Skip to content

Reinstate removed EventBase methods#19712

Merged
erikjohnston merged 4 commits into
developfrom
erikj/support_event_deprecated
Apr 22, 2026
Merged

Reinstate removed EventBase methods#19712
erikjohnston merged 4 commits into
developfrom
erikj/support_event_deprecated

Conversation

@erikjohnston
Copy link
Copy Markdown
Member

Both __getitem__ and .user_id were removed in #19680 to simplify the event class. However, EventBase is exposed to modules who might also make use of those methods, so let's reinstate them (but otherwise not reinstate the usage of them in the code).

Both `__getitem__` and `.user_id` were removed in #19680 to simplify the
event class. However, `EventBase` is exposed to modules who might also
make use of those methods, so let's reinstate them (but otherwise not
reinstate the usage of them in the code).
@erikjohnston erikjohnston marked this pull request as ready for review April 21, 2026 09:32
@erikjohnston erikjohnston requested a review from a team as a code owner April 21, 2026 09:32
Copy link
Copy Markdown
Contributor

@reivilibre reivilibre left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SGTM but we could annotate the deprecation better for external users to be more aware of it

Comment thread synapse/events/__init__.py
Comment thread tests/module_api/test_api.py Outdated
Comment thread tests/module_api/test_api.py Outdated
Co-authored-by: Eric Eastwood <madlittlemods@gmail.com>
@erikjohnston erikjohnston merged commit c8ce96f into develop Apr 22, 2026
46 checks passed
@erikjohnston erikjohnston deleted the erikj/support_event_deprecated branch April 22, 2026 10:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants