mirror of
https://github.com/element-hq/synapse
synced 2024-08-20 16:40:20 +00:00
============================== Please note that legacy Prometheus metric names are now deprecated and will be removed in Synapse 1.73.0. Server administrators should update their dashboards and alerting rules to avoid using the deprecated metric names. See the [upgrade notes](https://matrix-org.github.io/synapse/v1.69/upgrade.html#upgrading-to-v1690) for more details. Features -------- - Allow application services to set the `origin_server_ts` of a state event by providing the query parameter `ts` in [`PUT /_matrix/client/r0/rooms/{roomId}/state/{eventType}/{stateKey}`](https://spec.matrix.org/v1.4/client-server-api/#put_matrixclientv3roomsroomidstateeventtypestatekey), per [MSC3316](https://github.com/matrix-org/matrix-doc/pull/3316). Contributed by @lukasdenk. ([\#11866](https://github.com/matrix-org/synapse/issues/11866)) - Allow server admins to require a manual approval process before new accounts can be used (using [MSC3866](https://github.com/matrix-org/matrix-spec-proposals/pull/3866)). ([\#13556](https://github.com/matrix-org/synapse/issues/13556)) - Exponentially backoff from backfilling the same event over and over. ([\#13635](https://github.com/matrix-org/synapse/issues/13635), [\#13936](https://github.com/matrix-org/synapse/issues/13936)) - Add cache invalidation across workers to module API. ([\#13667](https://github.com/matrix-org/synapse/issues/13667), [\#13947](https://github.com/matrix-org/synapse/issues/13947)) - Experimental implementation of [MSC3882](https://github.com/matrix-org/matrix-spec-proposals/pull/3882) to allow an existing device/session to generate a login token for use on a new device/session. ([\#13722](https://github.com/matrix-org/synapse/issues/13722), [\#13868](https://github.com/matrix-org/synapse/issues/13868)) - Experimental support for thread-specific receipts ([MSC3771](https://github.com/matrix-org/matrix-spec-proposals/pull/3771)). ([\#13782](https://github.com/matrix-org/synapse/issues/13782), [\#13893](https://github.com/matrix-org/synapse/issues/13893), [\#13932](https://github.com/matrix-org/synapse/issues/13932), [\#13937](https://github.com/matrix-org/synapse/issues/13937), [\#13939](https://github.com/matrix-org/synapse/issues/13939)) - Add experimental support for [MSC3881: Remotely toggle push notifications for another client](https://github.com/matrix-org/matrix-spec-proposals/pull/3881). ([\#13799](https://github.com/matrix-org/synapse/issues/13799), [\#13831](https://github.com/matrix-org/synapse/issues/13831), [\#13860](https://github.com/matrix-org/synapse/issues/13860)) - Keep track when an event pulled over federation fails its signature check so we can intelligently back-off in the future. ([\#13815](https://github.com/matrix-org/synapse/issues/13815)) - Improve validation for the unspecced, internal-only `_matrix/client/unstable/add_threepid/msisdn/submit_token` endpoint. ([\#13832](https://github.com/matrix-org/synapse/issues/13832)) - Faster remote room joins: record _when_ we first partial-join to a room. ([\#13892](https://github.com/matrix-org/synapse/issues/13892)) - Support a `dir` parameter on the `/relations` endpoint per [MSC3715](https://github.com/matrix-org/matrix-doc/pull/3715). ([\#13920](https://github.com/matrix-org/synapse/issues/13920)) - Ask mail servers receiving emails from Synapse to not send automatic replies (e.g. out-of-office responses). ([\#13957](https://github.com/matrix-org/synapse/issues/13957)) Bugfixes -------- - Send push notifications for invites received over federation. ([\#13719](https://github.com/matrix-org/synapse/issues/13719), [\#14014](https://github.com/matrix-org/synapse/issues/14014)) - Fix a long-standing bug where typing events would be accepted from remote servers not present in a room. Also fix a bug where incoming typing events would cause other incoming events to get stuck during a fast join. ([\#13830](https://github.com/matrix-org/synapse/issues/13830)) - Fix a bug introduced in Synapse v1.53.0 where the experimental implementation of [MSC3715](https://github.com/matrix-org/matrix-spec-proposals/pull/3715) would give incorrect results when paginating forward. ([\#13840](https://github.com/matrix-org/synapse/issues/13840)) - Fix access token leak to logs from proxy agent. ([\#13855](https://github.com/matrix-org/synapse/issues/13855)) - Fix `have_seen_event` cache not being invalidated after we persist an event which causes inefficiency effects like extra `/state` federation calls. ([\#13863](https://github.com/matrix-org/synapse/issues/13863)) - Faster room joins: Fix a bug introduced in 1.66.0 where an error would be logged when syncing after joining a room. ([\#13872](https://github.com/matrix-org/synapse/issues/13872)) - Fix a bug introduced in 1.66.0 where some required fields in the pushrules sent to clients were not present anymore. Contributed by Nico. ([\#13904](https://github.com/matrix-org/synapse/issues/13904)) - Fix packaging to include `Cargo.lock` in `sdist`. ([\#13909](https://github.com/matrix-org/synapse/issues/13909)) - Fix a long-standing bug where device updates could cause delays sending out to-device messages over federation. ([\#13922](https://github.com/matrix-org/synapse/issues/13922)) - Fix a bug introduced in v1.68.0 where Synapse would require `setuptools_rust` at runtime, even though the package is only required at build time. ([\#13952](https://github.com/matrix-org/synapse/issues/13952)) - Fix a long-standing bug where `POST /_matrix/client/v3/keys/query` requests could result in excessively large SQL queries. ([\#13956](https://github.com/matrix-org/synapse/issues/13956)) - Fix a performance regression in the `get_users_in_room` database query. Introduced in v1.67.0. ([\#13972](https://github.com/matrix-org/synapse/issues/13972)) - Fix a bug introduced in v1.68.0 bug where Rust extension wasn't built in `release` mode when using `poetry install`. ([\#14009](https://github.com/matrix-org/synapse/issues/14009)) - Do not return an unspecified `original_event` field when using the stable `/relations` endpoint. Introduced in Synapse v1.57.0. ([\#14025](https://github.com/matrix-org/synapse/issues/14025)) - Correctly handle a race with device lists when a remote user leaves during a partial join. ([\#13885](https://github.com/matrix-org/synapse/issues/13885)) - Correctly handle sending local device list updates to remote servers during a partial join. ([\#13934](https://github.com/matrix-org/synapse/issues/13934)) Improved Documentation ---------------------- - Add `worker_main_http_uri` for the worker generator bash script. ([\#13772](https://github.com/matrix-org/synapse/issues/13772)) - Update URL for the NixOS module for Synapse. ([\#13818](https://github.com/matrix-org/synapse/issues/13818)) - Fix a mistake in sso_mapping_providers.md: `map_user_attributes` is expected to return `display_name`, not `displayname`. ([\#13836](https://github.com/matrix-org/synapse/issues/13836)) - Fix a cross-link from the registration admin API to the `registration_shared_secret` configuration documentation. ([\#13870](https://github.com/matrix-org/synapse/issues/13870)) - Update the man page for the `hash_password` script to correct the default number of bcrypt rounds performed. ([\#13911](https://github.com/matrix-org/synapse/issues/13911), [\#13930](https://github.com/matrix-org/synapse/issues/13930)) - Emphasize the right reasons when to use `(room_id, event_id)` in a database schema. ([\#13915](https://github.com/matrix-org/synapse/issues/13915)) - Add instruction to contributing guide for running unit tests in parallel. Contributed by @ashfame. ([\#13928](https://github.com/matrix-org/synapse/issues/13928)) - Clarify that the `auto_join_rooms` config option can also be used with Space aliases. ([\#13931](https://github.com/matrix-org/synapse/issues/13931)) - Add some cross references to worker documentation. ([\#13974](https://github.com/matrix-org/synapse/issues/13974)) - Linkify urls in config documentation. ([\#14003](https://github.com/matrix-org/synapse/issues/14003)) Deprecations and Removals ------------------------- - Remove the `complete_sso_login` method from the Module API which was deprecated in Synapse 1.13.0. ([\#13843](https://github.com/matrix-org/synapse/issues/13843)) - Announce that legacy metric names are deprecated, will be turned off by default in Synapse v1.71.0 and removed altogether in Synapse v1.73.0. See the upgrade notes for more information. ([\#14024](https://github.com/matrix-org/synapse/issues/14024)) Internal Changes ---------------- - Speed up creation of DM rooms. ([\#13487](https://github.com/matrix-org/synapse/issues/13487), [\#13800](https://github.com/matrix-org/synapse/issues/13800)) - Port push rules to using Rust. ([\#13768](https://github.com/matrix-org/synapse/issues/13768), [\#13838](https://github.com/matrix-org/synapse/issues/13838), [\#13889](https://github.com/matrix-org/synapse/issues/13889)) - Optimise get rooms for user calls. Contributed by Nick @ Beeper (@fizzadar). ([\#13787](https://github.com/matrix-org/synapse/issues/13787)) - Update the script which makes full schema dumps. ([\#13792](https://github.com/matrix-org/synapse/issues/13792)) - Use shared methods for cache invalidation when persisting events, remove duplicate codepaths. Contributed by Nick @ Beeper (@fizzadar). ([\#13796](https://github.com/matrix-org/synapse/issues/13796)) - Improve the `synapse.api.auth.Auth` mock used in unit tests. ([\#13809](https://github.com/matrix-org/synapse/issues/13809)) - Faster Remote Room Joins: tell remote homeservers that we are unable to authorise them if they query a room which has partial state on our server. ([\#13823](https://github.com/matrix-org/synapse/issues/13823)) - Carry IdP Session IDs through user-mapping sessions. ([\#13839](https://github.com/matrix-org/synapse/issues/13839)) - Fix the release script not publishing binary wheels. ([\#13850](https://github.com/matrix-org/synapse/issues/13850)) - Raise issue if complement fails with latest deps. ([\#13859](https://github.com/matrix-org/synapse/issues/13859)) - Correct the comments in the complement dockerfile. ([\#13867](https://github.com/matrix-org/synapse/issues/13867)) - Create a new snapshot of the database schema. ([\#13873](https://github.com/matrix-org/synapse/issues/13873)) - Faster room joins: Send device list updates to most servers in rooms with partial state. ([\#13874](https://github.com/matrix-org/synapse/issues/13874), [\#14013](https://github.com/matrix-org/synapse/issues/14013)) - Add comments to the Prometheus recording rules to make it clear which set of rules you need for Grafana or Prometheus Console. ([\#13876](https://github.com/matrix-org/synapse/issues/13876)) - Only pull relevant backfill points from the database based on the current depth and limit (instead of all) every time we want to `/backfill`. ([\#13879](https://github.com/matrix-org/synapse/issues/13879)) - Faster room joins: Avoid waiting for full state when processing `/keys/changes` requests. ([\#13888](https://github.com/matrix-org/synapse/issues/13888)) - Improve backfill robustness by trying more servers when we get a `4xx` error back. ([\#13890](https://github.com/matrix-org/synapse/issues/13890)) - Fix mypy errors with canonicaljson 1.6.3. ([\#13905](https://github.com/matrix-org/synapse/issues/13905)) - Faster remote room joins: correctly handle remote device list updates during a partial join. ([\#13913](https://github.com/matrix-org/synapse/issues/13913)) - Complement image: propagate SIGTERM to all workers. ([\#13914](https://github.com/matrix-org/synapse/issues/13914)) - Update an innaccurate comment in Synapse's upsert database helper. ([\#13924](https://github.com/matrix-org/synapse/issues/13924)) - Update mypy (0.950 -> 0.981) and mypy-zope (0.3.7 -> 0.3.11). ([\#13925](https://github.com/matrix-org/synapse/issues/13925), [\#13993](https://github.com/matrix-org/synapse/issues/13993)) - Use dedicated `get_local_users_in_room(room_id)` function to find local users when calculating users to copy over during a room upgrade. ([\#13960](https://github.com/matrix-org/synapse/issues/13960)) - Refactor language in user directory `_track_user_joined_room` code to make it more clear that we use both local and remote users. ([\#13966](https://github.com/matrix-org/synapse/issues/13966)) - Revert catch-all exceptions being recorded as event pull attempt failures (only handle what we know about). ([\#13969](https://github.com/matrix-org/synapse/issues/13969)) - Speed up calculating push actions in large rooms. ([\#13973](https://github.com/matrix-org/synapse/issues/13973), [\#13992](https://github.com/matrix-org/synapse/issues/13992)) - Enable update notifications from Github's dependabot. ([\#13976](https://github.com/matrix-org/synapse/issues/13976)) - Prototype a workflow to automatically add changelogs to dependabot PRs. ([\#13998](https://github.com/matrix-org/synapse/issues/13998), [\#14011](https://github.com/matrix-org/synapse/issues/14011), [\#14017](https://github.com/matrix-org/synapse/issues/14017), [\#14021](https://github.com/matrix-org/synapse/issues/14021), [\#14027](https://github.com/matrix-org/synapse/issues/14027)) - Fix type annotations to be compatible with new annotations in development versions of twisted. ([\#14012](https://github.com/matrix-org/synapse/issues/14012)) - Clear out stale entries in `event_push_actions_staging` table. ([\#14020](https://github.com/matrix-org/synapse/issues/14020)) - Bump versions of GitHub actions. ([\#13978](https://github.com/matrix-org/synapse/issues/13978), [\#13979](https://github.com/matrix-org/synapse/issues/13979), [\#13980](https://github.com/matrix-org/synapse/issues/13980), [\#13982](https://github.com/matrix-org/synapse/issues/13982), [\#14015](https://github.com/matrix-org/synapse/issues/14015), [\#14019](https://github.com/matrix-org/synapse/issues/14019), [\#14022](https://github.com/matrix-org/synapse/issues/14022), [\#14023](https://github.com/matrix-org/synapse/issues/14023)) -----BEGIN PGP SIGNATURE----- iQGzBAABCgAdFiEEWMTnW8Z8khaaf90R+84KzgcyGG8FAmM8IQMACgkQ+84Kzgcy GG+eewv/fl+SluS/J5xQ/bJU/rCp1TREd29vafWbCapjLFI4g/2CsLjWXXfP+zFi xHbGA/lWK7Vju/SV/9cURbouosxeCtbc5MrB5l2WmQB21Uw1Ql2DUkGBPVQKb45/ OkCG3J5qAID9r+OsGf6Ir1pJ6+38r5zliEuTn7557B5Fuawjbx7BWX5dfotjH49r WvhyKV+2EzVenmA82iLwC+RSykYcbTkCvKyoNd4Ry6oBOIBDFgLQIVivnQp6W/RK CneP7Q64Ga9+WvLUt9Xgp0B1vIWJcPoM9uPeeifb9Pzq7m7jPo48Zld6Sxdp/zAs NrLFdTQa+YfgvyvtxDXr8fLPjJ91F1Gv6wyPPtd57tZDLgcn3U2UMifDAjMgCWKB 7IEKNOH5fSY00q50cnSr2wS2azYPAS4KFfgXArZ0t1RaU2LDkjyZVjJj7eI7zuex rlqVqvZtqjdreOVUBkf401zTD/hD4+Vld8BnbHX3liAcGObOUIRSsGCwhFh6bquw 8hYy9V6Y =wV0r -----END PGP SIGNATURE----- Merge tag 'v1.69.0rc1' into develop Synapse 1.69.0rc1 (2022-10-04) ============================== Please note that legacy Prometheus metric names are now deprecated and will be removed in Synapse 1.73.0. Server administrators should update their dashboards and alerting rules to avoid using the deprecated metric names. See the [upgrade notes](https://matrix-org.github.io/synapse/v1.69/upgrade.html#upgrading-to-v1690) for more details. Features -------- - Allow application services to set the `origin_server_ts` of a state event by providing the query parameter `ts` in [`PUT /_matrix/client/r0/rooms/{roomId}/state/{eventType}/{stateKey}`](https://spec.matrix.org/v1.4/client-server-api/#put_matrixclientv3roomsroomidstateeventtypestatekey), per [MSC3316](https://github.com/matrix-org/matrix-doc/pull/3316). Contributed by @lukasdenk. ([\#11866](https://github.com/matrix-org/synapse/issues/11866)) - Allow server admins to require a manual approval process before new accounts can be used (using [MSC3866](https://github.com/matrix-org/matrix-spec-proposals/pull/3866)). ([\#13556](https://github.com/matrix-org/synapse/issues/13556)) - Exponentially backoff from backfilling the same event over and over. ([\#13635](https://github.com/matrix-org/synapse/issues/13635), [\#13936](https://github.com/matrix-org/synapse/issues/13936)) - Add cache invalidation across workers to module API. ([\#13667](https://github.com/matrix-org/synapse/issues/13667), [\#13947](https://github.com/matrix-org/synapse/issues/13947)) - Experimental implementation of [MSC3882](https://github.com/matrix-org/matrix-spec-proposals/pull/3882) to allow an existing device/session to generate a login token for use on a new device/session. ([\#13722](https://github.com/matrix-org/synapse/issues/13722), [\#13868](https://github.com/matrix-org/synapse/issues/13868)) - Experimental support for thread-specific receipts ([MSC3771](https://github.com/matrix-org/matrix-spec-proposals/pull/3771)). ([\#13782](https://github.com/matrix-org/synapse/issues/13782), [\#13893](https://github.com/matrix-org/synapse/issues/13893), [\#13932](https://github.com/matrix-org/synapse/issues/13932), [\#13937](https://github.com/matrix-org/synapse/issues/13937), [\#13939](https://github.com/matrix-org/synapse/issues/13939)) - Add experimental support for [MSC3881: Remotely toggle push notifications for another client](https://github.com/matrix-org/matrix-spec-proposals/pull/3881). ([\#13799](https://github.com/matrix-org/synapse/issues/13799), [\#13831](https://github.com/matrix-org/synapse/issues/13831), [\#13860](https://github.com/matrix-org/synapse/issues/13860)) - Keep track when an event pulled over federation fails its signature check so we can intelligently back-off in the future. ([\#13815](https://github.com/matrix-org/synapse/issues/13815)) - Improve validation for the unspecced, internal-only `_matrix/client/unstable/add_threepid/msisdn/submit_token` endpoint. ([\#13832](https://github.com/matrix-org/synapse/issues/13832)) - Faster remote room joins: record _when_ we first partial-join to a room. ([\#13892](https://github.com/matrix-org/synapse/issues/13892)) - Support a `dir` parameter on the `/relations` endpoint per [MSC3715](https://github.com/matrix-org/matrix-doc/pull/3715). ([\#13920](https://github.com/matrix-org/synapse/issues/13920)) - Ask mail servers receiving emails from Synapse to not send automatic replies (e.g. out-of-office responses). ([\#13957](https://github.com/matrix-org/synapse/issues/13957)) Bugfixes -------- - Send push notifications for invites received over federation. ([\#13719](https://github.com/matrix-org/synapse/issues/13719), [\#14014](https://github.com/matrix-org/synapse/issues/14014)) - Fix a long-standing bug where typing events would be accepted from remote servers not present in a room. Also fix a bug where incoming typing events would cause other incoming events to get stuck during a fast join. ([\#13830](https://github.com/matrix-org/synapse/issues/13830)) - Fix a bug introduced in Synapse v1.53.0 where the experimental implementation of [MSC3715](https://github.com/matrix-org/matrix-spec-proposals/pull/3715) would give incorrect results when paginating forward. ([\#13840](https://github.com/matrix-org/synapse/issues/13840)) - Fix access token leak to logs from proxy agent. ([\#13855](https://github.com/matrix-org/synapse/issues/13855)) - Fix `have_seen_event` cache not being invalidated after we persist an event which causes inefficiency effects like extra `/state` federation calls. ([\#13863](https://github.com/matrix-org/synapse/issues/13863)) - Faster room joins: Fix a bug introduced in 1.66.0 where an error would be logged when syncing after joining a room. ([\#13872](https://github.com/matrix-org/synapse/issues/13872)) - Fix a bug introduced in 1.66.0 where some required fields in the pushrules sent to clients were not present anymore. Contributed by Nico. ([\#13904](https://github.com/matrix-org/synapse/issues/13904)) - Fix packaging to include `Cargo.lock` in `sdist`. ([\#13909](https://github.com/matrix-org/synapse/issues/13909)) - Fix a long-standing bug where device updates could cause delays sending out to-device messages over federation. ([\#13922](https://github.com/matrix-org/synapse/issues/13922)) - Fix a bug introduced in v1.68.0 where Synapse would require `setuptools_rust` at runtime, even though the package is only required at build time. ([\#13952](https://github.com/matrix-org/synapse/issues/13952)) - Fix a long-standing bug where `POST /_matrix/client/v3/keys/query` requests could result in excessively large SQL queries. ([\#13956](https://github.com/matrix-org/synapse/issues/13956)) - Fix a performance regression in the `get_users_in_room` database query. Introduced in v1.67.0. ([\#13972](https://github.com/matrix-org/synapse/issues/13972)) - Fix a bug introduced in v1.68.0 bug where Rust extension wasn't built in `release` mode when using `poetry install`. ([\#14009](https://github.com/matrix-org/synapse/issues/14009)) - Do not return an unspecified `original_event` field when using the stable `/relations` endpoint. Introduced in Synapse v1.57.0. ([\#14025](https://github.com/matrix-org/synapse/issues/14025)) - Correctly handle a race with device lists when a remote user leaves during a partial join. ([\#13885](https://github.com/matrix-org/synapse/issues/13885)) - Correctly handle sending local device list updates to remote servers during a partial join. ([\#13934](https://github.com/matrix-org/synapse/issues/13934)) Improved Documentation ---------------------- - Add `worker_main_http_uri` for the worker generator bash script. ([\#13772](https://github.com/matrix-org/synapse/issues/13772)) - Update URL for the NixOS module for Synapse. ([\#13818](https://github.com/matrix-org/synapse/issues/13818)) - Fix a mistake in sso_mapping_providers.md: `map_user_attributes` is expected to return `display_name`, not `displayname`. ([\#13836](https://github.com/matrix-org/synapse/issues/13836)) - Fix a cross-link from the registration admin API to the `registration_shared_secret` configuration documentation. ([\#13870](https://github.com/matrix-org/synapse/issues/13870)) - Update the man page for the `hash_password` script to correct the default number of bcrypt rounds performed. ([\#13911](https://github.com/matrix-org/synapse/issues/13911), [\#13930](https://github.com/matrix-org/synapse/issues/13930)) - Emphasize the right reasons when to use `(room_id, event_id)` in a database schema. ([\#13915](https://github.com/matrix-org/synapse/issues/13915)) - Add instruction to contributing guide for running unit tests in parallel. Contributed by @ashfame. ([\#13928](https://github.com/matrix-org/synapse/issues/13928)) - Clarify that the `auto_join_rooms` config option can also be used with Space aliases. ([\#13931](https://github.com/matrix-org/synapse/issues/13931)) - Add some cross references to worker documentation. ([\#13974](https://github.com/matrix-org/synapse/issues/13974)) - Linkify urls in config documentation. ([\#14003](https://github.com/matrix-org/synapse/issues/14003)) Deprecations and Removals ------------------------- - Remove the `complete_sso_login` method from the Module API which was deprecated in Synapse 1.13.0. ([\#13843](https://github.com/matrix-org/synapse/issues/13843)) - Announce that legacy metric names are deprecated, will be turned off by default in Synapse v1.71.0 and removed altogether in Synapse v1.73.0. See the upgrade notes for more information. ([\#14024](https://github.com/matrix-org/synapse/issues/14024)) Internal Changes ---------------- - Speed up creation of DM rooms. ([\#13487](https://github.com/matrix-org/synapse/issues/13487), [\#13800](https://github.com/matrix-org/synapse/issues/13800)) - Port push rules to using Rust. ([\#13768](https://github.com/matrix-org/synapse/issues/13768), [\#13838](https://github.com/matrix-org/synapse/issues/13838), [\#13889](https://github.com/matrix-org/synapse/issues/13889)) - Optimise get rooms for user calls. Contributed by Nick @ Beeper (@fizzadar). ([\#13787](https://github.com/matrix-org/synapse/issues/13787)) - Update the script which makes full schema dumps. ([\#13792](https://github.com/matrix-org/synapse/issues/13792)) - Use shared methods for cache invalidation when persisting events, remove duplicate codepaths. Contributed by Nick @ Beeper (@fizzadar). ([\#13796](https://github.com/matrix-org/synapse/issues/13796)) - Improve the `synapse.api.auth.Auth` mock used in unit tests. ([\#13809](https://github.com/matrix-org/synapse/issues/13809)) - Faster Remote Room Joins: tell remote homeservers that we are unable to authorise them if they query a room which has partial state on our server. ([\#13823](https://github.com/matrix-org/synapse/issues/13823)) - Carry IdP Session IDs through user-mapping sessions. ([\#13839](https://github.com/matrix-org/synapse/issues/13839)) - Fix the release script not publishing binary wheels. ([\#13850](https://github.com/matrix-org/synapse/issues/13850)) - Raise issue if complement fails with latest deps. ([\#13859](https://github.com/matrix-org/synapse/issues/13859)) - Correct the comments in the complement dockerfile. ([\#13867](https://github.com/matrix-org/synapse/issues/13867)) - Create a new snapshot of the database schema. ([\#13873](https://github.com/matrix-org/synapse/issues/13873)) - Faster room joins: Send device list updates to most servers in rooms with partial state. ([\#13874](https://github.com/matrix-org/synapse/issues/13874), [\#14013](https://github.com/matrix-org/synapse/issues/14013)) - Add comments to the Prometheus recording rules to make it clear which set of rules you need for Grafana or Prometheus Console. ([\#13876](https://github.com/matrix-org/synapse/issues/13876)) - Only pull relevant backfill points from the database based on the current depth and limit (instead of all) every time we want to `/backfill`. ([\#13879](https://github.com/matrix-org/synapse/issues/13879)) - Faster room joins: Avoid waiting for full state when processing `/keys/changes` requests. ([\#13888](https://github.com/matrix-org/synapse/issues/13888)) - Improve backfill robustness by trying more servers when we get a `4xx` error back. ([\#13890](https://github.com/matrix-org/synapse/issues/13890)) - Fix mypy errors with canonicaljson 1.6.3. ([\#13905](https://github.com/matrix-org/synapse/issues/13905)) - Faster remote room joins: correctly handle remote device list updates during a partial join. ([\#13913](https://github.com/matrix-org/synapse/issues/13913)) - Complement image: propagate SIGTERM to all workers. ([\#13914](https://github.com/matrix-org/synapse/issues/13914)) - Update an innaccurate comment in Synapse's upsert database helper. ([\#13924](https://github.com/matrix-org/synapse/issues/13924)) - Update mypy (0.950 -> 0.981) and mypy-zope (0.3.7 -> 0.3.11). ([\#13925](https://github.com/matrix-org/synapse/issues/13925), [\#13993](https://github.com/matrix-org/synapse/issues/13993)) - Use dedicated `get_local_users_in_room(room_id)` function to find local users when calculating users to copy over during a room upgrade. ([\#13960](https://github.com/matrix-org/synapse/issues/13960)) - Refactor language in user directory `_track_user_joined_room` code to make it more clear that we use both local and remote users. ([\#13966](https://github.com/matrix-org/synapse/issues/13966)) - Revert catch-all exceptions being recorded as event pull attempt failures (only handle what we know about). ([\#13969](https://github.com/matrix-org/synapse/issues/13969)) - Speed up calculating push actions in large rooms. ([\#13973](https://github.com/matrix-org/synapse/issues/13973), [\#13992](https://github.com/matrix-org/synapse/issues/13992)) - Enable update notifications from Github's dependabot. ([\#13976](https://github.com/matrix-org/synapse/issues/13976)) - Prototype a workflow to automatically add changelogs to dependabot PRs. ([\#13998](https://github.com/matrix-org/synapse/issues/13998), [\#14011](https://github.com/matrix-org/synapse/issues/14011), [\#14017](https://github.com/matrix-org/synapse/issues/14017), [\#14021](https://github.com/matrix-org/synapse/issues/14021), [\#14027](https://github.com/matrix-org/synapse/issues/14027)) - Fix type annotations to be compatible with new annotations in development versions of twisted. ([\#14012](https://github.com/matrix-org/synapse/issues/14012)) - Clear out stale entries in `event_push_actions_staging` table. ([\#14020](https://github.com/matrix-org/synapse/issues/14020)) - Bump versions of GitHub actions. ([\#13978](https://github.com/matrix-org/synapse/issues/13978), [\#13979](https://github.com/matrix-org/synapse/issues/13979), [\#13980](https://github.com/matrix-org/synapse/issues/13980), [\#13982](https://github.com/matrix-org/synapse/issues/13982), [\#14015](https://github.com/matrix-org/synapse/issues/14015), [\#14019](https://github.com/matrix-org/synapse/issues/14019), [\#14022](https://github.com/matrix-org/synapse/issues/14022), [\#14023](https://github.com/matrix-org/synapse/issues/14023))
327 lines
12 KiB
TOML
327 lines
12 KiB
TOML
[tool.towncrier]
|
|
package = "synapse"
|
|
filename = "CHANGES.md"
|
|
directory = "changelog.d"
|
|
issue_format = "[\\#{issue}](https://github.com/matrix-org/synapse/issues/{issue})"
|
|
|
|
[[tool.towncrier.type]]
|
|
directory = "feature"
|
|
name = "Features"
|
|
showcontent = true
|
|
|
|
[[tool.towncrier.type]]
|
|
directory = "bugfix"
|
|
name = "Bugfixes"
|
|
showcontent = true
|
|
|
|
[[tool.towncrier.type]]
|
|
directory = "docker"
|
|
name = "Updates to the Docker image"
|
|
showcontent = true
|
|
|
|
[[tool.towncrier.type]]
|
|
directory = "doc"
|
|
name = "Improved Documentation"
|
|
showcontent = true
|
|
|
|
[[tool.towncrier.type]]
|
|
directory = "removal"
|
|
name = "Deprecations and Removals"
|
|
showcontent = true
|
|
|
|
[[tool.towncrier.type]]
|
|
directory = "misc"
|
|
name = "Internal Changes"
|
|
showcontent = true
|
|
|
|
[tool.black]
|
|
target-version = ['py37', 'py38', 'py39', 'py310']
|
|
# black ignores everything in .gitignore by default, see
|
|
# https://black.readthedocs.io/en/stable/usage_and_configuration/file_collection_and_discovery.html#gitignore
|
|
# Use `extend-exclude` if you want to exclude something in addition to this.
|
|
|
|
[tool.isort]
|
|
line_length = 88
|
|
sections = ["FUTURE", "STDLIB", "THIRDPARTY", "TWISTED", "FIRSTPARTY", "TESTS", "LOCALFOLDER"]
|
|
default_section = "THIRDPARTY"
|
|
known_first_party = ["synapse"]
|
|
known_tests = ["tests"]
|
|
known_twisted = ["twisted", "OpenSSL"]
|
|
multi_line_output = 3
|
|
include_trailing_comma = true
|
|
combine_as_imports = true
|
|
skip_gitignore = true
|
|
|
|
[tool.maturin]
|
|
manifest-path = "rust/Cargo.toml"
|
|
|
|
[tool.poetry]
|
|
name = "matrix-synapse"
|
|
version = "1.69.0rc1"
|
|
description = "Homeserver for the Matrix decentralised comms protocol"
|
|
authors = ["Matrix.org Team and Contributors <packages@matrix.org>"]
|
|
license = "Apache-2.0"
|
|
readme = "README.rst"
|
|
repository = "https://github.com/matrix-org/synapse"
|
|
packages = [
|
|
{ include = "synapse" },
|
|
]
|
|
classifiers = [
|
|
"Development Status :: 5 - Production/Stable",
|
|
"Topic :: Communications :: Chat",
|
|
]
|
|
include = [
|
|
{ path = "AUTHORS.rst", format = "sdist" },
|
|
{ path = "book.toml", format = "sdist" },
|
|
{ path = "changelog.d", format = "sdist" },
|
|
{ path = "CHANGES.md", format = "sdist" },
|
|
{ path = "CONTRIBUTING.md", format = "sdist" },
|
|
{ path = "demo", format = "sdist" },
|
|
{ path = "docs", format = "sdist" },
|
|
{ path = "INSTALL.md", format = "sdist" },
|
|
{ path = "mypy.ini", format = "sdist" },
|
|
{ path = "scripts-dev", format = "sdist" },
|
|
{ path = "synmark", format="sdist" },
|
|
{ path = "sytest-blacklist", format = "sdist" },
|
|
{ path = "tests", format = "sdist" },
|
|
{ path = "UPGRADE.rst", format = "sdist" },
|
|
{ path = "Cargo.toml", format = "sdist" },
|
|
{ path = "Cargo.lock", format = "sdist" },
|
|
{ path = "rust/Cargo.toml", format = "sdist" },
|
|
{ path = "rust/build.rs", format = "sdist" },
|
|
{ path = "rust/src/**", format = "sdist" },
|
|
]
|
|
exclude = [
|
|
{ path = "synapse/*.so", format = "sdist"}
|
|
]
|
|
|
|
build = "build_rust.py"
|
|
|
|
[tool.poetry.scripts]
|
|
synapse_homeserver = "synapse.app.homeserver:main"
|
|
synapse_worker = "synapse.app.generic_worker:main"
|
|
synctl = "synapse._scripts.synctl:main"
|
|
|
|
export_signing_key = "synapse._scripts.export_signing_key:main"
|
|
generate_config = "synapse._scripts.generate_config:main"
|
|
generate_log_config = "synapse._scripts.generate_log_config:main"
|
|
generate_signing_key = "synapse._scripts.generate_signing_key:main"
|
|
hash_password = "synapse._scripts.hash_password:main"
|
|
register_new_matrix_user = "synapse._scripts.register_new_matrix_user:main"
|
|
synapse_port_db = "synapse._scripts.synapse_port_db:main"
|
|
synapse_review_recent_signups = "synapse._scripts.review_recent_signups:main"
|
|
update_synapse_database = "synapse._scripts.update_synapse_database:main"
|
|
|
|
[tool.poetry.dependencies]
|
|
python = "^3.7.1"
|
|
|
|
# Mandatory Dependencies
|
|
# ----------------------
|
|
# we use the TYPE_CHECKER.redefine method added in jsonschema 3.0.0
|
|
jsonschema = ">=3.0.0"
|
|
# frozendict 2.1.2 is broken on Debian 10: https://github.com/Marco-Sulla/python-frozendict/issues/41
|
|
frozendict = ">=1,!=2.1.2"
|
|
# We require 2.1.0 or higher for type hints. Previous guard was >= 1.1.0
|
|
unpaddedbase64 = ">=2.1.0"
|
|
# We require 1.5.0 to work around an issue when running against the C implementation of
|
|
# frozendict: https://github.com/matrix-org/python-canonicaljson/issues/36
|
|
canonicaljson = "^1.5.0"
|
|
# we use the type definitions added in signedjson 1.1.
|
|
signedjson = "^1.1.0"
|
|
# validating SSL certs for IP addresses requires service_identity 18.1.
|
|
service-identity = ">=18.1.0"
|
|
# Twisted 18.9 introduces some logger improvements that the structured
|
|
# logger utilises
|
|
Twisted = {extras = ["tls"], version = ">=18.9.0"}
|
|
treq = ">=15.1"
|
|
# Twisted has required pyopenssl 16.0 since about Twisted 16.6.
|
|
pyOpenSSL = ">=16.0.0"
|
|
PyYAML = ">=3.11"
|
|
pyasn1 = ">=0.1.9"
|
|
pyasn1-modules = ">=0.0.7"
|
|
bcrypt = ">=3.1.7"
|
|
Pillow = ">=5.4.0"
|
|
sortedcontainers = ">=1.4.4"
|
|
pymacaroons = ">=0.13.0"
|
|
msgpack = ">=0.5.2"
|
|
phonenumbers = ">=8.2.0"
|
|
# we use GaugeHistogramMetric, which was added in prom-client 0.4.0.
|
|
prometheus-client = ">=0.4.0"
|
|
# we use `order`, which arrived in attrs 19.2.0.
|
|
# Note: 21.1.0 broke `/sync`, see #9936
|
|
attrs = ">=19.2.0,!=21.1.0"
|
|
netaddr = ">=0.7.18"
|
|
# Jinja 2.x is incompatible with MarkupSafe>=2.1. To ensure that admins do not
|
|
# end up with a broken installation, with recent MarkupSafe but old Jinja, we
|
|
# add a lower bound to the Jinja2 dependency.
|
|
Jinja2 = ">=3.0"
|
|
bleach = ">=1.4.3"
|
|
# We use `ParamSpec` and `Concatenate`, which were added in `typing-extensions` 3.10.0.0.
|
|
# Additionally we need https://github.com/python/typing/pull/817 to allow types to be
|
|
# generic over ParamSpecs.
|
|
typing-extensions = ">=3.10.0.1"
|
|
# We enforce that we have a `cryptography` version that bundles an `openssl`
|
|
# with the latest security patches.
|
|
cryptography = ">=3.4.7"
|
|
# ijson 3.1.4 fixes a bug with "." in property names
|
|
ijson = ">=3.1.4"
|
|
matrix-common = "^1.3.0"
|
|
# We need packaging.requirements.Requirement, added in 16.1.
|
|
packaging = ">=16.1"
|
|
# At the time of writing, we only use functions from the version `importlib.metadata`
|
|
# which shipped in Python 3.8. This corresponds to version 1.4 of the backport.
|
|
importlib_metadata = { version = ">=1.4", python = "<3.8" }
|
|
# This is the most recent version of Pydantic with available on common distros.
|
|
pydantic = ">=1.7.4"
|
|
|
|
# This is for building the rust components during "poetry install", which
|
|
# currently ignores the `build-system.requires` directive (c.f.
|
|
# https://github.com/python-poetry/poetry/issues/6154). Both `pip install` and
|
|
# `poetry build` do the right thing without this explicit dependency.
|
|
#
|
|
# This isn't really a dev-dependency, as `poetry install --no-dev` will fail,
|
|
# but the alternative is to add it to the main list of deps where it isn't
|
|
# needed.
|
|
setuptools_rust = ">=1.3"
|
|
|
|
|
|
# Optional Dependencies
|
|
# ---------------------
|
|
matrix-synapse-ldap3 = { version = ">=0.1", optional = true }
|
|
psycopg2 = { version = ">=2.8", markers = "platform_python_implementation != 'PyPy'", optional = true }
|
|
psycopg2cffi = { version = ">=2.8", markers = "platform_python_implementation == 'PyPy'", optional = true }
|
|
psycopg2cffi-compat = { version = "==1.1", markers = "platform_python_implementation == 'PyPy'", optional = true }
|
|
pysaml2 = { version = ">=4.5.0", optional = true }
|
|
authlib = { version = ">=0.14.0", optional = true }
|
|
# systemd-python is necessary for logging to the systemd journal via
|
|
# `systemd.journal.JournalHandler`, as is documented in
|
|
# `contrib/systemd/log_config.yaml`.
|
|
# Note: systemd-python 231 appears to have been yanked from pypi
|
|
systemd-python = { version = ">=231", optional = true }
|
|
lxml = { version = ">=4.2.0", optional = true }
|
|
sentry-sdk = { version = ">=0.7.2", optional = true }
|
|
opentracing = { version = ">=2.2.0", optional = true }
|
|
jaeger-client = { version = ">=4.0.0", optional = true }
|
|
txredisapi = { version = ">=1.4.7", optional = true }
|
|
hiredis = { version = "*", optional = true }
|
|
Pympler = { version = "*", optional = true }
|
|
parameterized = { version = ">=0.7.4", optional = true }
|
|
idna = { version = ">=2.5", optional = true }
|
|
|
|
[tool.poetry.extras]
|
|
# NB: Packages that should be part of `pip install matrix-synapse[all]` need to be specified
|
|
# twice: once here, and once in the `all` extra.
|
|
matrix-synapse-ldap3 = ["matrix-synapse-ldap3"]
|
|
postgres = ["psycopg2", "psycopg2cffi", "psycopg2cffi-compat"]
|
|
saml2 = ["pysaml2"]
|
|
oidc = ["authlib"]
|
|
# systemd-python is necessary for logging to the systemd journal via
|
|
# `systemd.journal.JournalHandler`, as is documented in
|
|
# `contrib/systemd/log_config.yaml`.
|
|
systemd = ["systemd-python"]
|
|
url_preview = ["lxml"]
|
|
sentry = ["sentry-sdk"]
|
|
opentracing = ["jaeger-client", "opentracing"]
|
|
jwt = ["authlib"]
|
|
# hiredis is not a *strict* dependency, but it makes things much faster.
|
|
# (if it is not installed, we fall back to slow code.)
|
|
redis = ["txredisapi", "hiredis"]
|
|
# Required to use experimental `caches.track_memory_usage` config option.
|
|
cache_memory = ["pympler"]
|
|
test = ["parameterized", "idna"]
|
|
|
|
# The duplication here is awful. I hate hate hate hate hate it. However, for now I want
|
|
# to ensure you can still `pip install matrix-synapse[all]` like today. Two motivations:
|
|
# 1) for new installations, I want instructions in existing documentation and tutorials
|
|
# out there to still work.
|
|
# 2) I don't want to hard-code a list of extras into CI if I can help it. The ideal
|
|
# solution here would be something like https://github.com/python-poetry/poetry/issues/3413
|
|
# Poetry 1.2's dependency groups might make this easier. But I'm not trying that out
|
|
# until there's a stable release of 1.2.
|
|
#
|
|
# NB: the strings in this list must be *package* names, not extra names.
|
|
# Some of our extra names _are_ package names, which can lead to great confusion.
|
|
all = [
|
|
# matrix-synapse-ldap3
|
|
"matrix-synapse-ldap3",
|
|
# postgres
|
|
"psycopg2", "psycopg2cffi", "psycopg2cffi-compat",
|
|
# saml2
|
|
"pysaml2",
|
|
# oidc and jwt
|
|
"authlib",
|
|
# url_preview
|
|
"lxml",
|
|
# sentry
|
|
"sentry-sdk",
|
|
# opentracing
|
|
"jaeger-client", "opentracing",
|
|
# redis
|
|
"txredisapi", "hiredis",
|
|
# cache_memory
|
|
"pympler",
|
|
# omitted:
|
|
# - test: it's useful to have this separate from dev deps in the olddeps job
|
|
# - systemd: this is a system-based requirement
|
|
]
|
|
|
|
[tool.poetry.dev-dependencies]
|
|
## We pin black so that our tests don't start failing on new releases.
|
|
isort = "==5.10.1"
|
|
black = "==22.3.0"
|
|
flake8-comprehensions = "*"
|
|
flake8-bugbear = "==21.3.2"
|
|
flake8 = "*"
|
|
|
|
# Typechecking
|
|
mypy = "*"
|
|
mypy-zope = "*"
|
|
types-bleach = ">=4.1.0"
|
|
types-commonmark = ">=0.9.2"
|
|
types-jsonschema = ">=3.2.0"
|
|
types-opentracing = ">=2.4.2"
|
|
types-Pillow = ">=8.3.4"
|
|
types-psycopg2 = ">=2.9.9"
|
|
types-pyOpenSSL = ">=20.0.7"
|
|
types-PyYAML = ">=5.4.10"
|
|
types-requests = ">=2.26.0"
|
|
types-setuptools = ">=57.4.0"
|
|
|
|
# Dependencies which are exclusively required by unit test code. This is
|
|
# NOT a list of all modules that are necessary to run the unit tests.
|
|
# Tests assume that all optional dependencies are installed.
|
|
# parameterized<0.7.4 can create classes with names that would normally be invalid
|
|
# identifiers. trial really does not like this when running with multiple workers.
|
|
parameterized = ">=0.7.4"
|
|
idna = ">=2.5"
|
|
|
|
# The following are used by the release script
|
|
click = "==8.1.1"
|
|
# GitPython was == 3.1.14; bumped to 3.1.20, the first release with type hints.
|
|
GitPython = ">=3.1.20"
|
|
commonmark = "==0.9.1"
|
|
pygithub = "==1.55"
|
|
# The following are executed as commands by the release script.
|
|
twine = "*"
|
|
# Towncrier min version comes from #3425. Rationale unclear.
|
|
towncrier = ">=18.6.0rc1"
|
|
|
|
[build-system]
|
|
requires = ["poetry-core>=1.0.0", "setuptools_rust>=1.3"]
|
|
build-backend = "poetry.core.masonry.api"
|
|
|
|
|
|
[tool.cibuildwheel]
|
|
# Skip unsupported platforms (by us or by Rust).
|
|
skip = "cp36* *-musllinux_i686"
|
|
|
|
# We need a rust compiler
|
|
before-all = "curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain stable -y"
|
|
environment= { PATH = "$PATH:$HOME/.cargo/bin" }
|
|
|
|
# For some reason if we don't manually clean the build directory we
|
|
# can end up polluting the next build with a .so that is for the wrong
|
|
# Python version.
|
|
before-build = "rm -rf {project}/build"
|
|
build-frontend = "build"
|
|
test-command = "python -c 'from synapse.synapse_rust import sum_as_string; print(sum_as_string(1, 2))'"
|