Eric Eastwood
efa6018519
Move LaterGauge further along
2025-05-20 13:58:02 -05:00
Eric Eastwood
65080f8464
More cleanup
2025-05-20 13:35:00 -05:00
Eric Eastwood
1400e155b2
Fix most lints
2025-05-20 13:29:12 -05:00
Eric Eastwood
ccd0a71395
Revert LruCache CacheManager changes for now
2025-05-20 13:24:49 -05:00
Eric Eastwood
4018aa4d98
Fix incorrect @cache_in_self underscore prefix in tests
2025-05-20 13:17:07 -05:00
Eric Eastwood
f49789bfd0
Fix LruCache @overload
2025-05-20 13:03:49 -05:00
Eric Eastwood
9943cd39ad
Fix return lints
2025-05-20 12:53:51 -05:00
Eric Eastwood
d3d228ea2d
More cache updates (LruCache not finished)
2025-05-19 16:59:17 -05:00
Eric Eastwood
d3c23f8235
Partial changes for CacheManager
2025-05-19 16:09:16 -05:00
Eric Eastwood
3de2c0970e
Move jemalloc metrics further along
2025-05-19 14:26:27 -05:00
Eric Eastwood
3215897de6
Try organize some of the global metrics
2025-05-16 17:54:39 -05:00
Eric Eastwood
86f39b04a6
Partial Counter update
2025-05-16 17:10:22 -05:00
Eric Eastwood
72b3becb89
Refactor more custom Collector to be stubbed to use hs.metrics_collector_registry
2025-05-15 16:49:39 -05:00
Eric Eastwood
a6dd8a96bb
Refactor our custom Collector to accept a registry
2025-05-15 16:47:36 -05:00
Eric Eastwood
9c6863e1a7
Remove metrics listener type in favor of http listener with metrics resource
2025-05-15 16:20:41 -05:00
Eric Eastwood
c07d3108cc
Move a couple metrics to homeserver specific CollectorRegistry
2025-05-15 15:45:26 -05:00
Stanislav Kazantsev
0afdc0fc7f
remove room without listeners from Notifier.room_to_user_streams ( #18380 )
...
Co-authored-by: Andrew Morgan <andrew@amorgan.xyz >
2025-05-15 18:18:17 +01:00
_
44ae5362fd
Add option to allow registrations that begin with '_' ( #18262 )
...
Co-authored-by: Andrew Morgan <1342360+anoadragon453@users.noreply.github.com >
2025-05-15 11:31:52 +00:00
Kim Brose
194b923a6e
Fix room_list_publication_rules docs for v1.126.0 ( #18286 )
...
Co-authored-by: Andrew Morgan <1342360+anoadragon453@users.noreply.github.com >
2025-05-14 11:36:54 +01:00
Eric Eastwood
a3bbd7eeab
Explain why we flush_buffer() for Python print(...) output ( #18420 )
...
Spawning from using this code elsewhere and not knowing why it's there.
Based on this article and @reivilibre's experience mentioning
`PYTHONUNBUFFERED=1`,
> #### programming languages where the default “print” statement buffers
>
> Also, here are a few programming language where the default print
statement will buffer output when writing to a pipe, and some ways to
disable buffering if you want:
>
> - Python (disable with `python -u`, or `PYTHONUNBUFFERED=1`, or
`sys.stdout.reconfigure(line_buffering=False)`, or `print(x,
flush=True)`)
>
> _--
https://jvns.ca/blog/2024/11/29/why-pipes-get-stuck-buffering/#programming-languages-where-the-default-print-statement-buffers_
2025-05-13 10:40:49 -05:00
Eric Eastwood
6e910e2b2c
Fix a couple type annotations in the RootConfig/Config ( #18409 )
...
Fix a couple type annotations in the `RootConfig`/`Config`. Discovered
while cribbing this code for another project.
It's really sucks that `mypy` type checking doesn't catch this. I assume
this is because we also have a `synapse/config/_base.pyi` that overrides
all of this. Still unclear to me why the `Iterable[str]` vs
`StrSequence` issue wasn't caught as that's what `ConfigError` expects.
2025-05-13 10:22:15 -05:00
Andrew Morgan
2db54c88ff
Explicitly enable pypy for cibuildwheel ( #18417 )
2025-05-13 15:19:30 +01:00
Andrew Morgan
480d4faa38
Remove newline from final bullet point of PR template ( #18419 )
2025-05-13 15:14:00 +01:00
dependabot[bot]
ba2f1be891
Bump types-requests from 2.32.0.20241016 to 2.32.0.20250328 ( #18427 )
2025-05-13 15:12:34 +01:00
dependabot[bot]
c626d54cea
Bump mypy-zope from 1.0.9 to 1.0.11 ( #18428 )
2025-05-13 15:12:22 +01:00
Erik Johnston
99c15f4630
Fix up changelog
v1.130.0rc1
2025-05-13 10:54:23 +01:00
Erik Johnston
09b4109c2e
1.130.0rc1
2025-05-13 10:44:11 +01:00
dependabot[bot]
40ce11ded0
Bump pillow from 11.1.0 to 11.2.1 ( #18429 )
...
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-13 09:46:03 +01:00
dependabot[bot]
3dade08e7c
Bump actions/setup-go from 5.4.0 to 5.5.0 ( #18426 )
...
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-13 09:34:23 +01:00
dependabot[bot]
1920dfff40
Bump pydantic from 2.10.3 to 2.11.4 ( #18394 )
2025-05-09 16:36:54 +01:00
dependabot[bot]
b7728a2df1
Bump packaging from 24.2 to 25.0 ( #18393 )
2025-05-09 15:37:05 +01:00
dependabot[bot]
c6dfe70014
Bump txredisapi from 1.4.10 to 1.4.11 ( #18392 )
2025-05-09 15:36:41 +01:00
dependabot[bot]
b5d94f654c
Bump sha2 from 0.10.8 to 0.10.9 ( #18395 )
2025-05-09 15:35:18 +01:00
Devon Hudson
7c633f1a58
Pass leave from remote invite rejection down Sliding Sync ( #18375 )
...
Fixes #17753
### Dev notes
The `sliding_sync_membership_snapshots` and `sliding_sync_joined_rooms`
database tables were added in
https://github.com/element-hq/synapse/pull/17512
### Pull Request Checklist
<!-- Please read
https://element-hq.github.io/synapse/latest/development/contributing_guide.html
before submitting your pull request -->
* [X] Pull request is based on the develop branch
* [x] Pull request includes a [changelog
file](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#changelog ).
The entry should:
- Be a short description of your change which makes sense to users.
"Fixed a bug that prevented receiving messages from other servers."
instead of "Moved X method from `EventStore` to `EventWorkerStore`.".
- Use markdown where necessary, mostly for `code blocks`.
- End with either a period (.) or an exclamation mark (!).
- Start with a capital letter.
- Feel free to credit yourself, by adding a sentence "Contributed by
@github_username." or "Contributed by [Your Name]." to the end of the
entry.
* [X] [Code
style](https://element-hq.github.io/synapse/latest/code_style.html ) is
correct
(run the
[linters](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#run-the-linters ))
---------
Co-authored-by: Erik Johnston <erik@matrix.org >
Co-authored-by: Olivier 'reivilibre <oliverw@matrix.org >
Co-authored-by: Eric Eastwood <erice@element.io >
2025-05-08 14:28:23 +00:00
Devon Hudson
ae877aa101
Convert Sliding Sync tests to use higher-level compute_interested_rooms ( #18399 )
...
Spawning from
https://github.com/element-hq/synapse/pull/18375#discussion_r2071768635 ,
This updates some sliding sync tests to use a higher level function in
order to move test coverage to cover both fallback & new tables.
Important when https://github.com/element-hq/synapse/pull/18375 is
merged.
In other words, adjust tests to target `compute_interested_room(...)`
(relevant to both new and fallback path) instead of the lower level
`get_room_membership_for_user_at_to_token(...)` that only applies to the
fallback path.
### Dev notes
```
SYNAPSE_TEST_LOG_LEVEL=INFO poetry run trial tests.handlers.test_sliding_sync.ComputeInterestedRoomsTestCase_new
```
```
SYNAPSE_TEST_LOG_LEVEL=INFO poetry run trial tests.rest.client.sliding_sync
```
```
SYNAPSE_POSTGRES=1 SYNAPSE_POSTGRES_USER=postgres SYNAPSE_TEST_LOG_LEVEL=INFO poetry run trial tests.handlers.test_sliding_sync.ComputeInterestedRoomsTestCase_new.test_display_name_changes_leave_after_token_range
```
### Pull Request Checklist
<!-- Please read
https://element-hq.github.io/synapse/latest/development/contributing_guide.html
before submitting your pull request -->
* [x] Pull request is based on the develop branch
* [x] Pull request includes a [changelog
file](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#changelog ).
The entry should:
- Be a short description of your change which makes sense to users.
"Fixed a bug that prevented receiving messages from other servers."
instead of "Moved X method from `EventStore` to `EventWorkerStore`.".
- Use markdown where necessary, mostly for `code blocks`.
- End with either a period (.) or an exclamation mark (!).
- Start with a capital letter.
- Feel free to credit yourself, by adding a sentence "Contributed by
@github_username." or "Contributed by [Your Name]." to the end of the
entry.
* [x] [Code
style](https://element-hq.github.io/synapse/latest/code_style.html ) is
correct
(run the
[linters](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#run-the-linters ))
---------
Co-authored-by: Eric Eastwood <erice@element.io >
2025-05-07 15:07:58 +00:00
Andrew Morgan
740fc885cd
Merge branch 'master' into develop
2025-05-06 13:31:41 +01:00
Andrew Morgan
9a62b2d47a
1.129.0
v1.129.0
2025-05-06 12:22:27 +01:00
Will Hunt
d0873d549a
Ensure the url previewer also hashes and quarantines media ( #18297 )
...
Co-authored-by: Andrew Morgan <1342360+anoadragon453@users.noreply.github.com >
2025-05-06 11:04:31 +01:00
Florian Klink
c9adbc6a1c
make tests tolerant to authlib 1.5.2 error messages ( #18390 )
...
authlib 1.5.2 now single-quotes error messages in the claims, causing
three tests to fail.
Replace the comparison with a regex that accepts both single or double
quotes.
This succeeds the tests with both authlib 1.5.1 and 1.5.2.
See https://github.com/NixOS/nixpkgs/pull/402797 for context.
### Pull Request Checklist
<!-- Please read
https://element-hq.github.io/synapse/latest/development/contributing_guide.html
before submitting your pull request -->
* [x] Pull request is based on the develop branch
* [x] Pull request includes a [changelog
file](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#changelog ).
The entry should:
- Be a short description of your change which makes sense to users.
"Fixed a bug that prevented receiving messages from other servers."
instead of "Moved X method from `EventStore` to `EventWorkerStore`.".
- Use markdown where necessary, mostly for `code blocks`.
- End with either a period (.) or an exclamation mark (!).
- Start with a capital letter.
- Feel free to credit yourself, by adding a sentence "Contributed by
@github_username." or "Contributed by [Your Name]." to the end of the
entry.
* [x] [Code
style](https://element-hq.github.io/synapse/latest/code_style.html ) is
correct
(run the
[linters](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#run-the-linters ))
2025-05-05 10:09:39 +00:00
David Baker
9f9eb56333
Return specific error code when email / phone not supported ( #17578 )
...
Implements https://github.com/matrix-org/matrix-spec-proposals/pull/4178
If this would need tests, could you give some idea of what tests would
be needed and how best to add them?
### Pull Request Checklist
<!-- Please read
https://element-hq.github.io/synapse/latest/development/contributing_guide.html
before submitting your pull request -->
* [ ] Pull request is based on the develop branch
* [ ] Pull request includes a [changelog
file](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#changelog ).
The entry should:
- Be a short description of your change which makes sense to users.
"Fixed a bug that prevented receiving messages from other servers."
instead of "Moved X method from `EventStore` to `EventWorkerStore`.".
- Use markdown where necessary, mostly for `code blocks`.
- End with either a period (.) or an exclamation mark (!).
- Start with a capital letter.
- Feel free to credit yourself, by adding a sentence "Contributed by
@github_username." or "Contributed by [Your Name]." to the end of the
entry.
* [ ] [Code
style](https://element-hq.github.io/synapse/latest/code_style.html ) is
correct
(run the
[linters](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#run-the-linters ))
2025-05-05 11:08:50 +02:00
Will Lewis
fe8bb620de
Add the ability to exclude remote users in user directory search results ( #18300 )
...
This change adds a new configuration
`user_directory.exclude_remote_users`, which defaults to False.
When set to True, remote users will not appear in user directory search
results.
### Pull Request Checklist
<!-- Please read
https://element-hq.github.io/synapse/latest/development/contributing_guide.html
before submitting your pull request -->
* [x] Pull request is based on the develop branch
* [x] Pull request includes a [changelog
file](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#changelog ).
The entry should:
- Be a short description of your change which makes sense to users.
"Fixed a bug that prevented receiving messages from other servers."
instead of "Moved X method from `EventStore` to `EventWorkerStore`.".
- Use markdown where necessary, mostly for `code blocks`.
- End with either a period (.) or an exclamation mark (!).
- Start with a capital letter.
- Feel free to credit yourself, by adding a sentence "Contributed by
@github_username." or "Contributed by [Your Name]." to the end of the
entry.
* [x] [Code
style](https://element-hq.github.io/synapse/latest/code_style.html ) is
correct
(run the
[linters](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#run-the-linters ))
---------
Co-authored-by: Andrew Morgan <1342360+anoadragon453@users.noreply.github.com >
2025-05-02 15:38:02 +01:00
Quentin Gliech
b8146d4b03
Allow a few admin APIs used by MAS to run on workers ( #18313 )
...
This should be reviewed commit by commit.
It adds a few admin servlets that are used by MAS when in delegation
mode to workers
---------
Co-authored-by: Olivier 'reivilibre <oliverw@matrix.org >
Co-authored-by: Devon Hudson <devon.dmytro@gmail.com >
Co-authored-by: Andrew Morgan <1342360+anoadragon453@users.noreply.github.com >
2025-05-02 15:37:58 +02:00
Shay
411d239db4
Apply should_drop_federated_event to federation invites ( #18330 )
...
Co-authored-by: Andrew Morgan <1342360+anoadragon453@users.noreply.github.com >
2025-05-02 13:04:01 +00:00
Quentin Gliech
d18edf67d6
Fix lint which broke in #18374 ( #18385 )
...
https://github.com/element-hq/synapse/pull/18374 did not pass linting
but was merged
2025-05-02 12:07:23 +00:00
Andrew Morgan
fd5d3d852d
Don't check the at_hash (access token hash) in OIDC ID Tokens if we don't use the access token ( #18374 )
...
Co-authored-by: Eric Eastwood <erice@element.io >
2025-05-02 12:16:14 +01:00
Shay
ea376126a0
Fix typo in doc for Scheduled Tasks Admin API ( #18384 )
2025-05-02 12:14:31 +01:00
Quentin Gliech
74be5cfdbc
Do not auto-provision missing users & devices when delegating auth to MAS ( #18181 )
...
Since MAS 0.13.0, the provisionning of devices and users is done
synchronously and reliably enough that we don't need to auto-provision
on the Synapse side anymore.
It's important to remove this behaviour if we want to start caching
token introspection results.
2025-05-02 12:13:26 +02:00
Andrew Ferrazzutti
f2ca2e31f7
Readme tweaks ( #18218 )
2025-05-02 12:11:48 +02:00
Shay
6dc1ecd359
Add an Admin API endpoint to fetch scheduled tasks ( #18214 )
2025-05-01 18:30:00 +00:00
Sebastian Spaeth
2965c9970c
docs/workers.md: Add ^/_matrix/federation/v1/event/ to list of delegatable endpoints ( #18377 )
2025-05-01 15:11:59 +01:00