Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Posthog: stop double reporting UTD events when app is relaunched #3374

Open
richvdh opened this issue May 2, 2024 · 1 comment
Open

Posthog: stop double reporting UTD events when app is relaunched #3374

richvdh opened this issue May 2, 2024 · 1 comment
Assignees

Comments

@richvdh
Copy link
Member

richvdh commented May 2, 2024

Per element-hq/element-meta#2333

@richvdh richvdh changed the title Posthog: stop double reporting UTDs events when app is relaunched Posthog: stop double reporting UTD events when app is relaunched May 2, 2024
@richvdh richvdh self-assigned this May 20, 2024
@richvdh
Copy link
Member Author

richvdh commented May 20, 2024

This follows up on code added in #3206. I think we want to add logic to matrix-sdk-ui::unable_to_decrypt_hook::UtdHookManager to filter out UTD errors that have already been reported the "parent" UTD hook; and we need to persist that data. As with element-hq/element-web#27421, we probably want to use a Bloom filter to avoid the data getting too huge.

It's not quite the same as known_utds, because that is updated when we first see a UTD for a given event. At that point, the report has not yet been sent. If the application is restarted before the max_delay elapses, the task to actually send the report will be killed. In short, we shouldn't update the list of reported UTDs until the report is actually sent.

The main difficulty, I think, is going to be actually connecting UtdHookManager up to some persistent storage.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant