WIP: feat: stateless sync and orphan all sync tokens #1456

Draft
gamesguru wants to merge 188 commits from gamesguru/continuwuity:guru/experiment/stateless-sync-purge-sync-tokens into main

188 commits

Author SHA1 Message Date
076b3b37d7
fix(cli): uwu enable SIGINT (Ctrl+C) mid-command
Some checks failed
Documentation / Build and Deploy Documentation (pull_request) Has been skipped
Complement Tests / complement-tests (pull_request) Failing after 32s
Update flake hashes / update-flake-hashes (pull_request) Successful in 30s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 3m12s
Checks / Prek / Clippy and Cargo Tests (pull_request) Failing after 1h0m0s
2026-03-04 19:59:55 -05:00
3687115073
fix: presence comparisons 2026-03-04 19:46:36 -05:00
d468c9c7d1
fix: place limit check/break at TOP of loop 2026-03-04 18:36:41 -05:00
5eb54d9c85
squash! fix: add outlier rescue admin commands; CONTROVERSIAL is_historical for prev_events soft-failing
enhance the `debug rescue-pdu` command with various useful filtering parameters
2026-03-04 18:17:05 -05:00
3d51339cd5
init forgejo runner for Complement tests 2026-03-04 18:05:57 -05:00
2327b04cce
Merge remote-tracking branch 'origin/main' into guru/nightly 2026-03-04 17:27:32 -05:00
0d46dfcaa7
fix: add outlier rescue admin commands; CONTROVERSIAL is_historical for prev_events soft-failing 2026-03-04 17:26:44 -05:00
d94df81985
fix(build): makefile fixes 2026-03-04 16:08:22 -05:00
caabf92bce
fix: misleading warning message on this branch 2026-03-04 14:57:50 -05:00
0245ffaf1d
chore(build/ci): tidy makefile 2026-03-04 14:53:22 -05:00
c03beb7bde
chore: News fragment 2026-03-04 14:39:34 -05:00
2845a63ae5
fix: Fix left rooms always being sent on initial sync 2026-03-04 14:39:33 -05:00
9d9fecf0c3
chore(ci): update github workflow var names 2026-03-04 13:24:06 -05:00
b1a7225c7f
build: tidy makefile 2026-03-04 13:10:50 -05:00
9a93e90f86
chore: bump version (0.6.6-beta.stateless)
fix: revert .0 suffix from stateless version bump

Revert "fix: revert .0 suffix from stateless version bump"

This reverts commit 646be79a6d67477f04b0d7b6fc9d17c9b3d65f35.

