Commit Graph

94 Commits

Author SHA1 Message Date
Benjamin Bouvier
1ea2162012 chore(ci): add a search feature to try out the experimental-search branch in CI 2025-08-18 17:33:34 +02:00
Skye Elliot
ae7f0fe022 feat: Experimental encrypted state feature flag with CI support (#5537)
This PR makes some non-domain-specific changes across multiple crates
that are required for proper testing of features implemented for #5397.

* Adds a `experimental-encrypted-state-events` feature flag across the
SDK.
* Introduces a feature set into xtask to ensure feature-gated tests are
run during CI.
* Minor fix to a test that would otherwise fail with the newly
introduced CI.
2025-08-15 12:54:41 +00:00
Jonas Platte
995ec618df chore: Upgrade xtask and uniffi-bindgen to Rust edition 2024 2025-07-09 08:41:41 +02:00
Jonas Platte
3d642356c6 refactor: Clean up formatting in many places
Process:
- set style_edition to 2024 in .rustfmt.toml
- run `cargo fmt`
- undo .rustfmt.toml change
- run `cargo fmt` again
- manually rewrap some strings
2025-06-27 19:54:13 +02:00
Daniel Salinas
abcc05f889 Change matrix-sdk-ffi to rely on features over platform targets
The system of platform targets was already quite messy, and becoming
even worse as we start preparing for Wasm support. Switch to features
instead to make this easier to work with.
2025-06-19 16:16:59 +02:00
Damir Jelić
cc7f6243c6 ci: Make the text output for our coverage xtask the default 2025-06-19 13:57:58 +02:00
Damir Jelić
422fd19d10 ci: Add an xtask subcommand for coverage reports
This command uses llvm-cov which we are planning to switch to.
2025-06-19 09:50:16 +02:00
Kévin Commaille
f6c5addf55 refactor(sdk): Remove experimental-oidc feature
Now that is compiles under WASM and that the API was cleaned up, it
should be okay.

Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr>
2025-03-24 14:04:04 +02:00
Kévin Commaille
f02a7d15ab test(sdk): Run integration tests for experimental-oidc feature too
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr>
2025-02-26 16:08:00 +01:00
Benjamin Bouvier
2291a61379 ci: add a new feature set to test experimental-oidc too
This would help find test failures specific to experimental-oidc, as
well as doctests failing (which would have prevented the failures fixed
in https://github.com/matrix-org/matrix-rust-sdk/pull/4614 to happen in
the first place).
2025-02-06 11:21:31 +01:00
Jonas Platte
993c103270 ci: Add wasm job for matrix-sdk-ui 2025-01-17 15:35:28 +01:00
Ivan Enderlin
61dd560499 feat: Remove the experimental-sliding-sync feature flag.
Sliding sync is no longer experimental. It has a solid MSC4186, along
with a solid implementation inside Synapse. It's time to consider it
mature.

The SDK continues to support the old MSC3575 in addition to MSC4186.
This patch only removes the `experimental-sliding-sync` feature flag.
2025-01-08 21:30:41 +01:00
Kévin Commaille
f94b202341 chore(xtask): Upgrade xshell
Gets rid of an unexpected_cfgs warning.

Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr>
2024-11-30 18:03:54 +01:00
Kévin Commaille
9999d3ba96 chore(sdk)!: Remove image-proc feature and functions to generate a thumbnail
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr>
2024-10-16 10:55:11 +02:00
Jonas Platte
a4bda1ac66 chore: Move lint configuration out of .cargo/config.toml
This allows removing a lot of hacks to avoid spurious rebuilds.
2024-10-11 12:40:18 +02:00
Benjamin Bouvier
47444cc671 sdk-base: hack to avoid over-recursion when evaluating Send/Sync bounds in rustc
See
https://github.com/matrix-org/matrix-rust-sdk/pull/3749#issuecomment-2312939823
for the gory details.
2024-08-28 16:49:46 +02:00
Benjamin Bouvier
13f2c89e06 xtask: force --target-applies-to-host when running Clippy check
Without this, the configs from `.cargo/config.toml` were not read in CI
tasks, causing false positives when running Clippy on CI (i.e. there
were issues observed when compiling locally that were not found when
compiling remotely).

Not entirely sure why it's needed, because I'm seeing the issues when
I'm using `cargo xtask ci clippy` locally, with nothing changed.
2024-06-05 09:34:31 +02:00
Kévin Commaille
6c18bcf748 sdk: Improvements around generate_image_thumbnail (#3415)
* sdk: Return a Thumbnail from generate_image_thumbnail

We have already all the data for it.
Also fixes an error where the thumbnail format was assumed to always be
JPEG.

* sdk: Allow to select the format of the generated thumbnail

Sending an attachment could often fail if the image crate
cannot encode the thumbnail to the same format as the original.
This allows to select a known supported format to always
be able to generate a thumbnail.

* sdk: Do not return error of thumbnail generation for SendAttachment

Since the thumbnail is optional, failing to generate it should not
stop us from sending the attachment.

* Apply code review fixes
* sdk: Split attachment tests in separate file
* sdk: Add integration tests for generating thumbnails
* Revert wiremock debug log level

---------

Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr>
2024-05-17 16:48:59 +02:00
Ivan Enderlin
62641adfeb Revert "Revert "matrix-sdk-indexeddb: make matrix-sdk-base an optional dependency"" 2024-01-11 15:20:38 +01:00
Ivan Enderlin
1521ec6cb2 Revert "matrix-sdk-indexeddb: make matrix-sdk-base an optional dependency" 2024-01-11 15:05:00 +01:00
Richard van der Hoff
0d938d94aa matrix-sdk-indexeddb: make matrix-sdk-base an optional dependency
If we're not using the StateStore, then we don't need a dependency on
`matrix-sdk-base`. Let's make it turn-off-able.
2024-01-05 17:29:07 +00:00
Jonas Platte
3b7f9f7361 Reapply "bindings: Use new uniffi-bindgen build mode"
This reverts commit 0d24bcf6e5.
2023-12-12 16:51:49 +01:00
Jonas Platte
c5c3850edf Use the same nightly toolchain for all xtask commands 2023-11-23 14:15:21 +01:00
Damir Jelić
e5b06bd6d8 Enable backups in the crypto crate by default 2023-11-03 19:17:10 +01:00
Richard van der Hoff
fcd593b0bf Improve documentation on xtask ci {wasm,wasm-pack} 2023-09-26 21:30:40 +02:00
Jonas Platte
7d674b39aa Remove matrix-sdk-appservice
There is unfortunately no capacity for maintaining it as a first-party
component of the Rust SDK.
2023-09-05 15:40:38 +02:00
Jonas Platte
0d24bcf6e5 Revert "bindings: Use new uniffi-bindgen build mode"
This reverts commit 329b6c4eb1.
2023-08-22 18:40:20 +02:00
Jonas Platte
329b6c4eb1 bindings: Use new uniffi-bindgen build mode 2023-08-22 11:12:55 +02:00
Damir Jelić
c22f6da909 Add a js feature to the qrcode crate 2023-07-31 10:08:53 +02:00
Benjamin Bouvier
020d5aa292 fix: use a little state machine to handle the response
and that allows to make sure that all event handlers are correctly called for all
events contained in the response.
2023-07-25 17:36:43 +02:00
Jonas Platte
bfed0907ed Remove wasm_command_bot 2023-07-14 11:07:47 +02:00
Jonas Platte
5abc781e1f Remove matrix-sdk-crypto-js
It now lives in its own repository at
https://github.com/matrix-org/matrix-rust-sdk-crypto-web
2023-07-13 13:11:02 +02:00
Jonas Platte
cd4288391e Bump nightly toolchain version 2023-07-03 18:57:05 +02:00
Benjamin Bouvier
4fbb3d2b63 xtask: add --features testing to most testing tasks 2023-06-30 12:41:04 +02:00
Ivan Enderlin
e6fdcfdf52 chore: Make Clippy happy. 2023-06-05 20:05:46 +02:00
Ivan Enderlin
d86647db77 chore(ci): Give pushd's result a name so that it's not dropped. 2023-05-17 20:00:33 +02:00
Ivan Enderlin
fc37f337fb fix(ci): Fix path to matrix-sdk-crypto-js and allow pushd to return an error.
First off, this patch changes `pushd(…)` to `pushd(…)?` so that errors
are propagated.

Second, instead of assuming that all crates live in `crates/`, let's
allow to precise a prefix, like `crates/` or `bindings/` directly in the
“folder” path of `args`.
2023-05-17 17:12:52 +02:00
Jonas Platte
cfc8effa66 Move timeline API into a new crate
… aimed at interactive user interfaces.
2023-05-17 09:58:31 +02:00
Kévin Commaille
ea826a257d sdk: Replace Sled with SQLite as defaut store
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr>
2023-05-08 12:11:10 +02:00
Jonas Platte
32fafe7be3 Pin rust nightly version
Works around https://github.com/rust-lang/rust/issues/111320.
2023-05-08 10:44:14 +02:00
Damir Jelić
516d849ef2 Allow room key forwarding to be enabled and disabled (#1365)
Co-authored-by: Ivan Enderlin <ivan@mnt.io>
2023-03-14 18:23:39 +01:00
Jonas Platte
932cf2ad99 Fix experimental features not compiling without encryption 2023-03-08 15:03:20 +01:00
Jonas Platte
32e8cb76b0 ci: Remove unused FeatureSet variant 2023-02-24 12:39:55 +01:00
Jonas Platte
ce973b35e9 chore: Upgrade uniffi to 0.23.0 2023-02-02 10:15:05 +01:00
Anderas
e9cef35f99 Add matrix-sdk-sqlite with a CryptoStore implementation
Note about "Write-Ahead Log" (WAL) mode: The SQLite WAL mode has a
bunch of advantages that are quite nice to have:

1. WAL is significantly faster in most scenarios.
2. WAL provides more concurrency as readers do not block writers and a
   writer does not block readers. Reading and writing can proceed
   concurrently.
3. Disk I/O operations tends to be more sequential using WAL.
4. WAL uses many fewer fsync() operations and is thus less vulnerable
   to problems on systems where the fsync() system call is broken.

The downsides of WAL mode don't really affect us. So let's turn it on.

More info: https://www.sqlite.org/wal.html

Co-authored-by: Jonas Platte <jplatte@matrix.org>
Co-authored-by: Damir Jelić <poljar@termina.org.uk>
2023-02-01 15:06:59 +01:00
Damir Jelić
cdfb51a606 refactor!(sdk): Add the experimental prefix to the sliding-sync feature 2023-01-11 11:54:32 +01:00
Jonas Platte
fa71122e7d ci: Add sliding-sync and experimental-timeline to clippy check 2022-11-18 15:05:48 +01:00
Jonas Platte
5b919fc9df refactor: Fix clippy lints 2022-11-04 15:17:01 +01:00
Jonas Platte
426f60a6a2 ci: Add bindings check to xtask 2022-10-27 11:58:42 +02:00
Doug
7125730917 ci(xtask): Switch to xtask for swift; run swift tasks on macOS
Merge pull request #1023 from matrix-org/doug/swift-linux: Run Swift tests on macOS
2022-10-17 14:12:43 +02:00