From bf69b574226192b946aeaf7a72a39457a3792e41 Mon Sep 17 00:00:00 2001 From: Patrick Cloke Date: Thu, 2 Nov 2023 10:00:18 -0400 Subject: [PATCH 1/7] Fix "'int' object is not iterable" error in set_device_id_for_pushers background update (#16594) A regression from removing the cursor_to_dict call, adds back the wrapping into a tuple. --- changelog.d/16594.bugfix | 1 + synapse/storage/databases/main/pusher.py | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) create mode 100644 changelog.d/16594.bugfix diff --git a/changelog.d/16594.bugfix b/changelog.d/16594.bugfix new file mode 100644 index 000000000000..701fa0dcdc17 --- /dev/null +++ b/changelog.d/16594.bugfix @@ -0,0 +1 @@ +Fix "'int' object is not iterable" error in `set_device_id_for_pushers` background update introduced in Synapse 1.95.0. diff --git a/synapse/storage/databases/main/pusher.py b/synapse/storage/databases/main/pusher.py index a6a1671bd649..8f36cfce1245 100644 --- a/synapse/storage/databases/main/pusher.py +++ b/synapse/storage/databases/main/pusher.py @@ -601,7 +601,7 @@ def set_device_id_for_pushers_txn(txn: LoggingTransaction) -> int: (last_pusher_id, batch_size), ) - rows = txn.fetchall() + rows = cast(List[Tuple[int, Optional[str], Optional[str]]], txn.fetchall()) if len(rows) == 0: return 0 @@ -617,7 +617,7 @@ def set_device_id_for_pushers_txn(txn: LoggingTransaction) -> int: txn=txn, table="pushers", key_names=("id",), - key_values=[row[0] for row in rows], + key_values=[(row[0],) for row in rows], value_names=("device_id", "access_token"), # If there was already a device_id on the pusher, we only want to clear # the access_token column, so we keep the existing device_id. Otherwise, From ff0148a165d8c6405319d177f90b817f14b92040 Mon Sep 17 00:00:00 2001 From: Patrick Cloke Date: Thu, 16 Nov 2023 12:58:00 -0500 Subject: [PATCH 2/7] 1.96.0 --- CHANGES.md | 9 +++++++++ changelog.d/16594.bugfix | 1 - debian/changelog | 6 ++++++ pyproject.toml | 2 +- 4 files changed, 16 insertions(+), 2 deletions(-) delete mode 100644 changelog.d/16594.bugfix diff --git a/CHANGES.md b/CHANGES.md index 2e7f1992992a..23aa629eabbe 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,3 +1,12 @@ +# Synapse 1.96.0 (2023-11-16) + +### Bugfixes + +- Fix "'int' object is not iterable" error in `set_device_id_for_pushers` background update introduced in Synapse 1.95.0. ([\#16594](https://github.com/matrix-org/synapse/issues/16594)) + + + + # Synapse 1.96.0rc1 (2023-10-31) ### Features diff --git a/changelog.d/16594.bugfix b/changelog.d/16594.bugfix deleted file mode 100644 index 701fa0dcdc17..000000000000 --- a/changelog.d/16594.bugfix +++ /dev/null @@ -1 +0,0 @@ -Fix "'int' object is not iterable" error in `set_device_id_for_pushers` background update introduced in Synapse 1.95.0. diff --git a/debian/changelog b/debian/changelog index cbfcb8f44d05..ab7faa056f32 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +matrix-synapse-py3 (1.96.0) stable; urgency=medium + + * New synapse release 1.96.0. + + -- Synapse Packaging team Thu, 16 Nov 2023 17:54:26 +0000 + matrix-synapse-py3 (1.96.0~rc1) stable; urgency=medium * New Synapse release 1.96.0rc1. diff --git a/pyproject.toml b/pyproject.toml index 23e00043955f..daf5f5baa2db 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -96,7 +96,7 @@ module-name = "synapse.synapse_rust" [tool.poetry] name = "matrix-synapse" -version = "1.96.0rc1" +version = "1.96.0" description = "Homeserver for the Matrix decentralised comms protocol" authors = ["Matrix.org Team and Contributors "] license = "Apache-2.0" From 2de2258bd299712942b08dbb09928b7f3a294c83 Mon Sep 17 00:00:00 2001 From: Patrick Cloke Date: Thu, 16 Nov 2023 13:01:32 -0500 Subject: [PATCH 3/7] Add blogpost link to changelog. --- CHANGES.md | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 23aa629eabbe..5facd2bfa383 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,11 +1,17 @@ # Synapse 1.96.0 (2023-11-16) -### Bugfixes +Synapse will soon be getting forked by Element under an AGPLv3.0 licence (with +CLA, for proprietary dual licensing). You can read more about this here: -- Fix "'int' object is not iterable" error in `set_device_id_for_pushers` background update introduced in Synapse 1.95.0. ([\#16594](https://github.com/matrix-org/synapse/issues/16594)) +* https://matrix.org/blog/2023/11/06/future-of-synapse-dendrite/ +* https://element.io/blog/element-to-adopt-agplv3/ +Any changes needed by server administrators will be communicated via our usual +announcements channels, but we are striving to make this as seamless as possible. +### Bugfixes +- Fix "'int' object is not iterable" error in `set_device_id_for_pushers` background update introduced in Synapse 1.95.0. ([\#16594](https://github.com/matrix-org/synapse/issues/16594)) # Synapse 1.96.0rc1 (2023-10-31) From 47c682101fe3097533e0b8d679537a3134ecec99 Mon Sep 17 00:00:00 2001 From: Patrick Cloke Date: Fri, 17 Nov 2023 07:42:49 -0500 Subject: [PATCH 4/7] Fix building wheels in CI. (#16653) pip was using a vendored setuptools that was incompatible with Python 3.12. Upgrading cibuildwheels to a version with a newer version of pip (and thus a newer version of setuptools) fixes the issue. --- .github/workflows/release-artifacts.yml | 2 +- changelog.d/16653.misc | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) create mode 100644 changelog.d/16653.misc diff --git a/.github/workflows/release-artifacts.yml b/.github/workflows/release-artifacts.yml index fed3a4158653..8019f4c250af 100644 --- a/.github/workflows/release-artifacts.yml +++ b/.github/workflows/release-artifacts.yml @@ -130,7 +130,7 @@ jobs: python-version: "3.x" - name: Install cibuildwheel - run: python -m pip install cibuildwheel==2.9.0 + run: python -m pip install cibuildwheel==2.16.2 - name: Set up QEMU to emulate aarch64 if: matrix.arch == 'aarch64' diff --git a/changelog.d/16653.misc b/changelog.d/16653.misc new file mode 100644 index 000000000000..9ee7b272261a --- /dev/null +++ b/changelog.d/16653.misc @@ -0,0 +1 @@ +Fix building of wheels in CI. From 76f990c244658285d9fe24c426b5114a21053e29 Mon Sep 17 00:00:00 2001 From: Patrick Cloke Date: Fri, 17 Nov 2023 07:51:59 -0500 Subject: [PATCH 5/7] 1.96.1 --- CHANGES.md | 8 ++++++++ changelog.d/16653.misc | 1 - debian/changelog | 6 ++++++ pyproject.toml | 2 +- 4 files changed, 15 insertions(+), 2 deletions(-) delete mode 100644 changelog.d/16653.misc diff --git a/CHANGES.md b/CHANGES.md index 5facd2bfa383..daa45016947b 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,3 +1,11 @@ +# Synapse 1.96.1 (2023-11-17) + +This minor release was needed only because of CI-related trouble on [v1.96.0](https://github.com/matrix-org/synapse/releases/tag/v1.96.0), which was never released. + +### Internal Changes + +- Fix building of wheels in CI. ([\#16653](https://github.com/matrix-org/synapse/issues/16653)) + # Synapse 1.96.0 (2023-11-16) Synapse will soon be getting forked by Element under an AGPLv3.0 licence (with diff --git a/changelog.d/16653.misc b/changelog.d/16653.misc deleted file mode 100644 index 9ee7b272261a..000000000000 --- a/changelog.d/16653.misc +++ /dev/null @@ -1 +0,0 @@ -Fix building of wheels in CI. diff --git a/debian/changelog b/debian/changelog index ab7faa056f32..25d9f15cdbb4 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +matrix-synapse-py3 (1.96.1) stable; urgency=medium + + * New synapse release 1.96.1. + + -- Synapse Packaging team Fri, 17 Nov 2023 12:48:45 +0000 + matrix-synapse-py3 (1.96.0) stable; urgency=medium * New synapse release 1.96.0. diff --git a/pyproject.toml b/pyproject.toml index daf5f5baa2db..7ff71787774f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -96,7 +96,7 @@ module-name = "synapse.synapse_rust" [tool.poetry] name = "matrix-synapse" -version = "1.96.0" +version = "1.96.1" description = "Homeserver for the Matrix decentralised comms protocol" authors = ["Matrix.org Team and Contributors "] license = "Apache-2.0" From 6a1352e56486022614a6765669bd6be66aba5ead Mon Sep 17 00:00:00 2001 From: Patrick Cloke Date: Fri, 17 Nov 2023 07:52:54 -0500 Subject: [PATCH 6/7] Move the forking note to 1.96.1. --- CHANGES.md | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index daa45016947b..9e4e0dac90b3 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,13 +1,5 @@ # Synapse 1.96.1 (2023-11-17) -This minor release was needed only because of CI-related trouble on [v1.96.0](https://github.com/matrix-org/synapse/releases/tag/v1.96.0), which was never released. - -### Internal Changes - -- Fix building of wheels in CI. ([\#16653](https://github.com/matrix-org/synapse/issues/16653)) - -# Synapse 1.96.0 (2023-11-16) - Synapse will soon be getting forked by Element under an AGPLv3.0 licence (with CLA, for proprietary dual licensing). You can read more about this here: @@ -17,6 +9,14 @@ CLA, for proprietary dual licensing). You can read more about this here: Any changes needed by server administrators will be communicated via our usual announcements channels, but we are striving to make this as seamless as possible. +This minor release was needed only because of CI-related trouble on [v1.96.0](https://github.com/matrix-org/synapse/releases/tag/v1.96.0), which was never released. + +### Internal Changes + +- Fix building of wheels in CI. ([\#16653](https://github.com/matrix-org/synapse/issues/16653)) + +# Synapse 1.96.0 (2023-11-16) + ### Bugfixes - Fix "'int' object is not iterable" error in `set_device_id_for_pushers` background update introduced in Synapse 1.95.0. ([\#16594](https://github.com/matrix-org/synapse/issues/16594)) From c4f5522189687c1e739d63246b5a6668d89b2d5f Mon Sep 17 00:00:00 2001 From: Patrick Cloke Date: Fri, 17 Nov 2023 08:01:13 -0500 Subject: [PATCH 7/7] Tweaks from review. --- CHANGES.md | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 9e4e0dac90b3..9358a22525b6 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,13 +1,15 @@ # Synapse 1.96.1 (2023-11-17) -Synapse will soon be getting forked by Element under an AGPLv3.0 licence (with -CLA, for proprietary dual licensing). You can read more about this here: +Synapse will soon be forked by Element under an AGPLv3.0 licence (with CLA, for +proprietary dual licensing). You can read more about this here: * https://matrix.org/blog/2023/11/06/future-of-synapse-dendrite/ * https://element.io/blog/element-to-adopt-agplv3/ -Any changes needed by server administrators will be communicated via our usual -announcements channels, but we are striving to make this as seamless as possible. +The Matrix.org Foundation copy of the project will be archived. Any changes needed +by server administrators will be communicated via our usual +[announcements channels](https://matrix.to/#/#homeowners:matrix.org), but we are +striving to make this as seamless as possible. This minor release was needed only because of CI-related trouble on [v1.96.0](https://github.com/matrix-org/synapse/releases/tag/v1.96.0), which was never released.