fix: change to 0.5.6-beta.stateless.0 per user request
2026-03-04 13:08:10 -05:00
76dd84468c
build: add make target to sync the lockfile 2026-03-04 13:01:31 -05:00
1746b69747
Merge remote-tracking branch 'origin/main' into guru/nightly
# Conflicts:
#	Cargo.lock
#	Cargo.toml
#	bin/complement
#	complement/complement.config.toml
#	src/core/error/mod.rs
#	src/service/media/remote.rs
#	src/service/sending/sender.rs
#	src/service/users/mod.rs
2026-03-04 12:53:50 -05:00
faf04f8e87
ci: try --format pkgname for less verbose CI log piping 2026-03-04 12:43:31 -05:00
ac07c5879b
ci: add targeted cache-clear-github make target 2026-03-04 12:08:49 -05:00
f7a3d26355
ci: general complement fixes 2026-03-04 11:58:49 -05:00
37f432b6c6
ci: fix overly verbose logging & long recursive comments exceeding GH API specs 2026-03-04 11:25:55 -05:00
ede4038532
ci: display branch/commit above complement stats 2026-03-04 11:13:04 -05:00
56bf084fbc
fix(ci-github): env var collision preventing full version string 2026-03-04 11:04:40 -05:00
1e06f5cd90
chore: Makefile easier supersedence with GH_ARTIFACT= 2026-03-04 11:01:37 -05:00
e3c910a95c
fix(ci[github]): use release-max-perf not just release-high-perf 2026-03-04 10:50:45 -05:00
09c6f15050
fixup! chore(ci/config): cleanup makefile 2026-03-04 10:48:36 -05:00
ef34ba449d
fix(ci[github]): add missing release-high-perf profile for skylake cpu build 2026-03-04 10:44:18 -05:00
e29a4efc94
fixup! ci(github): by default, disable GH workflows (which outside contributers may find useful) 2026-03-04 10:35:13 -05:00
de1890b89a
chore: fixup make download-list 2026-03-04 10:28:42 -05:00
437d7df982
chore(ci/config): cleanup makefile 2026-03-04 10:13:54 -05:00
8a1b36de2e
ci: fix make download annoyance, avx512 vs. avx2 runner 2026-03-04 09:55:38 -05:00
a247b29dac
ci(github): [wip] consolidate workflows 2026-03-04 09:47:29 -05:00
93ccdc73ff
ci(github): fix redundant sha ref and fetch tags by default 2026-03-04 09:32:35 -05:00
bb2494c00e
ci(github): by default, disable GH workflows (which outside contributers may find useful) 2026-03-04 09:32:35 -05:00
a1513ef027
security: fix temporary vulnerability/exploit introduced on this PR 2026-03-04 08:16:15 -05:00
9f03f8c22c
bump version 2026-03-04 06:54:15 -05:00
b310fe57d6
fix: handle some subspace event subcases 2026-03-03 11:03:11 -05:00
00117bfd78
wip 2026-03-03 10:14:59 -05:00
caee44cbab
fix: remove redundant duplicate state updates from copy paste job 2026-03-03 09:01:15 -05:00
b352bfe775
fix: 403 forbidden when attempting to leave or kick a 2nd person, and unread messages bug 2026-03-03 08:09:22 -05:00
5e5fdf5b52
fix: restrict startup presence reset to local users
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Has been skipped
Update flake hashes / update-flake-hashes (pull_request) Successful in 21s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m54s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 22m58s
2026-03-03 01:43:26 -05:00
83713cf3f9
tidy up database shutdown logic again 2026-03-03 01:14:56 -05:00
7de63f4894
fix ci to show comment full list of failures (test/complement) 2026-03-03 01:14:46 -05:00
34ec1ffcda
fix(router): block indefinitely on shutdown to avoid dropping active db refs 2026-03-03 00:39:16 -05:00
f6a9e052fb
fix(router): update shutdown db connection warn log 2026-03-03 00:32:15 -05:00
6fa8cc3d6b
logging: improve details of parallel DNS timeouts if admins care to know 2026-03-03 00:26:21 -05:00
bf209f1ded
fixup! better logging: "M_FORBIDDEN: Event is not authorized." 2026-03-03 00:10:20 -05:00
eb852062a9
better logging: "M_FORBIDDEN: Event is not authorized." 2026-03-02 23:38:50 -05:00
a32f87a11a
restore complement github action to working state 2026-03-02 23:30:56 -05:00
b71f5fb2dc
fix: bad unwrapping logic and stream holding 2026-03-02 22:55:25 -05:00
294a7ce158
fixup! perf: parallelize federation joins and improve sync state lookups [LARGE COMMIT] 2026-03-02 22:45:32 -05:00
6fce0995d2
fixup! update complement workflow to hopefully post PR comments successfully 2026-03-02 22:45:32 -05:00
4bc3aec5c3
perf: parallelize federation joins and improve sync state lookups [LARGE COMMIT] 2026-03-02 22:31:47 -05:00
020a1ca4a1
fixup! fix: PresenceService leak, which should release hold on GlobalsService and DB 2026-03-02 22:16:39 -05:00
4bd878172f
fixup! add more additional log info in similar places 2026-03-02 22:13:38 -05:00
356a880da8
perf: use synapse federated requests for joins and leaves to accomodate under-powered servers or large state chains 2026-03-02 21:47:20 -05:00
e831b70a7f
fix: race condition associated with log spam: "user joined since last sync"
```log
2026-03-03T02:36:25.790498Z  INFO conduwuit_api::client::sync::v3::joined: user joined since last sync: last_sync_end_shortstatehash=Some(3316807), membership=Some(RoomMemberEventContent { avatar_url: Some("mxc://mdev.nutra.tk/Pb87ocP5NsGs7xvS9ZbIDhI30aU7EZLO"), displayname: Some("ggdev 🏴🚩"), is_direct: None, membership: "leave", third_party_invite: None, blurhash: None, reason: None, join_authorized_via_users_server: None, redact_events: None })
```
2026-03-02 21:36:37 -05:00
763d095ca2
perf: allow 3 concurrent DNS lookups per request (no more sequential SRV->A->AAAA bottlenecks) 2026-03-02 21:33:57 -05:00
31a3c42b21
update complement workflow to hopefully post PR comments successfully 2026-03-02 21:31:26 -05:00
78de411000
fixup! fix: PresenceService leak, which should release hold on GlobalsService and DB 2026-03-02 21:22:32 -05:00
89ddc52b50
add more additional log info in similar places 2026-03-02 21:21:29 -05:00
aa74ee56eb
fix: add additional info around warning log "Missing Authorization header.: Header of type authorization was missing" 2026-03-02 21:14:39 -05:00
e48ad40558
fixup! fixup! adjust log levels 2026-03-02 21:09:35 -05:00
d3900d370b
fix: PresenceService leak, which should release hold on GlobalsService and DB 2026-03-02 21:05:18 -05:00
68c20ecafb
fixup! adjust log levels 2026-03-02 20:14:50 -05:00
e98e1ec605
fix(ci): hopefully fix complement test suite log summary JSON parsing error 2026-03-02 19:59:52 -05:00
00d5fe3b8d
better handling of shutdown logic and closing of database references 2026-03-02 19:58:58 -05:00
55a253992e
adjust log levels 2026-03-02 19:52:15 -05:00
ce5f250c1f
fetch tags in github workflows 2026-03-02 19:41:35 -05:00
2ab1112c4a
fixup! fix: explicit legacy media routes and reduce log noise 2026-03-02 19:10:08 -05:00
f6d2836ac8
attempt to completely safely close hanging database handlers/refs 2026-03-02 18:14:20 -05:00
d874e7f58b
don't cache negative hits; adjust logs 2026-03-02 07:38:01 -05:00
5febd07c0a
media and shutdown cleanup 2026-03-02 06:35:07 -05:00
49ec05a836
run all complement tests, parallelize DB opening, add warn log. 2026-03-02 05:02:07 -05:00
b4948981fa
fix: shut the services down in a logical, safer, and more expeditious manner 2026-03-02 04:20:35 -05:00
d67c9b44c6
fix: pernicious bug resulting in clobbered cross-sigs (by sig merge logic) 2026-03-02 03:46:16 -05:00
a7887371be
fixup! fix: explicit legacy media routes and reduce log noise 2026-03-02 03:24:08 -05:00
6e9b33a229
fix: explicit legacy media routes and reduce log noise 2026-03-02 02:16:37 -05:00
07160e1ba7
fix: ensure complement result files are always created and add debug info 2026-03-02 01:00:02 -05:00
75787524bd
fix: make complement test result paths absolute to resolve missing artifacts in CI 2026-03-02 00:57:09 -05:00
cc7d77e6d4
revert busted attempt to liberally bamboozle /r0/thumbnail into subordination 2026-03-02 00:50:13 -05:00
91159bfeec
fixup! various tweaks & hopefully some fixes 2026-03-02 00:19:16 -05:00
32b0f53631
fix: missing logic inversion for acquired keys (should speed up room joins) 2026-03-01 23:23:12 -05:00
3e7bc3b6b3
simplify join hopeful fix failed to derive last_sync_end_shortstatehash and oldest event is before last sync 2026-03-01 23:21:14 -05:00
e8bf10a9aa
various tweaks & hopefully some fixes 2026-03-01 23:18:04 -05:00
b86f82c0df
silence two noisy logs for debugging; TODO: put on periodic stat report? 2026-03-01 21:23:16 -05:00
4d63b939d4
fixup! fix: complement tests 2026-03-01 21:12:31 -05:00
be44f83032
fixup! some efforts to debug/resolve the sluggy startup tendencies 2026-03-01 20:04:09 -05:00
dad34dfc4f
config fix (output debug builds, too, in GitHub) 2026-03-01 20:03:39 -05:00
fe8350948d
some efforts to debug/resolve the sluggy startup tendencies 2026-03-01 19:55:07 -05:00
b860412720
more lint fixes 2026-03-01 19:45:12 -05:00
e18b3af926
some lint fixes 2026-03-01 18:48:45 -05:00
01adb96c30
perf: limit member PDU fetch concurrency to 256 2026-03-01 18:31:20 -05:00
6664ca3fc7
fix: this branch's regression on the legacy media spec 2026-03-01 18:28:56 -05:00
02c9649591
perf: add room state cache and optimize /members to fetch only member events 2026-03-01 17:01:20 -05:00
57f84a79be
fix: better fallback for rooms missing from sync after federated join 2026-03-01 17:01:20 -05:00
fddb329e64
fix: complement tests 2026-03-01 15:00:08 -05:00
5fc91d1a0b
Merge branch 'guru/fix/media-legacy-r0-endpoints' into guru/nightly 2026-03-01 12:34:50 -05:00
8a07b4f7ef
Merge branch 'guru/fix/stratify-internal-500-errors-by-type-and-severity' into guru/nightly 2026-03-01 12:04:52 -05:00
03a42739a2
config changes? 2026-03-01 10:44:08 -05:00
d68d2dca9f
fix: include outlier PDUs in state resolution to fix partially-loaded member lists
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Has been skipped
Update flake hashes / update-flake-hashes (pull_request) Successful in 22s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m23s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 20m6s
2026-03-01 09:36:14 -05:00
4e86ba0e80
fix: force profile update propagation to all rooms and parallelize with broad_then 2026-03-01 09:36:09 -05:00
cc21434412
perf: use wide_ methods to parallelize server discovery and remote PDU fetching
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Has been skipped
Update flake hashes / update-flake-hashes (pull_request) Successful in 49s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m0s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 20m45s
2026-03-01 08:48:53 -05:00
e4a7f1bbd5
fix: lint warning on main to appease clippy
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m39s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 25m32s
2026-03-01 06:36:10 -05:00
697bc52610
fix: subtype 500 errors FederationTimeout(504) and FederationConnection(502) 2026-03-01 06:26:38 -05:00
45c34d2cc5
fix: missing m.room.create outliers causing a sea of Empty rooms and Version 1 errors
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Has been skipped
Update flake hashes / update-flake-hashes (pull_request) Successful in 23s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 3m44s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 37m37s
2026-03-01 06:20:00 -05:00
f40237701e
fix(sync): Apply remote state to room before appending join event in stateless sync 2026-03-01 05:18:20 -05:00
1e27d3f684
fix(sync): Return proper timeline for newly joined rooms in stateless sync 2026-03-01 04:49:17 -05:00
05e8aa8da7
fix: [warning] m.room.create event is missing room version, assuming version "1" 2026-03-01 03:56:02 -05:00
5f84b74f38
fix merge 2026-03-01 02:41:58 -05:00
ec117d6f30
restore deleted check_legacy_freeze functionality 2026-03-01 02:41:58 -05:00
d3a6abe86b
don't leak info on forbidden 2026-03-01 02:41:58 -05:00
3acedeee63
feat(media): add config to enable missing legacy media endpoints
update config key descriptions in config/mod.rs

add speculative fixes for the following 404 ORB errors in SchildiChat web:

    {"errcode":"M_NOT_FOUND","error":"M_NOT_FOUND: Fetching media failed: Answer from matrix.sp-codes.de: [404 / M_UNRECOGNIZED] Unrecognized request mxc=mxc://matrix.sp-codes.de/SpHUPhCGRnsYTFlyRYCDZhDD authenticated=true"}

    {"errcode":"M_NOT_FOUND","error":"M_NOT_FOUND: Fetching media failed: Answer from hampai.ch: [401 / M_UNAUTHORIZED] no auth provided (required) mxc=mxc://hampai.ch/b291e6908914b64277b7ed0e1de87df5d52cac241958243044855644160 authenticated=true"}

enforce freeze_legacy_media on all legacy remote fetch paths

fix: fallback to unauthenticated media on more errors and safely return NotFound for empty media
2026-03-01 02:41:58 -05:00
5ad6f22b38
fixup! config changes 2026-03-01 02:41:58 -05:00
2de2ffb52a
fix and update stuff 2026-03-01 01:36:48 -05:00
f49678b5ad
separate custom build workflow 2026-02-28 23:26:17 -05:00
01ad0b787e
Merge branch 'main' into guru/experiment/stateless-sync-purge-sync-tokens 2026-02-28 23:18:23 -05:00
0a2d135dff
Merge branch 'guru/experiment/Matrix-Complement-Test-Suite' 2026-02-28 23:10:29 -05:00
e17a4c3cc9
perf(sync): batch PDU retrieval during state resolution to prevent 408 errors during initial sync 2026-02-28 08:42:31 -05:00
bd68879a29
config changes 2026-02-28 08:35:49 -05:00
30b41c9a96
adjust log messages 2026-02-28 08:20:44 -05:00
ed9ddbc56f
Merge branch 'chore/config' into guru/experiment/stateless-sync-purge-sync-tokens 2026-02-28 07:42:16 -05:00
e8997a2963
fix config (one dep out of sync in Cargo.toml w/ main) 2026-02-28 06:36:22 -05:00
4b5f21a685
drop sync tokens; rework timeline state resolution 2026-02-28 06:31:20 -05:00
7e903b4847
implement a basic LRU cache to reduce disk seeks under concurrent loads 2026-02-28 02:38:07 -05:00
655e6fdbb8
fix/tidy 2026-02-28 02:08:01 -05:00
Shane
bdd747149e
fix joins? 2026-02-27 14:46:10 -05:00
Shane
7709977e54
Merge branch 'guru/experiment/rocksdb-transactional-wrappers' into guru/experiment/stateless-sync-purge-sync-tokens 2026-02-27 14:31:34 -05:00
Shane
a5049e055b
switch a log from info to debug; appease clippy 2026-02-27 13:54:41 -05:00
824a696c39
Merge branch 'guru/experiment/Matrix-Complement-Test-Suite' into guru/experiment/stateless-sync-purge-sync-tokens 2026-02-27 08:49:26 -05:00
6a8619a776
changes to refactor it again, more
Some checks failed
Documentation / Build and Deploy Documentation (pull_request) Has been skipped
Update flake hashes / update-flake-hashes (pull_request) Successful in 22s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 3m3s
Checks / Prek / Clippy and Cargo Tests (pull_request) Failing after 19m3s
2026-02-27 08:46:16 -05:00
691b269c09
checkpoint? or broken? 2026-02-27 08:45:44 -05:00
693a5a46d2
fixup! squash! fix spam: "timeline for newly joined room is empty" 2026-02-27 07:32:11 -05:00
fd261e5d2a
fixup! squash! fix spam: "timeline for newly joined room is empty" 2026-02-27 05:49:18 -05:00
1f56875e88
fixup! config changes 2026-02-27 05:14:01 -05:00
7fe9b0c8bc
fixup! squash! fix spam: "timeline for newly joined room is empty" 2026-02-27 05:13:49 -05:00
c7c9f199ac
fixup! config changes 2026-02-27 04:49:23 -05:00
dfd188a3c4
fixup! squash! fix spam: "timeline for newly joined room is empty" 2026-02-27 04:23:38 -05:00
cb9ad6655f
fixup! config changes 2026-02-27 03:04:20 -05:00
dff38bba00
squash! fix spam: "timeline for newly joined room is empty"
add some info/warn logs for debugging
2026-02-27 02:59:06 -05:00
7b6addff3b
fixup! config changes 2026-02-27 02:51:08 -05:00
0592f9e808
fix spam: "timeline for newly joined room is empty" 2026-02-27 02:50:39 -05:00
a76b9e0bc1
run complement thru gotestsum for easier to digest (human-readable) output 2026-02-25 08:14:05 -05:00
fdcc24c8be
presence and response fix 2026-02-25 08:13:43 -05:00
3f22675140
fix some tests? 2026-02-25 08:06:29 -05:00
709edd1a05
some more response obfuscating to meet spec 2026-02-25 07:40:33 -05:00
271461c836
restore expected 400 error; enable presence/federation in complement config 2026-02-25 07:21:39 -05:00
e856655b8e
more complement fixes to pass some more tests 2026-02-25 07:13:23 -05:00
4b4586a238
allow DELETE, fix 400 error (want 401), see below:
This error occurred fairly early in the Complement logs:

