Skip to content

fix: fallback to Stadia Maps when CARTO basemap fails#1037

Merged
koala73 merged 1 commit intomainfrom
fix/basemap-fallback
Mar 5, 2026
Merged

fix: fallback to Stadia Maps when CARTO basemap fails#1037
koala73 merged 1 commit intomainfrom
fix/basemap-fallback

Conversation

@koala73
Copy link
Owner

@koala73 koala73 commented Mar 5, 2026

Summary

  • When CARTO CDN is unreachable (CORS error, outage), the map showed a blank canvas with no recovery
  • Adds automatic fallback to Stadia Maps (alidade_smooth_dark / alidade_smooth) via MapLibre's error event
  • Theme switching respects the fallback state
  • Stadia Maps: free tier, no API key, proper CORS headers

Test plan

  • Normal load: CARTO basemap loads as usual
  • Simulate CARTO failure (block basemaps.cartocdn.com in DevTools Network): Stadia fallback loads
  • Theme toggle works correctly in both normal and fallback states

When CARTO CDN is unreachable (CORS error, outage), the map canvas
shows blank. Add automatic fallback to Stadia Maps (alidade_smooth_dark
/ alidade_smooth) on MapLibre error event. Theme switching respects
the fallback state.
@chatgpt-codex-connector
Copy link

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@vercel
Copy link

vercel bot commented Mar 5, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
worldmonitor Ready Ready Preview, Comment Mar 5, 2026 3:20am

Request Review

@koala73 koala73 merged commit f4c43f0 into main Mar 5, 2026
3 checks passed
aldoyh pushed a commit to aldoyh/worldmonitor that referenced this pull request Mar 6, 2026
…3#1037)

When CARTO CDN is unreachable (CORS error, outage), the map canvas
shows blank. Add automatic fallback to Stadia Maps (alidade_smooth_dark
/ alidade_smooth) on MapLibre error event. Theme switching respects
the fallback state.
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.

1 participant