Introduce support for MSC4429: Profile Updates for Legacy Sync (#19556)

Implements support for [MSC4429: Profile Updates for Legacy
Sync](https://github.com/matrix-org/matrix-spec-proposals/pull/4429).

Paired with https://github.com/matrix-org/complement/pull/849 and
https://github.com/matrix-org/sytest/tree/anoa/msc4429

Tracking issue for removing unstable identifiers in Synapse:
https://github.com/element-hq/synapse/issues/19891
Further improvements tracked in:
https://github.com/element-hq/synapse/issues/19981

---------

Co-authored-by: Half-Shot <will@half-shot.uk>
Co-authored-by: Jason Robinson <jasonr@element.io>
Co-authored-by: Olivier 'reivilibre' <oliverw@element.io>
This commit is contained in:
Andrew Morgan
2026-08-06 15:35:07 +01:00
committed by GitHub
co-authored by Half-Shot Jason Robinson Olivier 'reivilibre'
parent 556154848c
commit c5f02a9313
51 changed files with 4380 additions and 359 deletions
+5
View File
@@ -45,6 +45,7 @@ from mypy.types import (
AnyType,
CallableType,
Instance,
LiteralType,
NoneType,
Options,
TupleType,
@@ -813,6 +814,10 @@ def is_cacheable(
if isinstance(rt, AnyType):
return True, ("may be mutable" if verbose else None)
elif isinstance(rt, LiteralType):
# Literal[True] etc
return True, None
elif isinstance(rt, Instance):
if (
rt.type.fullname in IMMUTABLE_VALUE_TYPES