```log
=== NAME  TestDeviceManagement/DELETE_/device/{deviceId}
    apidoc_device_management_test.go:134: MatchResponse got status 400 want 401 - http://127.0.0.1:32820/_matrix/client/v3/devices/7hTYOfr7hy => {"errcode":"M_NOT_JSON","error":"M_NOT_JSON: Not json."}
=== RUN   TestDeviceManagement/DELETE_/device/{deviceId}_requires_UI_auth_user_to_match_device_owner
```
2026-02-25 06:46:55 -05:00
1107ee54b6
fix 2026-02-25 06:21:23 -05:00
af712c2e2c
config changes & remove auth thingy for other PR 2026-02-25 05:59:29 -05:00
2738458865
fix(complement): resolve Docker build context issues for any profile
- .dockerignore: whitelist target/dev-quick/conduwuit and target/latest/conduwuit
- Dockerfile: copy from target/dev-quick/conduwuit (concrete path, no symlink)
- Makefile: pass through PROFILE and include --profile in CARGO_FLAGS override
2026-02-25 05:13:07 -05:00
38c331945d
fix(register): skip token check when open registration is enabled
iterate_tokens() always returns the first-run token during first-run
mode, so the previous fix still caused the RegistrationToken flow to
be offered. Now the iterate_tokens() check is also skipped when
open_registration is explicitly enabled, allowing the code to fall
through to the m.login.dummy flow path.
2026-02-25 05:09:54 -05:00
2fe6a8b35a
fix(complement): cp binary to flat path to work around Docker symlink limitation
Docker COPY cannot follow directory symlinks in the build context.
Resolve target/latest to the actual profile dir using readlink,
cp the binary to target/conduwuit-complement (a plain file),
and COPY from that in the Dockerfile.
2026-02-25 04:56:35 -05:00
e733b75a86
fix(complement): include --profile in CARGO_FLAGS override, use target/debug/
CARGO_FLAGS default includes --profile, so overriding it requires
including --profile explicitly. Revert Dockerfile to target/debug/
since both dev and dev-quick produce the binary there.
2026-02-25 04:45:16 -05:00
b48fa9a216
fix(complement): pass PROFILE=dev as Make arg not shell env var
Shell env vars don't override .env file values in sub-make calls.
Make command-line arguments have the highest precedence and correctly
override whatever PROFILE is set in .env.
2026-02-25 04:40:48 -05:00
1841fe4436
fix(complement): force PROFILE=dev for docker/complement build
Use PROFILE=dev (matching CI) to ensure binary is in target/debug/
where the Dockerfile expects it. The dev-quick profile doesn't produce
a conduwuit binary in its output directory.
2026-02-25 04:39:17 -05:00
48c1bbebc1
fix(complement): resolve symlink for Docker build context
Docker COPY doesn't follow host symlinks, so target/latest/conduwuit
failed. The Makefile now copies the resolved binary to
target/conduwuit-complement before docker build, and the Dockerfile
copies from that stable non-symlinked path.
2026-02-25 04:37:36 -05:00
1ab9e6b018
fix(complement): copy from target/latest/ so any build profile works
The Dockerfile was hardcoded to target/debug/conduwuit but the Makefile
builds to target/dev-quick/ by default, causing Docker to silently
reuse the old cached binary.

target/latest is a symlink that always points to the last-built profile
directory. Using it means the Dockerfile works correctly regardless of
whether the user built with dev, dev-quick, or release.
2026-02-25 04:35:15 -05:00
3a587cd7f4
fix(complement): use PROFILE=dev and --no-cache for docker/complement target
The Dockerfile copies target/debug/conduwuit, but the Makefile was
building with the default dev-quick profile into target/dev-quick/.
Docker then silently reused the cached old binary.

Use PROFILE=dev to match CI and ensure the binary goes to target/debug/,
and add --no-cache to docker build to force a fresh image.
2026-02-25 04:34:09 -05:00
a2fd581ccf
fix(register): fix 500 error and first-run registration with open registration
Two fixes:

1. Error::Uiaa now maps to StatusCode::UNAUTHORIZED (401) in
   status_code() instead of falling through to the wildcard
   INTERNAL_SERVER_ERROR (500). Fixes issue #1409.

2. When yes_i_am_very_very_sure_i_want_an_open_registration_server_prone_to_abuse
   is set, first-run mode no longer forces m.login.registration_token.
   Admins that explicitly opted into open registration should get
   m.login.dummy on first-run just like subsequent registrations.
   Fixes Complement TestRegistration failures.

Also adds docker/complement Makefile target for local Complement testing.
2026-02-25 04:31:27 -05:00
b6d064d43f
fix(complement): bootstrap first admin user to exit first-run mode
During first-run mode, registration requires m.login.registration_token
which Complement cannot supply. The entrypoint now starts conduwuit,
parses the auto-generated token from the welcome banner, registers a
first admin user to exit first-run mode, then lets Complement tests
proceed using m.login.dummy auth.
2026-02-25 04:15:52 -05:00
f9ceab6449
fix(uiaa): map Error::Uiaa to 401 Unauthorized status code instead of 500 Internal Server Error 2026-02-25 03:15:32 -05:00
58cc8e449f
fix(complement): bundle direct_tls and adjust db path for tests 2026-02-25 01:44:56 -05:00
9d42f4673c
build with direct_tls (full features) to fix Complement startup failure? 2026-02-25 01:10:04 -05:00
6d74457bd1
config changes 2026-02-24 03:24:18 -05:00
1b9987df14
feat: stateless sync and orphan all sync tokens
Some checks failed
Documentation / Build and Deploy Documentation (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 5m44s
Checks / Prek / Clippy and Cargo Tests (pull_request) Failing after 31m27s
2026-02-24 03:24:41 -05:00
e45fe8b997
config changes 2026-02-23 06:07:24 -05:00
7b846ccffe
feat: implement transactional wrappers around room joins and other key code blocks writing to the database
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 15m40s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 24m23s
edits in join.rs to support better transactions

lint fixes

add a test to ensure the database nested transaction panic works as expected

add news fragment
2026-02-23 06:10:43 -05:00
6b12998e4f
config changes 2026-02-23 06:07:24 -05:00
06536f2025
ci: add matrix-org/complement testing suite workflow 2026-02-24 01:20:45 -05:00
5dfe69ef23
fix build (Cargo.lock mismatch resolved) 2026-02-22 12:53:55 -05:00
3506aa8268
config changes 2026-02-21 01:32:58 -05:00
f957b3f02b
admin command to clear URL preview cache (per URL currently) 2026-02-21 01:09:41 -05:00
d17c8429f1
lint fix 2026-02-20 23:49:14 -05:00
ba0115d5fa
more aggressive user agent for media to hopefully fix:
"Your browser is deprecated. Please upgrade."
2026-02-20 21:45:11 -05:00
ded383f4d3
restore 2026-02-20 21:30:27 -05:00
81031bf225
update configs/fix 2026-02-20 21:23:50 -05:00
6297b3b192
add github workflow to build out jammy image 2026-02-17 13:22:19 -05:00
fd8b1620a7
pin askama to shared 0.15 version where possible 2026-02-17 12:25:54 -05:00
Shane
db7f014042
make legacy media hopefully configurable?
tidy up, fix build error
2026-02-16 14:44:47 -05:00
ab84cef338
put embedbot sig only on media-like endpoints 2026-02-16 08:01:45 -05:00
acc069b909
feat(media): supply option to enable additional legacy media endpoints 2026-02-16 04:09:55 -05:00
4d0b47fdd2
simplify git URI parsing logic
tidy/remove bloat, consolidate
2026-02-16 03:06:06 -05:00
baffec46da
add tests 2026-02-16 03:05:18 -05:00
0f303c0182
improve build hash logic. initialize makefile targets 2026-02-14 23:55:04 -05:00
7c3548b2b8
add a "release-fast" build target for quicker testing/development
make .envrc work for me
2026-02-14 17:29:19 -05:00
af5eb97c46
fix build hashing to update each time regardless of clone strategy 2026-02-14 17:29:00 -05:00