You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Marked hiking and cycling routes (Overpass API) are always downloaded and drawn in the outdoor style. They come for the browsed area in small blocks while the map is left alone, for downloaded regions one at a time, and with each region download.
Trail queries give way to browsing, run one at a time at least 10 s apart, and wait after busy answers (429, 502-504).
Downloaded maps with the same name are one row with a count and their total size which opens to the maps, each with its own actions, and can show or rename all of them. Each map keeps its own folder.
Trail downloads need Tactility main with TLS 1.3 (23 Nov 2026 or later).
Summary by CodeRabbit
New Features
Downloaded maps with matching names are grouped together, with individual maps still available for their own actions.
Hiking and cycling trails download automatically for completed and browsed map areas, and display with the outdoor map style.
Bug Fixes
Map browsing can take priority over background trail downloads, which retry later when conditions allow.
Improved handling of tile downloads and writes, including retries for temporary failures.
location_subscribe() takes a subscriber description since Tactility
#728. The app's own copy of the declarations was older, so the firmware
read the description from an argument the app never passed.
- Marked hiking and cycling routes are downloaded by themselves and drawn in the outdoor style
- Trail queries give way to browsing and run one at a time, with waits after busy answers
- Downloaded maps with the same name are one row that opens to its maps
- Fixes for a browsed tile that was fetched again and again, and for trails that never came for some places
File: No configuration file from this repository applied
Commit: Unavailable
Layers: Organization UI
Review profile: CHILL
Plan: Advanced
Run ID: 9bae63d1-e3aa-42ff-b3ec-08736ea16097
Commits
Reviewing files that changed from the base of the PR and between 6ea427b and f755ec8.
Files selected for processing: 10
Apps/Maps/CHANGELOG.md
Apps/Maps/main/Source/app/Downloader.cpp
Apps/Maps/main/Source/app/MapDebug.cpp
Apps/Maps/main/Source/app/MapScreens.cpp
Apps/Maps/main/Source/app/MapView.h
Apps/Maps/main/Source/app/PlatformTactility.cpp
Apps/Maps/main/Source/app/TileWorker.cpp
Apps/Maps/main/Source/app/TileWorker.h
Apps/Maps/main/Source/platform/Platform.h
Apps/Maps/main/Source/render/Trails.h
Walkthrough
This update adds automatic trail downloads for browsed map areas and completed regions, including retry scheduling, trail-file storage, and completion markers. Trail rendering follows the selected map style, and the trails setting is removed. The downloaded-maps screen groups regions with matching titles and provides group actions while preserving individual-map operations. Debug scripts add trail controls and log mirroring. The Maps version changes to 0.10.1.
Merge Risk: Moderate · previous review 6ea42
Trail downloads and grouped map rows work in the common case, but some failure paths can leave trails missing or mark regions complete too early. A delete or rename confirmation could also act on a different map after the list regroups. These problems are recoverable and narrow in trigger, but they should be fixed before merging.
Pre-merge checks: 4
Check name
Status
Explanation
Description Check
Check skipped - CodeRabbit’s high-level summary is enabled.
Title check
The title "Maps 0.10.1: Marked trails" names the main change. The PR adds marked hiking and cycling trail downloads and rendering, which the changeset implements across Downloader, TileWorker, TileSto…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title "Maps 0.10.1: Marked trails" names the main change. The PR adds marked hiking and cycling trail downloads and rendering, which the changeset implements across Downloader, TileWorker, TileStore, MapView, and the trail renderer. It also names the 0.10.1 version bump, which matches the manifest and Version.h changes. The title omits the grouped downloaded-map rows, the log mirror, and the settings removal, but it does not need to cover every detail.
Finishing Touches
Generate unit tests (beta)
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 10
Caution
Some comments are outside the diff and can’t be posted inline due to GitHub limitations.
⚠️ Outside diff range comments (4)
Minor · Remove trail markers when deleting a region. · Downloader.cpp:3116
Apps/Maps/main/Source/app/Downloader.cpp:3116 Minor · Functional Correctness · Quick win
Remove trail markers when deleting a region.
The new trails.ok file is not in this cleanup list. After a successful trail download, it prevents the final region-directory removal. scanRegions() registers that remaining directory even though meta.json was deleted, so deleted regions continue to consume the bounded region slots after restart.
Add trails.ok and trails.tmp to the cleanup list.
Minor · Mark trail coverage stale after deleting a region. · Downloader.cpp:3140
Apps/Maps/main/Source/app/Downloader.cpp:3140 Minor · Functional Correctness · Quick win
Mark trail coverage stale after deleting a region.
runDelete removes the region's files but leaves trailRegionsStale unchanged. If the trail coverage cache was rebuilt before the deletion, the deleted region's box stays in trailRegions. Until the next rebuild, trailsCovered() treats blocks inside that box as covered. runPendingTrails then drops such blocks without a query, so their trails are not downloaded.
Set the flag in runDelete. The next trail pass then rebuilds the cache from the surviving regions.
Minor · Update the trail instructions in About. · MapScreens.cpp:76
Apps/Maps/main/Source/app/MapScreens.cpp:76 Minor · Functional Correctness · Quick win
Update the trail instructions in About.
This text still directs users to “Settings, Marked trails” and says trails are off by default. This change removes that control and always enables trail downloads. State that downloads are automatic and that outdoor style controls trail visibility.
Minor · Select the browsed map's own row before any same-title group row. · MapScreens.cpp:587-589
Apps/Maps/main/Source/app/MapScreens.cpp:587-589 Minor · Functional Correctness · Quick win
Select the browsed map's own row before any same-title group row.
A browsed map renamed to the title of two or more ordinary maps can select the group row instead of its own row. This happens when the group row precedes the browsed row, which can occur because the browsed folder is registered after the ordinary maps. Choosing Rename from the browsed popup then opens "Rename all" for the group. Confirming renames the ordinary maps, and the browsed map keeps its title. The same wrong selection makes Delete from the browsed popup fail with "Open the group to delete its maps". Each rename or delete writes to the card. The change is reversible, but the trigger requires a specific title and ordering.
The browsed map always has its own row, so selectRegionRow should look for an exact row match first. Keep the same-title group match as a fallback, and require a non-empty title. This also matches the regionRows contract, which excludes the browsed map from title matching.
Suggested fix
void MapView::selectRegionRow(int index) {
for (int row = 0; row < regionRowCount; row++) {
- const RegionRow& entry = regionRowList[row];- if (entry.region == index ||- (entry.members > 1 && index >= 0 && index < regionCount && sameRegionTitle(regions[entry.region].title, regions[index].title) &&- regions[index].title[0] != '\0')) {+ if (regionRowList[row].region == index) {
regionList.select(row);
return;
}
}
+ // A group that shares the title comes only after the exact row, which the browsed map always has+ for (int row = 0; row < regionRowCount; row++) {+ const RegionRow& entry = regionRowList[row];+ if (entry.members > 1 && index >= 0 && index < regionCount && regions[index].title[0] != '\0' &&+ sameRegionTitle(regions[entry.region].title, regions[index].title)) {+ regionList.select(row);+ return;+ }+ }
regionList.select(std::min(regionList.selected(), std::max(regionRowCount - 1, 0)));
}
Review info
Run configuration
Source mode: Auto
Repository: Unavailable
Branch: Unavailable
File: No configuration file from this repository applied
Commit: Unavailable
Layers: Organization UI
Review profile: CHILL
Plan: Advanced
Run ID: bdd01281-f6bc-4e82-bac4-cb2e71d61a5d
Commits
Reviewing files that changed from the base of the PR and between feed410 and 6ea427b.
Files selected for processing: 27
Apps/Maps/CHANGELOG.md
Apps/Maps/main/Source/app/Debug.cpp
Apps/Maps/main/Source/app/Debug.h
Apps/Maps/main/Source/app/Downloader.cpp
Apps/Maps/main/Source/app/Downloader.h
Apps/Maps/main/Source/app/MapDebug.cpp
Apps/Maps/main/Source/app/MapDownloads.cpp
Apps/Maps/main/Source/app/MapScreens.cpp
Apps/Maps/main/Source/app/MapView.cpp
Apps/Maps/main/Source/app/MapView.h
Apps/Maps/main/Source/app/PlatformTactility.cpp
Apps/Maps/main/Source/app/TileWorker.cpp
Apps/Maps/main/Source/app/TileWorker.h
Apps/Maps/main/Source/platform/Platform.h
Apps/Maps/main/Source/platform/Version.h
Apps/Maps/main/Source/render/Trails.cpp
Apps/Maps/main/Source/render/Trails.h
Apps/Maps/main/Source/tiles/RegionMeta.cpp
Apps/Maps/main/Source/tiles/RegionMeta.h
Apps/Maps/main/Source/tiles/TileStore.cpp
Apps/Maps/main/Source/tiles/TileStore.h
Apps/Maps/main/Source/ui/MapOverlay.cpp
Apps/Maps/main/Source/ui/Settings.cpp
Apps/Maps/main/Source/ui/Settings.h
Apps/Maps/main/Source/ui/SettingsList.cpp
Apps/Maps/main/Source/ui/SettingsList.h
Apps/Maps/manifest.properties
Files with no reviewable changes: 4
Apps/Maps/main/Source/ui/Settings.cpp
Apps/Maps/main/Source/ui/Settings.h
Apps/Maps/main/Source/ui/SettingsList.cpp
Apps/Maps/main/Source/ui/SettingsList.h
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.
- trails.ok is written only after every trail file and the marker are stored; a failed file build fails the query
- Region trail queries cover the whole z12 tiles their box touches
- Every trail query starts at least 10 s after the last one; the short read timeout is reset after a trail query
- Region dialogs and the rename prompt act on the folder they named
- Log mirror: lines kept until written, filter read under the lock
- Tiles that come on screen from the cache look for their trail files
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Updates Maps to 0.10.1.
Trail downloads need Tactility main with TLS 1.3 (23 Nov 2026 or later).
Summary by CodeRabbit