Commit Graph

3134 Commits

Author SHA1 Message Date
aecsocket
fa7d1d7942 Use new MaxMind env vars on Labrinth (#4573)
* Bring in modrinth-maxmind

* integrate modrinth-maxmind into labrinth

* Fix CI
2025-10-18 18:38:19 +00:00
Calum H.
d1ffed564d fix: #4567 (#4571) 2025-10-17 17:56:25 +00:00
Alejandro González
e719ae2f42 fix(daedalus-client): backport new Mojang MC version library patches from PrismLauncher (#4493)
While researching and fixing other issue, it caught my attention that we
are embedding a library patches JSON file from the PrismLauncher meta
repository. However, since we copied that file, a new revision of it was
published with patches that improve compatibility with Apple Silicon
macOS platforms.

These changes update such a file and, perhaps most importantly, add a
comment explaining the provenance and licensing of such a file.
2025-10-17 16:43:04 +00:00
François-Xavier Talbot
5db5bf4c4c Changes to handling of refunds in Anrok (#4556)
* Use negations, track transaction version/accounting time, use original charge accounting time in refunds

* query cache

* chore: query cache, clippy, fmt

* Fix tax drift calculation

* Fix migration

* Increase update_tax_transactions rate
2025-10-17 15:57:36 +00:00
Josiah Glosson
b23d3e674f Update Rust & Java dependencies (#4540)
* Update Java dependencies

* Baselint lint fixes

* Update Rust version

* Update actix-files 0.6.6 -> 0.6.8

* Update actix-http 3.11.0 -> 3.11.2

* Update actix-rt 2.10.0 -> 2.11.0

* Update async_zip 0.0.17 -> 0.0.18

* Update async-compression 0.4.27 -> 0.4.32

* Update async-trait 0.1.88 -> 0.1.89

* Update async-tungstenite 0.30.0 -> 0.31.0

* Update const_format 0.2.34 -> 0.2.35

* Update bitflags 2.9.1 -> 2.9.4

* Update bytemuck 1.23.1 -> 1.24.0

* Update typed-path 0.11.0 -> 0.12.0

* Update chrono 0.4.41 -> 0.4.42

* Update cidre 0.11.2 -> 0.11.3

* Update clap 4.5.43 -> 4.5.48

* Update data-url 0.3.1 -> 0.3.2

* Update discord-rich-presence 0.2.5 -> 1.0.0

* Update enumset 1.1.7 -> 1.1.10

* Update flate2 1.1.2 -> 1.1.4

* Update hyper 1.6.0 -> 1.7.0

* Update hyper-util 0.1.16 -> 0.1.17

* Update iana-time-zone 0.1.63 -> 0.1.64

* Update image 0.25.6 -> 0.25.8

* Update indexmap 2.10.0 -> 2.11.4

* Update json-patch 4.0.0 -> 4.1.0

* Update meilisearch-sdk 0.29.1 -> 0.30.0

* Update clickhouse 0.13.3 -> 0.14.0

* Fix some prettier things

* Update lettre 0.11.18 -> 0.11.19

* Update phf 0.12.1 -> 0.13.1

* Update png 0.17.16 -> 0.18.0

* Update quick-xml 0.38.1 -> 0.38.3

* Update redis 0.32.4 -> 0.32.7

* Update regex 1.11.1 -> 1.11.3

* Update reqwest 0.12.22 -> 0.12.23

* Update rust_decimal 1.37.2 -> 1.38.0

* Update rust-s3 0.35.1 -> 0.37.0

* Update serde 1.0.219 -> 1.0.228

* Update serde_bytes 0.11.17 -> 0.11.19

* Update serde_json 1.0.142 -> 1.0.145

* Update serde_with 3.14.0 -> 3.15.0

* Update sentry 0.42.0 -> 0.45.0 and sentry-actix 0.42.0 -> 0.45.0

* Update spdx 0.10.9 -> 0.12.0

* Update sysinfo 0.36.1 -> 0.37.2

* Update tauri 2.7.0 -> 2.8.5

* Update tauri-build 2.3.1 -> 2.4.1

* Update tauri-plugin-deep-link 2.4.1 -> 2.4.3

* Update tauri-plugin-dialog 2.3.2 -> 2.4.0

* Update tauri-plugin-http 2.5.1 -> 2.5.2

* Update tauri-plugin-opener 2.4.0 -> 2.5.0

* Update tauri-plugin-os 2.3.0 -> 2.3.1

* Update tauri-plugin-single-instance 2.3.2 -> 2.3.4

* Update tempfile 3.20.0 -> 3.23.0

* Update thiserror 2.0.12 -> 2.0.17

* Update tracing-subscriber 0.3.19 -> 0.3.20

* Update url 2.5.4 -> 2.5.7

* Update uuid 1.17.0 -> 1.18.1

* Update webp 0.3.0 -> 0.3.1

* Update whoami 1.6.0 -> 1.6.1

* Note that windows and windows-core can't be updated yet

* Update zbus 5.9.0 -> 5.11.0

* Update zip 4.3.0 -> 6.0.0

* Fix build

* Enforce rustls crypto provider

* Refresh Cargo.lock

* Update transitive dependencies

* Bump Gradle usage to Java 17

* Use ubuntu-latest consistently across workflows

* Fix lint

* Fix lint in Rust

* Update native-dialog 0.9.0 -> 0.9.2

* Update regex 1.11.3 -> 1.12.2

* Update reqwest 0.12.23 -> 0.12.24

* Update rust_decimal 1.38.0 -> 1.39.0

* Remaining lock-only updates

* chore: move TLS impl of some other dependencies to aws-lc-rs

The AWS bloatware "virus" expands by sheer force of widespread adoption
by the ecosystem... 🫣

* chore(fmt): run Tombi

---------

Co-authored-by: Alejandro González <me@alegon.dev>
2025-10-15 20:45:47 +00:00
Prospector
75e3994c6e update changelog 2025-10-15 11:58:01 -07:00
Alejandro González
71e28e1ea5 fix(app-lib): cache most Modrinth data for the intended time (#4558) 2025-10-15 18:40:47 +00:00
Alejandro González
6dbd1e5236 fix(labrinth): make orgs with a single user and only approved projects visible to non-logged-in people (#4557)
I made a typo on PR https://github.com/modrinth/code/pull/4426 by making
the corresponding SQL query filter by projects with an unexisting
`public` status, instead of `approved`. During my testing, I used the
`archived` status, so I didn't notice it back then.
2025-10-15 18:16:44 +00:00
Prospector
77afdb1cc4 add UI for changing user role (#4554) 2025-10-15 18:10:36 +00:00
Alejandro González
7fa442fb28 Reapply "refactor(app): reduce tech debt by eliminating wry fork" (#4555)
* Reapply "refactor(app): reduce tech debt by eliminating `wry` fork (#4500)"

This reverts commit 2535156dac.

* test: temporarily replace ad link by something with sound

* Revert "test: temporarily replace ad link by something with sound"

This reverts commit 74bb7eecb7cc7b17ccfd6b2e20c24eeec38ac363.

* Reapply "test: temporarily replace ad link by something with sound"

This reverts commit f1b0e9f2c4a30f789099048e98ffa91ff376f571.

* test: also disable ads init muting script for good measure

* Revert "test: also disable ads init muting script for good measure"

This reverts commit 4ac7a81e1780f13c976d033c420bfe1d5db9c298.

* Revert "Reapply "test: temporarily replace ad link by something with sound""

This reverts commit c5f1b9f242f5c7f56b40f21b586e8b484c7eb3c5.
2025-10-15 10:24:32 +00:00
Prospector
2535156dac Revert "refactor(app): reduce tech debt by eliminating wry fork (#4500)"
This reverts commit dbc64afe
2025-10-14 19:55:54 -07:00
Prospector
8972c9a198 update changelog 2025-10-14 18:41:47 -07:00
Prospector
03ed64c99f Remove "prepare backup" step (#4551)
* Remove "prepare backup" step

* fix post-approval.ts
2025-10-14 22:35:50 +00:00
aecsocket
4cd8ccd319 Taplo and typos in CI, TOML cleanup (#4510)
* Taplo and typos in CI

* Clean up Cargo.toml files

* Fix CI

* Fix CI

* Run typos in CI

* Loosen typos a bit

* Fix typos

* Fix taplo

* Switch to Tombi

* Fix Tombi errors

* Remove unused typos config

* Tombi fmt

* Remove extraneous cargo fmt

* fix typos
2025-10-12 20:18:38 +00:00
chaos
ea594ec27c chore: update openapi docs to include neoforge for forgeUpdates (#4545)
* chore: update openapi docs to include neoforge for forgeUpdates

* chore: add NeoForge parameter to forge_updates
2025-10-12 13:38:44 +00:00
François-Xavier Talbot
2a61916d1e Mark charges from stripe customers with no address as unresolvable (#4521) 2025-10-11 18:24:21 +00:00
aecsocket
e66b131a5d See available funds history and withdrawls in user payout history (#4537)
* Add GET /v3/payouts/history

* V3 backwards compat

* Sqlx prepare

* Include user ID in GET /v3/payout
2025-10-11 10:51:38 +00:00
François-Xavier Talbot
0c66fa3f12 Custom Emails (#4526)
* Dynamic email template

* Set lower cache expiry for templates

* Custom email route

* Fix subject line on custom emails

* chore: query cache, clippy, fmt

* Bugfixes

* Key-based caching on custom emails

* Sequentially process emails prone to causing cache stampede

* Fill variables in dynamic body + subject line

* Update apps/labrinth/src/queue/email/templates.rs

Co-authored-by: aecsocket <aecsocket@tutanota.com>
Signed-off-by: François-Xavier Talbot <108630700+fetchfern@users.noreply.github.com>

* Update apps/labrinth/src/queue/email/templates.rs

Co-authored-by: aecsocket <aecsocket@tutanota.com>
Signed-off-by: François-Xavier Talbot <108630700+fetchfern@users.noreply.github.com>

---------

Signed-off-by: François-Xavier Talbot <108630700+fetchfern@users.noreply.github.com>
Co-authored-by: aecsocket <aecsocket@tutanota.com>
2025-10-10 16:30:38 +00:00
aecsocket
aec49cff7c Include both analytics v1 and v2 in tree (#4527)
* Include both analytics v1 and v2 in tree

* fix sqlx cache

* fix tests
2025-10-10 14:58:19 +00:00
François-Xavier Talbot
c88bdda3e6 More flexible datetime parsing (#4533) 2025-10-09 20:01:07 +00:00
Prospector
1a72d55e2d changelog 2025-10-08 13:41:24 -07:00
Prospector
55eae7ec7e update ads.txt (#4525) 2025-10-08 19:33:34 +00:00
Jerozgen
351b3da337 Fix download tax form description (#4522) 2025-10-08 19:12:04 +00:00
Calum H.
9ee0626e8b feat: dynamic email template using markdown (#4515)
* feat: markdown dynamic email template

* fix: lint and remove debug statements

* fix: lint issues
2025-10-08 19:05:23 +00:00
Prospector
e9735bd9ba Revert "Analytics backend V2 (#4408)" (#4524)
This reverts commit 6919c8dea9.
2025-10-08 19:01:32 +00:00
Alejandro González
15a7815ec3 perf(Dockerfile): improve Docker cache mounts usage (#4507)
As described in
https://hackmd.io/jgkoQ24YRW6i0xWd73S64A#Using-Docker-cache-mounts,
cache mounts need to be used with a fairly specific syntax for caching
of previously build Rust artifacts to be as effective as it can be.
2025-10-08 16:03:15 +00:00
aecsocket
6919c8dea9 Analytics backend V2 (#4408)
* start with analytics v2

* the big ass SQL query™

* downloads and views analytics working

* Implement analytics bucketing API

* allow filtering by monetization

* Use a new format for project metrics and bucketing

* revenue API works

* Add country data to analytics API

* Add checks for number of slices and time slice resolution

* work on docs

* wip: fix tests and add docs

* Fix tests

* Fix tests

* Uncomment crates

* feat: frontend CLAUDE.md (#4433)

* Slight tweaks to time slicing logic

* More tweaks

* Fix error messages

* Fix sqlx cache

---------

Co-authored-by: Calum H. <contact@cal.engineer>
2025-10-07 22:01:10 +00:00
Calum H.
f32558cf97 feat: tax form download stage (#4513)
* feat: start on fix

* fix: withdraw btn

* fix: lint issues

* feat: start on download stage for tax form modal

* fix: use button rather than span

* fix: lint

* fix: lint issues

* feat: tax form notification email for users who didnt get chance to download

* feat: finish download stage for tax modal

* fix: lint & i18n

* fix: lint + svg cleanup

---------

Signed-off-by: Calum H. <contact@cal.engineer>
Co-authored-by: --global <--global>
2025-10-07 21:51:43 +00:00
Calum H.
ad705fa66f feat: introduce surface variables, text variables & shades (#4413)
* feat: surface variables & gradients

* feat: text vars

* fix: lint

* chore: remove L from surface vars

* fix: fully remove L from surface vars

---------

Co-authored-by: --global <--global>
2025-10-07 16:35:45 +00:00
Prospector
87f8773401 update changelog 2025-10-07 09:47:37 -07:00
Calum H.
3c578108de fix: allow payouts that go over the tax limit by prefilling form (#4478)
* feat: start on fix

* fix: withdraw btn

* fix: lint issues

* fix: use button rather than span

* fix: lint issues

---------

Co-authored-by: --global <--global>
2025-10-07 16:33:50 +00:00
Calum H.
cb5600ad45 feat: doc templating & cleanup of routes (#4411)
* feat: clean up route structure

* feat: install html-pdf-node-ts

* fea

* feat: use @ceereals/vue-pdf (react-pdf)

* feat: remove pdf

* feat: hide cc

* feat: shared template

* feat: payment statement document & redirect for emails

* feat: layout tweaks

* fix: lint issues

* fix: robots.txt

* feat: remove letterhead

* Delete .claude/settings.local.json

Signed-off-by: Calum H. <contact@cal.engineer>

---------

Signed-off-by: Calum H. <contact@cal.engineer>
2025-10-07 10:47:59 +00:00
Modrinth Bot
59e48ea2b1 New translations from Crowdin (main) (#4436) 2025-10-07 09:12:11 +00:00
Josiah Glosson
7658e1c653 Restart the app after updates if the updater didn't do it for us (#4511) 2025-10-06 22:20:09 +00:00
François-Xavier Talbot
9589e23118 Link customer ID to Anrok transaction (#4509)
* Mark transactions with unresolvable addresses as unresolved

* Add customer_name + customer_id to anrok transactions

* Increase rate of Anrok syn

* Remove timer from update_tax_transactions

* chore: query cache, clippy, fmt
2025-10-06 16:06:57 +00:00
Alejandro González
dbc64afe48 refactor(app): reduce tech debt by eliminating wry fork (#4500) 2025-10-05 22:22:36 +00:00
Prospector
7e682c22bb add 0.10.10 changelog 2025-10-04 17:14:01 -07:00
Alejandro González
fd80f1217d fix(app): make MC <1.12.2 downloadable again (#4494)
PR #4270 modified the internal `fetch` function used by the application
to download version artifacts in a way that 4xx HTTP errors also caused
an abnormal return, instead of just 5xx errors. That was a good change,
but it had the unintended side effect of exposing our faulty logic
elsewhere of trying to download non-native JAR library artifacts when
only native artifacts are appropriate, at least according to the
PrismLauncher source code I've read. Such a download always returned a
404 error, but because such error was considered successful, a dummy
library file was still created and things worked seemingly fine.

These changes bring the Modrinth App behavior in this regard more in
line with PrismLauncher's, avoiding downloading non-native artifacts for
dependencies that have native artifacts available. (Reference:
8b5e91920d/launcher/minecraft/Library.cpp (L163))

I've tested these changes to work successfully with a variety of old
vanilla and modded Minecraft versions.

Fixes #4464.
2025-10-04 21:27:41 +00:00
Alejandro González
d98394d8d5 chore: revert back to stable Rust toolchain (#4492)
PR #3960 reverted the Cranelift usage introduced in #4388 due to its
codegen not being up to standard when compiling some pieces of code
under some platforms. However, it didn't revert the switch to a nightly
Rust toolchain, which is now unnecessary, and produces unnecessary drift
between what's declared in the `rust-toolchain.toml` and the Docker
image manifests, causing inefficiencies.

These changes bring back the usage of stable Rust for the time being to
correct those inefficiencies.
2025-10-04 20:42:57 +00:00
aecsocket
e303655727 Fix using a private serde_with re-export (#4489) 2025-10-04 18:10:42 +00:00
Prospector
95de8977d4 add 0.10.9 changelog 2025-10-04 10:59:40 -07:00
Prospector
92e91a0606 Remove successful update notif, is unnecessary and a bit broken (#4487) 2025-10-04 17:22:32 +00:00
Alejandro González
98269842f3 tweak(path-util): addendum to #4482 (#4486)
* tweak(path-util): addendum to #4482

These changes improve on those introduced in #4482 in two ways:

- The serialization logic for `SafeRelativeUtf8UnixPathBuf` now more
  closely mirrors the deserialization checks, reducing the chance that a
  generated path will fail to deserialize. While unlikely in practice,
  catching such theoretical cases earlier improves the experience for
  users and developers.
- After deeper testing on a clean Windows 10 VM, I found that reserved
  device names can have both an extension and an alternate data stream
  appended, not just one or the other. These changes handle that case
  more gracefully.

* chore: fix typos, add tests

* fix(path-util): extend `SafeRelativeUtf8UnixPathBuf` contract to allow `.` components

While quite useless, they were accepted by previous app versions, the
`.mrpack` specification does not forbid them, and they do not pose
security issues, so accept them for backwards compatibility.
2025-10-04 16:10:01 +00:00
Alejandro González
ab6e9dd5d7 fix(app-lib, labrinth): stricter mrpack file path validation (#4482)
* fix(app-lib, labrinth): stricter mrpack file path validation

* chore: run `cargo fmt`

* tweak: reject reserved Windows device names in mrpacks too
2025-10-04 10:35:30 +00:00
François-Xavier Talbot
a13647b9e2 Negate refund amount (#4481) 2025-10-03 23:29:22 +00:00
aecsocket
2af7ecc077 Fix affiliate PUT API (#4456)
* Fix affiliate PUT API

* PR fixes

* wip: merge affiliate code endpoints
2025-10-03 14:24:15 +00:00
François-Xavier Talbot
bea0ba017c Fix interactive payments in non-USD currencies (#4476)
* Use price's currency rather than inferred stripe currency in PaymentIntent

* Correctly convert to stripe::Currency

* Include original currency code in error message
2025-10-03 13:26:06 +00:00
Emma Alexia
f874856452 Fix user deletion with new notifications_deliveries table for real (#4473)
Maybe this will work? I dunno but users are still saying they're getting errors deleting accs. In theory it shouldn't matter if the transaction all gets committed at the same time, though, right? I can't really test this so I would like someone to tell me whether this will actually make a difference.

Co-authored-by: François-X. T <fetch@ferrous.ch>
2025-10-03 13:03:02 +00:00
aecsocket
b96c5cd5ab Improve error logging and observability (#4443)
* Replace actix tracing with custom error tracing

* Fix logging

* wip: JSON logging

* Use LABRINTH_FORMAT to change to JSON output

* sqlx fix?

* CI fix

* Add tracing span info to HTTP requests

* Merge Result and Option error wrapping

* Add http.authorized to tracing
2025-10-03 13:02:20 +00:00
François-Xavier Talbot
7e84659249 Cleanup + fixes to index_billing/index_subscriptions (#4457)
* Parse refunds

* Cleanup index subscriptions/index billing

* chore: query cache, clippy, fmt
2025-10-03 13:01:52 +00:00