Commit Graph

13906 Commits

Author SHA1 Message Date
Kévin Commaille
32b72580da Commit changed Cargo.lock
This seems to come from a previous commit?

Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr>
2025-12-01 15:22:48 +00:00
Ivan Enderlin
73449f4f57 doc(sdk): Add #5908 in the CHANGELOG.md. 2025-11-27 17:23:47 +01:00
Ivan Enderlin
bbe35e8190 fix(sdk): A new local LatestEventValue can be “cannot be sent”.
This patch fixes a bug where a new local `LatestEventValue`
was always created as `LocalIsSending`. It must be created as
`LocalCannotBeSent` if a previous local `LatestEventValue` exists and is
`LocalCannotBeSent`.

This patch adds the companion test too.
2025-11-27 17:23:47 +01:00
Marcel-Nordeck
107fc07d08 Wasm improvements for the bindings
This patch improves the Wasm support of the matrix-sdk-ffi crate.

First a uniffi feature needed to be enabled.
Secondly a bunch of methods which don't work under Wasm have been stubbed out.

Signed-off-by: MTRNord <MTRNord@users.noreply.github.com>
Co-authored-by: MTRNord <MTRNord@users.noreply.github.com>
2025-11-27 15:46:33 +01:00
Damir Jelić
4585d5f4d8 docs(search): Remove the example depending on the matrix-sdk crate
Examples are great, but the circular dependency this introduces is not
worth the trouble.
2025-11-27 14:34:35 +01:00
Damir Jelić
239203a813 fix: The search crate doesn't actually depend on the main crate
This removes a circular dependency we had resulting in a semi-broken
release process.
2025-11-27 14:34:35 +01:00
Damir Jelić
24d7518a01 chore: Allow release branches for cargo release as well 2025-11-27 11:10:32 +01:00
Damir Jelić
e6059251d0 Merge pull request #5901 from matrix-org/poljar/release-0.15.0 2025-11-27 10:39:45 +01:00
Damir Jelić
f4fef6e995 chore: Fix the dates of the 0.15.0 release 2025-11-27 10:07:41 +01:00
Damir Jelić
850b7dde6d chore: Release matrix-sdk version 0.15.0 2025-11-26 15:44:26 +01:00
Damir Jelić
700c17f383 release: Allow release preparation to work on the HEAD
This is to allow Jujutsu users to use the cargo-release tooling.
2025-11-26 15:38:29 +01:00
Doug
9e842a5d07 spaces: Add support for getting a flattened list of editable spaces. 2025-11-26 13:06:49 +01:00
Doug
18175c1cd0 chore: Use a common add_space_rooms function for tests. 2025-11-26 13:06:49 +01:00
dependabot[bot]
100a04ae2c chore(deps): bump CodSpeedHQ/action from 4.3.3 to 4.4.1
Bumps [CodSpeedHQ/action](https://github.com/codspeedhq/action) from 4.3.3 to 4.4.1.
- [Release notes](https://github.com/codspeedhq/action/releases)
- [Changelog](https://github.com/CodSpeedHQ/action/blob/main/CHANGELOG.md)
- [Commits](bb005fe1c1...346a2d8a8d)

---
updated-dependencies:
- dependency-name: CodSpeedHQ/action
  dependency-version: 4.4.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-26 10:30:10 +01:00
dependabot[bot]
3a655083d6 chore(deps): bump bnjbvr/cargo-machete
Bumps [bnjbvr/cargo-machete](https://github.com/bnjbvr/cargo-machete) from 04b9adbd8c1c00963289b5628510dd907b27dc60 to 10aef304cba9ef99dacee57a756c14892391cdca.
- [Release notes](https://github.com/bnjbvr/cargo-machete/releases)
- [Changelog](https://github.com/bnjbvr/cargo-machete/blob/main/CHANGELOG.md)
- [Commits](04b9adbd8c...10aef304cb)

---
updated-dependencies:
- dependency-name: bnjbvr/cargo-machete
  dependency-version: 10aef304cba9ef99dacee57a756c14892391cdca
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-26 09:51:58 +01:00
dependabot[bot]
46947be662 chore(deps): bump crate-ci/typos from 1.39.0 to 1.39.2
Bumps [crate-ci/typos](https://github.com/crate-ci/typos) from 1.39.0 to 1.39.2.
- [Release notes](https://github.com/crate-ci/typos/releases)
- [Changelog](https://github.com/crate-ci/typos/blob/master/CHANGELOG.md)
- [Commits](https://github.com/crate-ci/typos/compare/v1.39.0...v1.39.2)

---
updated-dependencies:
- dependency-name: crate-ci/typos
  dependency-version: 1.39.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-26 09:51:05 +01:00
Johannes Marbach
fccafd8c80 feat(oauth): expose session expiration errors when requesting login with a QR code
Signed-off-by: Johannes Marbach <n0-0ne+github@mailbox.org>
2025-11-26 09:50:11 +01:00
Johannes Marbach
1e30d5f0b0 feat(oauth): expose session expiration errors when granting login with a QR code
Signed-off-by: Johannes Marbach <n0-0ne+github@mailbox.org>
2025-11-26 09:50:11 +01:00
Johannes Marbach
4ab12543ce feat(testing): allow specifying expiration duration in MockedRendezvousServer
Signed-off-by: Johannes Marbach <n0-0ne+github@mailbox.org>
2025-11-26 09:50:11 +01:00
Johannes Marbach
a82ccf1069 fix(oauth): expose client API errors when receiving messages on rendezvous channel
Signed-off-by: Johannes Marbach <n0-0ne+github@mailbox.org>
2025-11-26 09:50:11 +01:00
Ivan Enderlin
45a9d96573 chore(sdk): Remove an unwrap in debug_string. 2025-11-25 15:41:27 +01:00
Ivan Enderlin
c9324b2f30 refactor(sdk): Change a Semaphore(permit=1) for a Mutex.
This patch changes the `Semaphore(permit=1)` for a `Mutex`: the
semantics is strictly equivalent, but it removes the need to guarantee
there is a single permit.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
8e93bb5373 chore: Replace unwrap by expect. 2025-11-25 15:41:27 +01:00
Ivan Enderlin
8df55fa3e7 test(sdk): Add a test for dirtiness handling in RoomEventCacheStateLock::new. 2025-11-25 15:41:27 +01:00
Ivan Enderlin
478df4af33 test(sdk): Ensure EventCacheStoreLockGuard::clear_dirty is called!
This patch ensures that the `EventCacheStoreLockGuard::clear_dirty`
method is correctly called.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
04fdf7f2f6 feat(sdk): Send updates when RoomEventCacheStateLock is reloaded.
This patch updates the reloading of `RoomEventCacheStateLock`
when the cross-process lock over the store is dirty to broadcast
`RoomEventCacheUpdate` and `RoomEventCacheGenericUpdate`. That way the
`Timeline` and other components can react to this reload.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
179136a9a4 refactor(sdk): Rename RoomEventCacheInner::sender to update_sender.
This patch renames the `sender` field of `RoomEventCacheInner` to
`update_sender` to clarify what the sender is about.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
e51996a47c test(sdk): Add the test_reset_when_dirty test.
This patch adds the new `test_reset_when_dirty` test, which ensures
the state is correctly reset when the cross-process lock over the store
becomes dirty.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
12e5614fc8 feat(sdk): Allow shared access on RoomEventCacheStateLock::read.
This patch fixes a problem found in a test (not commited yet) where it
was impossible to do multiple calls to `read` if the first guard was
still alive. See the comments to learn more.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
14d550739a feat(sdk): Implement RoomEventCacheStateLockWriteGuard::downgrade.
This patch implements `RoomEventCacheStateLockWriteGuard::downgrade` to
simplify the code a little bit.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
fbcd8ef546 test(common): Make tests run faster.
This patch replaces `sleep` by `yield_now`, which has the same effect in
this case, and makes the tests run faster.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
e5f6153f54 test(common): Test dirtiness of the cross-process lock. 2025-11-25 15:41:27 +01:00
Ivan Enderlin
badba6eebc fix(sdk): Remove a warning for wasm32. 2025-11-25 15:41:27 +01:00
Ivan Enderlin
72f2296809 doc(sdk): Add missing or fix documentation. 2025-11-25 15:41:27 +01:00
Ivan Enderlin
b1af16ef09 feat(sdk): Reset RoomEventCacheState when the cross-process lock is dirty.
This patch updates the `RoomEventCacheStateLock::read` and `write`
methods to reset the state when the cross-process lock is dirty.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
1cf0601ba3 refactor(sdk) Introduce RoomEventCacheStateLock and read/write guards.
This patch extracts fields from `RoomEventCacheState` and move them
into `RoomEventCacheStateLock`. This lock provides 2 methods: `read`
and `write`, respectively to acquire a read-only lock, and a write-only
lock, represented by the `RoomEventCacheStateLockReadGuard` and the
`RoomEventCacheStateLockWriteGuard` types.

All “public” methods on `RoomEventCacheState` now are facade to the read
and write guards.

This refactoring makes the code to compile with the last change in
`EventCacheStore::lock`, which now returns a `EventCacheStoreLockState`.
The next step is to re-load `RoomEventCacheStateLock` when the lock is
dirty! But before doing that, we need this new mechanism to centralise
the management of the store lock.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
e034a51b7b test(sdk): Update to use EventCacheStoreLockState. 2025-11-25 15:41:27 +01:00
Ivan Enderlin
9e6a6c0e71 fix(base): Use the EventCacheStoreLockState. 2025-11-25 15:41:27 +01:00
Ivan Enderlin
d1633f2a78 feat(base): EventCacheStoreLockGuard can be cloned.
This patch implements `Clone` for `EventCacheStoreLockGuard`.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
4dbee471ac feat(common): CrossProcessLockGuard can be cloned.
This patch implements `Clone` for `CrossProcessLockGuard`.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
997f992d15 refactor(base): EventCacheStoreLockState owns a clone of the inner store.
This patch changes `EventCacheStoreLockState` to own a clone of
the inner store. It helps to remove the `'a` lifetime, and so it
“disconnects” from the lifetime of the store.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
3d5b32494e feat(base): Add EventCacheStoreLockGuard::clear_dirty. 2025-11-25 15:41:27 +01:00
Ivan Enderlin
c5893f882c feat(common): Add CrossProcessLockGuard::is_dirty and ::clear_dirty.
This patch replicates the `is_dirty` and `clear_dirty` methods from
`CrossProcessLock` to `CrossProcessLockGuard`. It allows to get an
access to this API from a guard when one doesn't have the cross-process
lock at hand.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
68e8866bcf chore(sdk): Clean up imports. 2025-11-25 15:41:27 +01:00
Ivan Enderlin
c98d9db185 feat(base) Create the EventCacheStoreLockState type.
This patch updates `EventCacheStoreLock::lock()` to return an
`EventCacheStoreLockState` instead of an `EventCacheStoreLockGuard`, so
that the caller has to handle dirty locks.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
cee2b1bebf feat(common): Add CrossProcessLockState::map.
This patch adds the `CrossProcessLockState::map` method along with its
companion `MappedCrossProcessLockState` type. The idea is to facilitate
the creation of custom `CrossProcessLockState`-like type in various
usage of the cross-process lock.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
19a96b41df feat(common) Add #[must_use] on CrossProcessLockGuard and *State.
This patch adds a `#[must_use]` attribute on `CrossProcessLockGuard` and
`CrossProcessLockState` to avoid a misuse.
2025-11-25 15:41:27 +01:00
Ivan Enderlin
80decaebf4 chore(common) Rename CrossProcessLockKind to CrossProcessLockState.
This patch renames the `CrossProcessLockKind` type to
`CrossProcessLockState`.
2025-11-25 15:41:27 +01:00
Jorge Martín
20ee85bd0f fix: Remove unnecessary options from sentry::ClientOptions 2025-11-25 14:19:49 +01:00
Jorge Martín
813c5fc9f9 misc: Bump Sentry SDK to v0.46.0 2025-11-25 14:19:49 +01:00