Skip to content

Start, send and stop live location#5333

Closed
Velin92 wants to merge 5 commits intodevelopfrom
mauroromito/start_live_location
Closed

Start, send and stop live location#5333
Velin92 wants to merge 5 commits intodevelopfrom
mauroromito/start_live_location

Conversation

@Velin92
Copy link
Copy Markdown
Member

@Velin92 Velin92 commented Mar 31, 2026

This PR implements inside the LiveLocationManager the following functions

  • Start live location sharing
  • Send LLS updates (all done in background the user doesn't need to worry about anything)
  • Stop LLS

It also implements a store that keeps track of what are the rooms this device is sending LLS to, in this way in case of a crash, kill or reopen we can restore the LLS updates.

We also try to stop events once they have expired in conformance with the MSC.
It's important to note that this is a best effort thing, if it's not possible we don't try again (usually clients implement an internal check to consider an LLS expired, so that's generally fine).

To review commit by commit.

Also the send functions will not work properly on the current SDK release, since we need a fix for the sync over the beaconInfo event, which is being worked on here: matrix-org/matrix-rust-sdk#6385

@Velin92 Velin92 force-pushed the mauroromito/start_live_location branch 2 times, most recently from 6de8dff to 59cc473 Compare April 2, 2026 15:15
@Velin92 Velin92 force-pushed the mauroromito/start_live_location branch from 59cc473 to e39303c Compare April 2, 2026 15:29
@Velin92 Velin92 changed the title Start Live Location Start, send and stop live location Apr 2, 2026
@Velin92 Velin92 added the pr-wip for anything that isn't ready to ship and will be enabled at a later date label Apr 2, 2026
@Velin92 Velin92 marked this pull request as ready for review April 2, 2026 16:50
@Velin92 Velin92 requested a review from a team as a code owner April 2, 2026 16:50
@Velin92 Velin92 requested review from stefanceriu and removed request for a team April 2, 2026 16:50
@Velin92 Velin92 force-pushed the mauroromito/start_live_location branch from a8a0ec7 to 858c1e6 Compare April 2, 2026 16:52
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 2, 2026

Codecov Report

❌ Patch coverage is 41.17647% with 90 lines in your changes missing coverage. Please review.
✅ Project coverage is 74.49%. Comparing base (e66bbab) to head (858c1e6).
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
...ources/Services/Location/LiveLocationManager.swift 0.00% 87 Missing ⚠️
...cationSharing/LocationSharingScreenViewModel.swift 97.67% 1 Missing ⚠️
...X/Sources/Screens/Timeline/TimelineViewModel.swift 50.00% 1 Missing ⚠️
...melineItemViews/LiveLocationRoomTimelineView.swift 66.66% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #5333      +/-   ##
===========================================
- Coverage    74.58%   74.49%   -0.10%     
===========================================
  Files          800      800              
  Lines        53498    53636     +138     
===========================================
+ Hits         39904    39958      +54     
- Misses       13594    13678      +84     
Flag Coverage Δ
unittests 64.47% <41.17%> (-0.07%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

@Velin92 Velin92 closed this Apr 2, 2026
@Velin92 Velin92 deleted the mauroromito/start_live_location branch April 2, 2026 20:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-wip for anything that isn't ready to ship and will be enabled at a later date

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant