Skip to content

Conversation

uhoreg
Copy link
Member

@uhoreg uhoreg commented Sep 9, 2025

Depends on matrix-org/matrix-rust-sdk#5647

Content

Currently, if you verify using a recovery key, but the backup key is corrupt, it will fail, saying that you entered the incorrect recovery key, even if you entered the correct recovery key. This PR ignores errors coming from importing secrets from secret storage, allowing those errors to be handle by the "key storage out of sync" detection.

Motivation and context

Fixes #5099

Tests

Tested devices

  • Physical
  • Emulator
  • OS version(s): Android 16 (emulated Pixel 9)

Checklist

  • Changes have been tested on an Android device or Android emulator with API 24
  • UI change has been tested on both light and dark themes
  • Accessibility has been taken into account. See https://github.com/element-hq/element-x-android/blob/develop/CONTRIBUTING.md#accessibility
  • Pull request is based on the develop branch
  • Pull request title will be used in the release note, it clearly define what will change for the user
  • Pull request includes screenshots or videos if containing UI changes
  • You've made a self review of your PR

Copy link
Contributor

github-actions bot commented Sep 9, 2025

Thank you for your contribution! Here are a few things to check in the PR to ensure it's reviewed as quickly as possible:

  • Your branch should be based on origin/develop, at least when it was created.
  • The title of the PR will be used for release notes, so it needs to describe the change visible to the user.
  • The test pass locally running ./gradlew test.
  • The code quality check suite pass locally running ./gradlew runQualityChecks.
  • If you modified anything related to the UI, including previews, you'll have to run the Record screenshots GH action in your forked repo: that will generate compatible new screenshots. However, given Github Actions limitations, it will prevent the CI from running temporarily, until you upload a new commit after that one. To do so, just pull the latest changes and push an empty commit.

@uhoreg
Copy link
Member Author

uhoreg commented Oct 2, 2025

I'm guessing that the CI failure is because it needs to be updated to the latest Rust SDK. This PR needs at least matrix-org/matrix-rust-sdk@57d21cc But when I update to the latest main branch of the Rust SDK, I get a bunch of other unrelated compile errors. :-/

Anyways, I think this PR is ready to be reviewed now.

@uhoreg uhoreg marked this pull request as ready for review October 2, 2025 22:10
@uhoreg uhoreg requested a review from a team as a code owner October 2, 2025 22:10
@uhoreg uhoreg requested review from bmarty and removed request for a team October 2, 2025 22:10
Copy link
Member

@bmarty bmarty left a comment

Choose a reason for hiding this comment

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

Thanks!
I have removed your code that was already present on develop and was added to fix compilation issue.

Copy link

codecov bot commented Oct 7, 2025

Codecov Report

❌ Patch coverage is 0% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 81.93%. Comparing base (59ef782) to head (1cd8a2a).
⚠️ Report is 46 commits behind head on develop.

Files with missing lines Patch % Lines
...es/matrix/impl/encryption/RustEncryptionService.kt 0.00% 3 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #5314      +/-   ##
===========================================
- Coverage    81.94%   81.93%   -0.02%     
===========================================
  Files         2371     2371              
  Lines        67233    67235       +2     
  Branches      8119     8121       +2     
===========================================
- Hits         55095    55089       -6     
- Misses        9163     9171       +8     
  Partials      2975     2975              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@bmarty
Copy link
Member

bmarty commented Oct 9, 2025

I'll fix the error reported by Detekt on develop 🙈

EDIT: c08590a

@bmarty bmarty merged commit 4308f55 into element-hq:develop Oct 9, 2025
22 of 26 checks passed
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

Successfully merging this pull request may close these issues.

Attempting to verify with recovery key reports "incorrect recovery key" if 4S lacks backup key

2 participants