Open richvdh opened 6 months ago
Amazingly.. Firefox still doesn't support the durability
property. https://developer.mozilla.org/en-US/docs/Web/API/IDBTransaction/durability though pre-release versions do.
EDIT: Ah that's reading the durability from an existing transaction, the option to enable it has been supported much longer https://developer.mozilla.org/en-US/docs/Web/API/IDBDatabase/transaction#options
Filed https://github.com/rustwasm/wasm-bindgen/issues/3959 which needs to land first before we can specify the durability mode.
Ugh, I believe this just happened to me (Alice
is a bot running on my server, and Bob
is myself)...
Any idea on how to "reinitialise" the Olm session?
Do you happen to run the bot using the IndexedDB based store? Do you have logs for this? I suspect that the cause might be a different one.
The Olm session will attempt to reinitialize itself, though you might need to drop the currently active room key for the new session to be used: https://matrix-org.github.io/matrix-rust-sdk/matrix_sdk/room/struct.Room.html#method.discard_room_key. That's at least required if you don't use a SDK version which includes: https://github.com/matrix-org/matrix-rust-sdk/pull/3604.
@poljar Probably not indeed. I would have loved to try your fix by bumping the version of the SDK I use, but I can't because of #3689 .
Consider:
Currently, we use the "default" durability mode of IndexedDB, which can lead to data loss. We should instead use "strict", at least for transactions which update Olm sessions.