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

ffi: expose room membership through the RoomListItem and allow invited rooms to be build differently than "full" ones #3869

Merged
merged 2 commits into from
Aug 21, 2024

Conversation

stefanceriu
Copy link
Member

We're finding ourselves in the situation in which we can't interact with invites through normal Room APIs as full_rooms can't be build from the RoomListItem. Full rooms require the timeline to be configured before use and the timeline can't be configured because encryption cannot be fetched for invited rooms on homeservers that have previews disabled (see #3848 and #3850)

In response we now expose the room's membership directly from the RoomListItem so that the final client can chose which of the 2 rooms types (invited or full) to ask for before using aforementioned APIs.

Powers element-hq/element-x-ios#3189

…d rooms to be build differently than "full" ones

We're finding ourselves in the situation in which we can't interact with invites through normal Room APIs as `full_room`s can't be build from the RoomListItem.
Full rooms require the timeline to be configured before use and the timeline can't be configured because encryption cannot be fetched for invited rooms on homeservers that have previews disabled (see #3848 and #3850)

In response we now expose the room's membership directly from the `RoomListItem` so that the final client can chose which of the 2 rooms types (invited or full) to ask for before using aforementioned APIs.
Copy link

codecov bot commented Aug 21, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 84.09%. Comparing base (a27ebaa) to head (89c65fa).
Report is 10 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3869   +/-   ##
=======================================
  Coverage   84.08%   84.09%           
=======================================
  Files         261      261           
  Lines       27637    27637           
=======================================
+ Hits        23239    23240    +1     
+ Misses       4398     4397    -1     

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

Copy link
Member

@bnjbvr bnjbvr left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

bindings/matrix-sdk-ffi/src/room_list.rs Outdated Show resolved Hide resolved
bindings/matrix-sdk-ffi/src/room_list.rs Outdated Show resolved Hide resolved
…oomListError::IncorrectRoomMembership` error
@stefanceriu stefanceriu merged commit 4cc5790 into main Aug 21, 2024
40 checks passed
@stefanceriu stefanceriu deleted the stefan/ffiRoomTypes branch August 21, 2024 13:55
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.

2 participants