Skip to content

Update existingLoiFeatures to depend on camera bounds - #3887

Merged
andreia-ferreira merged 7 commits into
masterfrom
andreia/3866/existing-features-within-bounds
Aug 21, 2026
Merged

Update existingLoiFeatures to depend on camera bounds#3887
andreia-ferreira merged 7 commits into
masterfrom
andreia/3866/existing-features-within-bounds

Conversation

@andreia-ferreira

Copy link
Copy Markdown
Collaborator

Towards #3866

This PR improves the previously introduced existingLoiFeatures, combining it with the getCurrentCameraPosition flow in order to only render the features within the bounds. This prevents potential OOMs due to the fact that these features, drawn in the drop pin/draw area screens, are not clusterable, so they'd all be rendered at once if not bounded.

It also removes the uneeded extension launchWhenTaskVisible which was required for when the data collection was a view pager.

@shobhitagarwal1612 PTAL?

…ng-features-within-bounds

# Conflicts:
#	app/src/main/java/org/groundplatform/android/ui/datacollection/DataCollectionViewModel.kt
#	app/src/test/java/org/groundplatform/android/ui/common/BaseMapViewModelTest.kt
@codecov

codecov Bot commented Aug 21, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 62.06897% with 11 lines in your changes missing coverage. Please review.
✅ Project coverage is 68.80%. Comparing base (1bd6c53) to head (ec97a16).

Files with missing lines Patch % Lines
...ui/datacollection/tasks/AbstractTaskMapFragment.kt 0.00% 4 Missing ⚠️
...ollection/tasks/polygon/DrawAreaTaskMapFragment.kt 72.72% 3 Missing ⚠️
...n/tasks/location/CaptureLocationTaskMapFragment.kt 0.00% 2 Missing ⚠️
...oundplatform/android/ui/common/BaseMapViewModel.kt 90.90% 0 Missing and 1 partial ⚠️
...tacollection/tasks/point/DropPinTaskMapFragment.kt 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff            @@
##             master    #3887   +/-   ##
=========================================
  Coverage     68.79%   68.80%           
- Complexity     1928     1929    +1     
=========================================
  Files           412      411    -1     
  Lines         10971    10958   -13     
  Branches       1432     1428    -4     
=========================================
- Hits           7548     7540    -8     
+ Misses         2676     2673    -3     
+ Partials        747      745    -2     
Files with missing lines Coverage Δ
...droid/ui/datacollection/DataCollectionViewModel.kt 80.93% <ø> (-0.24%) ⬇️
...oundplatform/android/ui/common/BaseMapViewModel.kt 63.49% <90.90%> (-0.58%) ⬇️
...tacollection/tasks/point/DropPinTaskMapFragment.kt 14.28% <0.00%> (+0.95%) ⬆️
...n/tasks/location/CaptureLocationTaskMapFragment.kt 0.00% <0.00%> (ø)
...ollection/tasks/polygon/DrawAreaTaskMapFragment.kt 50.00% <72.72%> (+2.17%) ⬆️
...ui/datacollection/tasks/AbstractTaskMapFragment.kt 60.27% <0.00%> (ø)

... and 2 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@andreia-ferreira
andreia-ferreira merged commit 14387e7 into master Aug 21, 2026
19 checks passed
@andreia-ferreira
andreia-ferreira deleted the andreia/3866/existing-features-within-bounds branch August 21, 2026 10:51
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