Skip to content

Conversation

@nvrWhere
Copy link
Collaborator

@nvrWhere nvrWhere commented Sep 15, 2024

So after failing the enableEncryption test in #800 I had a deeper look at the test. What was happening was that we were creating a room but were not waiting for the room state to be synced down. This meant that when we tried to check user power levels there were no state events available to get the user's power level and also no creation event so it defaulted to 0.

In fact with the way the test was laid out it was pretty timing dependent. I.e. the manual syncs managed to happen after the encryption was activated.

This reworks a little so that the connection sync loop is activated then we just wait on first the room base state loading, then the encryption signal coming through.

Copy link
Member

@KitsuneRal KitsuneRal left a comment

Choose a reason for hiding this comment

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

Thanks - just one more thing to delete :)

@nvrWhere nvrWhere changed the title Rework enableEncryption tet to be less timing dependent Rework enableEncryption test to be less timing dependent Sep 15, 2024
@KitsuneRal KitsuneRal merged commit dd8d3ea into quotient-im:dev Sep 16, 2024
@KitsuneRal KitsuneRal added the bug/fix The library doesn't work as expected label Sep 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug/fix The library doesn't work as expected

Projects

Status: 0.9 - Done

Development

Successfully merging this pull request may close these issues.

2 participants