Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
4906771
Faster redis replication handling (#19138)
erikjohnston Nov 5, 2025
d3ffd04
Fix spelling (#19145)
erikjohnston Nov 5, 2025
6790312
Fixup logcontexts after replication PR. (#19146)
erikjohnston Nov 5, 2025
fcac7e0
Write union types as `X | Y` where possible (#19111)
AndrewFerr Nov 6, 2025
077a6f7
Merge branch 'release-v1.142' into develop
anoadragon453 Nov 7, 2025
8580ab6
Add `delayed_events` table to boolean column port (#19155)
AndrewFerr Nov 10, 2025
378c5c8
Document Nginx Proxy Manager configuration steps (#19136)
Sharakea Nov 10, 2025
a50923b
Improve documentation around streams, particularly ID generators and …
reivilibre Nov 10, 2025
dc7f01f
register_new_matrix_user: Support multiple config files (#18784)
V02460 Nov 10, 2025
674b932
Bump sentry-sdk from 2.34.1 to 2.43.0 (#19157)
dependabot[bot] Nov 10, 2025
a10e238
Bump docker/metadata-action from 5.8.0 to 5.9.0 (#19161)
dependabot[bot] Nov 10, 2025
8fa7d4a
Ignore Python language refactors (`.git-blame-ignore-revs`) (#19150)
MadLittleMods Nov 10, 2025
91c2845
Bump pydantic from 2.12.3 to 2.12.4 (#19158)
dependabot[bot] Nov 10, 2025
70e6cc0
Bump pyo3-log from 0.13.1 to 0.13.2 (#19156)
dependabot[bot] Nov 10, 2025
2e66cf1
Bump types-netaddr from 1.3.0.20240530 to 1.3.0.20251108 (#19160)
dependabot[bot] Nov 10, 2025
03e873e
Bump cryptography from 43.0.3 to 45.0.7 (#19159)
dependabot[bot] Nov 11, 2025
9c67666
Merge branch 'master' of github.com:element-hq/synapse into develop
anoadragon453 Nov 11, 2025
2c91896
Run trial tests on Python 3.14 in PRs (#19135)
anoadragon453 Nov 12, 2025
9722e05
Update `pyproject.toml` to be compatible with other standard Python p…
anoadragon453 Nov 12, 2025
3ba3c7f
Reduce cardinality of metrics on event persister (#19133)
erikjohnston Nov 12, 2025
97cc05d
Bump lower bounds of unit test exclusive dependencies for Python 3.10…
AndrewFerr Nov 12, 2025
df80288
Further reduce cardinality of metrics on event persister (#19168)
erikjohnston Nov 12, 2025
e67ba69
Provide same `servers` list in s2s alias results as c2s. (#18970)
jevolk Nov 13, 2025
938c974
Add a shortcut return when there are no events to purge. (#19093)
reivilibre Nov 13, 2025
b9dda0f
Restore printing `sentinel` for `log_record.request` (#19172)
MadLittleMods Nov 13, 2025
47d24bd
Add debug logs to track `Clock` callbacks (#19173)
MadLittleMods Nov 13, 2025
4494cc0
Point out which event caused the exception when checking MSC4293 reda…
MadLittleMods Nov 13, 2025
9e23cde
MSC4140: Remove auth from delayed event management endpoints (#19152)
AndrewFerr Nov 13, 2025
5d545d1
Remove support for PostgreSQL 13 (#19170)
devonh Nov 13, 2025
408a05e
Fix potential lost logcontext when `PerDestinationQueue.shutdown(...)…
MadLittleMods Nov 13, 2025
8da8d4b
Remove explicit python 3.8/9 skips (#19177)
anoadragon453 Nov 14, 2025
edc0de9
Fix bad deferred logcontext handling (#19180)
MadLittleMods Nov 14, 2025
19251fc
Bump bytes from 1.10.1 to 1.11.0 (#19193)
dependabot[bot] Nov 17, 2025
fca80e2
Bump tomli from 2.2.1 to 2.3.0 (#19194)
dependabot[bot] Nov 17, 2025
26ddedb
Bump ruff from 0.14.3 to 0.14.5 (#19196)
dependabot[bot] Nov 17, 2025
ce65b5c
Bump sentry-sdk from 2.43.0 to 2.44.0 (#19197)
dependabot[bot] Nov 17, 2025
34d93c9
Bump click from 8.1.8 to 8.3.1 (#19195)
dependabot[bot] Nov 17, 2025
322481c
Run background updates on all databases (#19181)
devonh Nov 17, 2025
bc42899
Allow subpaths in MAS endpoints (#19186)
devonh Nov 18, 2025
1b24a14
Merge branch 'master' into develop
devonh Nov 18, 2025
f5bf02e
1.143.0rc1
devonh Nov 18, 2025
2cffd75
Fix duplicate poetry version from merging patch release
devonh Nov 19, 2025
b631bf7
1.143.0rc2
devonh Nov 19, 2025
3779c59
move postgres 13 deprecation note to top of changelog
anoadragon453 Nov 19, 2025
2eb76b4
1.143.0
devonh Nov 25, 2025
87d6e27
Capitalize Synapse in changelog
devonh Nov 25, 2025
90c2c97
Merge remote-tracking branch 'upstream/release-v1.143' into famedly-r…
jason-famedly Dec 16, 2025
aedcd97
Update Changlog
jason-famedly Dec 16, 2025
1158faf
bump: codecov-action to v5
jason-famedly Dec 17, 2025
cced457
ci: generate xml coverage file
jason-famedly Dec 17, 2025
af6db09
ci: use oidc for codecov access
jason-famedly Dec 17, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
3 changes: 1 addition & 2 deletions .ci/scripts/auditwheel_wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
import argparse
import os
import subprocess
from typing import Optional
from zipfile import ZipFile

from packaging.tags import Tag
Expand Down Expand Up @@ -80,7 +79,7 @@ def cpython(wheel_file: str, name: str, version: Version, tag: Tag) -> str:
return new_wheel_file


def main(wheel_file: str, dest_dir: str, archs: Optional[str]) -> None:
def main(wheel_file: str, dest_dir: str, archs: str | None) -> None:
"""Entry point"""

# Parse the wheel file name into its parts. Note that `parse_wheel_filename`
Expand Down
41 changes: 25 additions & 16 deletions .ci/scripts/calculate_jobs.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,46 +35,55 @@ def set_output(key: str, value: str):

# First calculate the various trial jobs.
#
# For PRs, we only run each type of test with the oldest Python version supported (which
# is Python 3.10 right now)
# For PRs, we only run each type of test with the oldest and newest Python
# version that's supported. The oldest version ensures we don't accidentally
# introduce syntax or code that's too new, and the newest ensures we don't use
# code that's been dropped in the latest supported Python version.

trial_sqlite_tests = [
{
"python-version": "3.10",
"database": "sqlite",
"extras": "all",
}
},
{
"python-version": "3.14",
"database": "sqlite",
"extras": "all",
},
]

if not IS_PR:
# Otherwise, check all supported Python versions.
#
# Avoiding running all of these versions on every PR saves on CI time.
trial_sqlite_tests.extend(
{
"python-version": version,
"database": "sqlite",
"extras": "all",
}
for version in ("3.11", "3.12", "3.13", "3.14")
for version in ("3.11", "3.12", "3.13")
)

# Only test postgres against the earliest and latest Python versions that we
# support in order to save on CI time.
trial_postgres_tests = [
{
"python-version": "3.10",
"database": "postgres",
"postgres-version": "13",
"postgres-version": "14",
"extras": "all",
}
},
{
"python-version": "3.14",
"database": "postgres",
"postgres-version": "17",
"extras": "all",
},
]

if not IS_PR:
trial_postgres_tests.append(
{
"python-version": "3.14",
"database": "postgres",
"postgres-version": "17",
"extras": "all",
}
)

# Ensure that Synapse passes unit tests even with no extra dependencies installed.
trial_no_extra_tests = [
{
"python-version": "3.10",
Expand Down
23 changes: 13 additions & 10 deletions .ci/scripts/prepare_old_deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,23 @@ export VIRTUALENV_NO_DOWNLOAD=1
# to select the lowest possible versions, rather than resorting to this sed script.

# Patch the project definitions in-place:
# - Replace all lower and tilde bounds with exact bounds
# - Replace all caret bounds---but not the one that defines the supported Python version!
# - Delete all lines referring to psycopg2 --- so no testing of postgres support.
# - `-E` use extended regex syntax.
# - Don't modify the line that defines required Python versions.
# - Replace all lower and tilde bounds with exact bounds.
# - Replace all caret bounds with exact bounds.
# - Delete all lines referring to psycopg2 - so no testing of postgres support.
# - Use pyopenssl 17.0, which is the oldest version that works with
# a `cryptography` compiled against OpenSSL 1.1.
# - Omit systemd: we're not logging to journal here.

sed -i \
-e "s/[~>]=/==/g" \
-e '/^python = "^/!s/\^/==/g' \
-e "/psycopg2/d" \
-e 's/pyOpenSSL = "==16.0.0"/pyOpenSSL = "==17.0.0"/' \
-e '/systemd/d' \
pyproject.toml
sed -i -E '
/^\s*requires-python\s*=/b
s/[~>]=/==/g
s/\^/==/g
/psycopg2/d
s/pyOpenSSL\s*==\s*16\.0\.0"/pyOpenSSL==17.0.0"/
/systemd/d
' pyproject.toml

echo "::group::Patched pyproject.toml"
cat pyproject.toml
Expand Down
5 changes: 5 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,8 @@ c4268e3da64f1abb5b31deaeb5769adb6510c0a7
# Update black to 23.1.0 (https://github.com/matrix-org/synapse/pull/15103)
9bb2eac71962970d02842bca441f4bcdbbf93a11

# Use type hinting generics in standard collections (https://github.com/element-hq/synapse/pull/19046)
fc244bb592aa481faf28214a2e2ce3bb4e95d990

# Write union types as X | Y where possible (https://github.com/element-hq/synapse/pull/19111)
fcac7e0282b074d4bd3414d1c9c181e9701875d9
2 changes: 1 addition & 1 deletion .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ jobs:
uses: sigstore/cosign-installer@faadad0cce49287aee09b3a48701e75088a2c6ad # v4.0.0

- name: Calculate docker image tag
uses: docker/metadata-action@c1e51972afc2121e065aed6d45c65596fe445f3f # v5.8.0
uses: docker/metadata-action@318604b99e75e41977312d83839a89be02ca4893 # v5.9.0
with:
images: ${{ matrix.repository }}
flavor: |
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/famedly-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -252,10 +252,11 @@ jobs:
-exec echo "::endgroup::" \;
|| true
- run: poetry run coverage combine
- run: poetry run coverage xml
- name: Codecov - Upload coverage
uses: codecov/codecov-action@v4
uses: codecov/codecov-action@v5
with:
token: ${{secrets.CODECOV_TOKEN}}
use_oidc: true

sytest:
if: ${{ !failure() && !cancelled() }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/push_complement_image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
password: ${{ secrets.GITHUB_TOKEN }}
- name: Work out labels for complement image
id: meta
uses: docker/metadata-action@c1e51972afc2121e065aed6d45c65596fe445f3f # v5.8.0
uses: docker/metadata-action@318604b99e75e41977312d83839a89be02ca4893 # v5.9.0
with:
images: ghcr.io/${{ github.repository }}/complement-synapse
tags: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -617,7 +617,7 @@ jobs:
matrix:
include:
- python-version: "3.10"
postgres-version: "13"
postgres-version: "14"

- python-version: "3.14"
postgres-version: "17"
Expand Down
88 changes: 88 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,91 @@
# Synapse 1.143.0 (2025-11-25)

## Dropping support for PostgreSQL 13

In line with our [deprecation policy](https://github.com/element-hq/synapse/blob/develop/docs/deprecation_policy.md), we've dropped
support for PostgreSQL 13, as it is no longer supported upstream.
This release of Synapse requires PostgreSQL 14+.

No significant changes since 1.143.0rc2.


### Famedly additions for v1.143.0_1
- fix: docs url broken on /version ([\#219](https://github.com/famedly/synapse/pull/219)) (FrenchgGithubUser)
- fix: provide remote servers a way to find out about an event created during the remote join handshake ([\#71](https://github.com/famedly/synapse/pull/71)) (FrenchgGithubUser)


# synapse 1.143.0rc2 (2025-11-18)

## Dropping support for PostgreSQL 13

In line with our [deprecation policy](https://github.com/element-hq/synapse/blob/develop/docs/deprecation_policy.md), we've dropped
support for PostgreSQL 13, as it is no longer supported upstream.
This release of Synapse requires PostgreSQL 14+.


## Internal Changes

- Fixes docker image creation in the release workflow.



# Synapse 1.143.0rc1 (2025-11-18)

## Features

- Support multiple config files in `register_new_matrix_user`. ([\#18784](https://github.com/element-hq/synapse/issues/18784))
- Remove authentication from `POST /_matrix/client/v1/delayed_events`, and allow calling this endpoint with the update action to take (`send`/`cancel`/`restart`) in the request path instead of the body. ([\#19152](https://github.com/element-hq/synapse/issues/19152))

## Bugfixes

- Fixed a longstanding bug where background updates were only run on the `main` database. ([\#19181](https://github.com/element-hq/synapse/issues/19181))
- Fixed a bug introduced in v1.142.0 preventing subpaths in MAS endpoints from working. ([\#19186](https://github.com/element-hq/synapse/issues/19186))
- Fix the SQLite-to-PostgreSQL migration script to correctly migrate a boolean column in the `delayed_events` table. ([\#19155](https://github.com/element-hq/synapse/issues/19155))

## Improved Documentation

- Improve documentation around streams, particularly ID generators and adding new streams. ([\#18943](https://github.com/element-hq/synapse/issues/18943))

## Deprecations and Removals

- Remove support for PostgreSQL 13. ([\#19170](https://github.com/element-hq/synapse/issues/19170))

## Internal Changes

- Provide additional servers with federation room directory results. ([\#18970](https://github.com/element-hq/synapse/issues/18970))
- Add a shortcut return when there are no events to purge. ([\#19093](https://github.com/element-hq/synapse/issues/19093))
- Write union types as `X | Y` where possible, as per PEP 604, added in Python 3.10. ([\#19111](https://github.com/element-hq/synapse/issues/19111))
- Reduce cardinality of `synapse_storage_events_persisted_events_sep_total` metric by removing `origin_entity` label. This also separates out events sent by local application services by changing the `origin_type` for such events to `application_service`. The `type` field also only tracks common event types, and anything else is bucketed under `*other*`. ([\#19133](https://github.com/element-hq/synapse/issues/19133), [\#19168](https://github.com/element-hq/synapse/issues/19168))
- Run trial tests on Python 3.14 for PRs. ([\#19135](https://github.com/element-hq/synapse/issues/19135))
- Update `pyproject.toml` project metadata to be compatible with standard Python packaging tooling. ([\#19137](https://github.com/element-hq/synapse/issues/19137))
- Minor speed up of processing of inbound replication. ([\#19138](https://github.com/element-hq/synapse/issues/19138), [\#19145](https://github.com/element-hq/synapse/issues/19145), [\#19146](https://github.com/element-hq/synapse/issues/19146))
- Ignore recent Python language refactors from git blame (`.git-blame-ignore-revs`). ([\#19150](https://github.com/element-hq/synapse/issues/19150))
- Bump lower bounds of dependencies `parameterized` to `0.9.0` and `idna` to `3.3` as those are the first to advertise support for Python 3.10. ([\#19167](https://github.com/element-hq/synapse/issues/19167))
- Point out which event caused the exception when checking [MSC4293](https://github.com/matrix-org/matrix-spec-proposals/pull/4293) redactions. ([\#19169](https://github.com/element-hq/synapse/issues/19169))
- Restore printing `sentinel` for the log record `request` when no logcontext is active. ([\#19172](https://github.com/element-hq/synapse/issues/19172))
- Add debug logs to track `Clock` utilities. ([\#19173](https://github.com/element-hq/synapse/issues/19173))
- Remove explicit python version skips in `cibuildwheel` config as it's no longer required after [#19137](https://github.com/element-hq/synapse/pull/19137). ([\#19177](https://github.com/element-hq/synapse/issues/19177))
- Fix potential lost logcontext when `PerDestinationQueue.shutdown(...)` is called. ([\#19178](https://github.com/element-hq/synapse/issues/19178))
- Fix bad deferred logcontext handling across the codebase. ([\#19180](https://github.com/element-hq/synapse/issues/19180))



### Updates to locked dependencies

* Bump bytes from 1.10.1 to 1.11.0. ([\#19193](https://github.com/element-hq/synapse/issues/19193))
* Bump click from 8.1.8 to 8.3.1. ([\#19195](https://github.com/element-hq/synapse/issues/19195))
* Bump cryptography from 43.0.3 to 45.0.7. ([\#19159](https://github.com/element-hq/synapse/issues/19159))
* Bump docker/metadata-action from 5.8.0 to 5.9.0. ([\#19161](https://github.com/element-hq/synapse/issues/19161))
* Bump pydantic from 2.12.3 to 2.12.4. ([\#19158](https://github.com/element-hq/synapse/issues/19158))
* Bump pyo3-log from 0.13.1 to 0.13.2. ([\#19156](https://github.com/element-hq/synapse/issues/19156))
* Bump ruff from 0.14.3 to 0.14.5. ([\#19196](https://github.com/element-hq/synapse/issues/19196))
* Bump sentry-sdk from 2.34.1 to 2.43.0. ([\#19157](https://github.com/element-hq/synapse/issues/19157))
* Bump sentry-sdk from 2.43.0 to 2.44.0. ([\#19197](https://github.com/element-hq/synapse/issues/19197))
* Bump tomli from 2.2.1 to 2.3.0. ([\#19194](https://github.com/element-hq/synapse/issues/19194))
* Bump types-netaddr from 1.3.0.20240530 to 1.3.0.20251108. ([\#19160](https://github.com/element-hq/synapse/issues/19160))



# Synapse 1.142.1 (2025-11-18)

## Bugfixes
Expand Down
8 changes: 4 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions contrib/cmdclient/console.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@
import time
import urllib
from http import TwistedHttpClient
from typing import Optional

import urlparse
from signedjson.key import NACL_ED25519, decode_verify_key_bytes
Expand Down Expand Up @@ -726,7 +725,7 @@ def _run_and_pprint(
method,
path,
data=None,
query_params: Optional[dict] = None,
query_params: dict | None = None,
alt_text=None,
):
"""Runs an HTTP request and pretty prints the output.
Expand Down
9 changes: 4 additions & 5 deletions contrib/cmdclient/http.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
import json
import urllib
from pprint import pformat
from typing import Optional

from twisted.internet import defer, reactor
from twisted.web.client import Agent, readBody
Expand Down Expand Up @@ -90,7 +89,7 @@ def get_json(self, url, args=None):
body = yield readBody(response)
return json.loads(body)

def _create_put_request(self, url, json_data, headers_dict: Optional[dict] = None):
def _create_put_request(self, url, json_data, headers_dict: dict | None = None):
"""Wrapper of _create_request to issue a PUT request"""
headers_dict = headers_dict or {}

Expand All @@ -101,7 +100,7 @@ def _create_put_request(self, url, json_data, headers_dict: Optional[dict] = Non
"PUT", url, producer=_JsonProducer(json_data), headers_dict=headers_dict
)

def _create_get_request(self, url, headers_dict: Optional[dict] = None):
def _create_get_request(self, url, headers_dict: dict | None = None):
"""Wrapper of _create_request to issue a GET request"""
return self._create_request("GET", url, headers_dict=headers_dict or {})

Expand All @@ -113,7 +112,7 @@ def do_request(
data=None,
qparams=None,
jsonreq=True,
headers: Optional[dict] = None,
headers: dict | None = None,
):
headers = headers or {}

Expand All @@ -138,7 +137,7 @@ def do_request(

@defer.inlineCallbacks
def _create_request(
self, method, url, producer=None, headers_dict: Optional[dict] = None
self, method, url, producer=None, headers_dict: dict | None = None
):
"""Creates and sends a request to the given url"""
headers_dict = headers_dict or {}
Expand Down
Loading
Loading