-
Notifications
You must be signed in to change notification settings - Fork 254
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
sdk: add support for listening to stream of live location updates #4025
base: main
Are you sure you want to change the base?
Conversation
Seems that the test aren't particularly happy with this PR. Can you please have a look? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR. I've left some feedback that can impact the global design of your patch.
3b574dd
to
7066fb3
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #4025 +/- ##
=======================================
Coverage 85.00% 85.01%
=======================================
Files 274 275 +1
Lines 29945 29951 +6
=======================================
+ Hits 25456 25463 +7
+ Misses 4489 4488 -1 ☔ View full report in Codecov by Sentry. |
29a2552
to
4cc5b45
Compare
Updated with more comprehensive tests and ready for a re-review thanks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we are almost done! Can you rebase your git
history please?
I've just merged #4253, and I believe it might interest you, or may your code a bit simpler. What do you think? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is still issues with the code (see comments). However, I suggest you to use #4253, where you can return your own subscriber, in which the produced stream can map the stream from EventHandlerSubscriber
to generate a LiveLocationShare
. See StreamExt::map
.
Would you be open to merging this as-is using the existing Recent commit makes use of the |
e21d9fb
to
05c1172
Compare
See torrybr#1, which does most of the job. |
488fb53
to
5bea9ef
Compare
Updated and rebased with the newest approach for using an observable stream. Appreciate the help and discussion around this PR, thanks! |
feea74e
to
7328083
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Almost there! The code is good, just a comment about documentation.
973e277
to
e10d8eb
Compare
Conversation related to this issue can be found here
This merge request adds
subscribe_to_live_location_shares
to thematrix_sdk::Room
that allows clients to listen for beacon updates using a background task. The method provides an easy way to subscribe to live location sharing events within a room, handling event processing internally.Follow-up tasks will include adding support for the event cache.