/osm dual basemap: OSM map ↔ ESRI satellite toggle#101
Conversation
The /osm slippy cockpit can now switch skins: OSM raster tiles <-> ESRI World Imagery satellite — the SAME keyless imagery source the ver-9 terrain skins (canyon/havel) drape from, so the flat map and the 3D scenes share one imagery truth. Same slippy addresses, same HHTL keys — two skins of one cascade. osm_tiles.rs: SAT_TILE_URL const + sat_tile_url() — ESRI's path is z/y/x (row before column), unlike OSM's z/x/y; a shared fill_template carries the axis order in the template so both fill through one call. The /api/osm/locate and /api/osm/tile/:z/:x/:y responses now report sat_tile_url + sat_source alongside the OSM fields (additive, non- breaking). New test pins the y-before-x swap. osm.rs (the inline page): a BASEMAPS table (src template, attribution, next), a `sat`/`osm` toggle in the map controls (button names the skin you will switch TO), attribution follows the active source (OSM contributors <-> Esri, Maxar, Earthstar Geographics). Verified headless on the extracted page HTML: OSM->sat->OSM round trip, tile srcs swap with the z/y/x order correct (12/2197/1340 <-> 12/1340/2197), attribution swaps. cockpit-server itself cannot compile in this container (rusty_v8 static-lib download blocked by org egress policy); the Rust side mirrors the existing tested handler pattern and CI runs the new test. Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_012jEwwaT5JZ5x8qWvcnaMYC
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_2f5bf1a2-f2d8-4242-94fa-30ec44be8789) |
|
Warning Review limit reached
Next review available in: 49 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe ChangesOSM dual basemap
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
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. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@crates/cockpit-server/src/osm.rs`:
- Around line 140-146: Update the click→locate handler to select the tile URL
matching the active basemap: use d.sat_tile_url when basemap is satellite and
d.tile_url otherwise, then display that value in the tile source panel instead
of always using d.tile_url.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 47bd8ac8-fcbd-4958-8ecc-c1e78a70a1b6
📒 Files selected for processing (3)
claude-notes/plans/2026-07-10-garmin-dem-satellite-skin.mdcrates/cockpit-server/src/osm.rscrates/cockpit-server/src/osm_tiles.rs
CodeRabbit finding on #101: the click->locate panel always displayed d.tile_url, so on the satellite basemap it showed the OSM URL — a mismatch with the visible tiles. Select d.sat_tile_url when the sat skin is active (the locate API already reports both). Verified headless with a stubbed locate API: click on OSM shows the openstreetmap URL, toggle to sat + click shows the arcgisonline URL. Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_012jEwwaT5JZ5x8qWvcnaMYC
The
/osmslippy cockpit can now switch skins: OSM raster ↔ ESRI World Imagery satellite — the same keyless imagery source the ver-9 terrain skins (canyon/havel) drape from, so the flat map and the 3D scenes share one imagery truth. Same slippy addresses, same HHTL keys — two skins of one cascade.What changed
crates/cockpit-server/src/osm_tiles.rsSAT_TILE_URL+sat_tile_url()— ESRI's path is z/y/x (row before column), unlike OSM's z/x/y; a sharedfill_templatecarries the axis order in the template so both fill through one call./api/osm/locateand/api/osm/tile/:z/:x/:ynow reportsat_tile_url+sat_sourcealongside the OSM fields (additive JSON, non-breaking).crates/cockpit-server/src/osm.rs(the inline page)BASEMAPStable (src template, attribution, next), asat/osmtoggle button in the map controls (names the skin you'll switch TO), attribution follows the active source (OSM contributors ↔ Esri, Maxar, Earthstar Geographics).Verification
12/2197/1340↔12/1340/2197); attribution swaps.Follow-ups still queued
GrandCanyon_S2_20260620.tif)🤖 Generated with Claude Code
Generated by Claude Code
Summary by CodeRabbit
New Features
/osmcockpit, allowing users to switch between OpenStreetMap and ESRI World Imagery satellite views.Tests