Skip to content

notifier.wait_for_events(user_id) should notify when device_one_time_keys_count changes #17474

Open
@MadLittleMods

Description

@MadLittleMods

Spawning from a discussion on a Sliding Sync PR,


notifier.wait_for_events(user_id) is used in Sync v2 and Sliding Sync to to wait for something to happen before assembling a sync response.

It currently handles things like new events, account data, to-device messages, typing activity, etc but doesn't pick up when your device one-time-key (OTK) counts change which affects the device_one_time_keys_count/device_unused_fallback_key_types in the sync response and should be considered new activity.

Currently, if other devices exhaust your OTKs without other activity to notify your sync loop, you would never be notified to upload more.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions