Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update MSC3912 implementation to use with_rel_type instead of with_relations #3420

Merged
merged 7 commits into from
Jun 7, 2023

Conversation

weeman1337
Copy link
Contributor

@weeman1337 weeman1337 commented May 30, 2023

Adapts the implementation to the latest version of MSC3912

  • with_relationswith_rel_types
  • with_rel_types is now always a list of strings incl. *
  • I decided to keep with_relations and mark it as deprecated. It should be removed once the MSC becomes stable.

Part of element-hq/element-web#25471

Checklist

  • Tests written for new code (and old code if feasible)
  • Linter and other CI checks pass
  • Sign-off given on the changes (see CONTRIBUTING.md)

Here's what your changelog entry will look like:

✨ Features

  • Update MSC3912 implementation to use with_rel_type instead of with_relations (#3420).

@weeman1337 weeman1337 added the T-Task Tasks for the team like planning label May 30, 2023
@weeman1337 weeman1337 marked this pull request as ready for review May 30, 2023 14:06
@weeman1337 weeman1337 requested a review from a team as a code owner May 30, 2023 14:06
@richvdh richvdh changed the title Migrate MSC3912 Update MSC3912 implementation to use new property names May 31, 2023
@richvdh richvdh added T-Enhancement and removed T-Task Tasks for the team like planning labels May 31, 2023
@richvdh
Copy link
Member

richvdh commented May 31, 2023

@weeman1337 a gentle request to try to make your PR subjects meaningful, and not to mark them as T-Task where there are functional changes :)

src/@types/requests.ts Outdated Show resolved Hide resolved
src/client.ts Outdated Show resolved Hide resolved
src/client.ts Outdated Show resolved Hide resolved
src/@types/event.ts Show resolved Hide resolved
spec/unit/matrix-client.spec.ts Outdated Show resolved Hide resolved
spec/unit/matrix-client.spec.ts Outdated Show resolved Hide resolved
src/client.ts Outdated Show resolved Hide resolved
src/client.ts Outdated Show resolved Hide resolved
Copy link
Member

@richvdh richvdh left a comment

Choose a reason for hiding this comment

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

some nit-picking but generally lgtm

src/client.ts Outdated Show resolved Hide resolved
src/client.ts Outdated Show resolved Hide resolved
Comment on lines +343 to +345
unstableFeatures = {
"org.matrix.msc3440.stable": true,
};
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
unstableFeatures = {
"org.matrix.msc3440.stable": true,
};
unstableFeatures["org.matrix.msc3440.stable"] = true;

(though I'm not sure why it is being moved at all)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This sets unstableFeatures to a defined state before each test. Another test sets an additional property on it:

unstableFeatures["org.matrix.msc3912"] = true;

Copy link
Contributor Author

Choose a reason for hiding this comment

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

→ will add a comment

Copy link
Member

Choose a reason for hiding this comment

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

oh, I see.

Copy link
Member

Choose a reason for hiding this comment

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

oh, I see.

@weeman1337 weeman1337 changed the title Update MSC3912 implementation to use new property names Update MSC3912 implementation to use with_rel_type instead of with_relations Jun 1, 2023
@weeman1337 weeman1337 added this pull request to the merge queue Jun 7, 2023
Merged via the queue into develop with commit 2d7fdde Jun 7, 2023
23 checks passed
@weeman1337 weeman1337 deleted the weeman1337/migrate-msc3912 branch June 7, 2023 12:16
su-ex added a commit to SchildiChat/matrix-js-sdk that referenced this pull request Feb 22, 2024
* Introduce a new `Crypto.Verifier` interface, and deprecate direct access to `VerificationBase`, `SAS` and `ReciprocateQRCode` ([\matrix-org#3414](matrix-org#3414)).
* Add `rust-crypto#isCrossSigningReady` implementation ([\matrix-org#3462](matrix-org#3462)). Contributed by @florianduros.
* OIDC: Validate `m.authentication` configuration ([\matrix-org#3419](matrix-org#3419)). Contributed by @kerryarchibald.
* ElementR: Add `CryptoApi.getCrossSigningStatus` ([\matrix-org#3452](matrix-org#3452)). Contributed by @florianduros.
* Extend stats summary with call device and user count based on room state ([\matrix-org#3424](matrix-org#3424)). Contributed by @toger5.
* Update MSC3912 implementation to use `with_rel_type` instead of `with_relations` ([\matrix-org#3420](matrix-org#3420)).
* Export thread-related types from SDK ([\matrix-org#3447](matrix-org#3447)). Contributed by @stas-demydiuk.
* Use correct /v3 prefix for /refresh ([\matrix-org#3016](matrix-org#3016)). Contributed by @davidisaaclee.
* Fix thread list being ordered based on all updates ([\matrix-org#3458](matrix-org#3458)). Fixes element-hq/element-web#25522.
* Fix: handle `baseUrl` with trailing slash in `fetch.getUrl` ([\matrix-org#3455](matrix-org#3455)). Fixes element-hq/element-web#25526. Contributed by @kerryarchibald.
* use cli.canSupport to determine intentional mentions support ([\matrix-org#3445](matrix-org#3445)). Fixes element-hq/element-web#25497. Contributed by @kerryarchibald.
* Make sliding sync linearize processing of sync requests ([\matrix-org#3442](matrix-org#3442)).
* Fix edge cases around 2nd order relations and threads ([\matrix-org#3437](matrix-org#3437)).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants