Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🔨 bake chart view map / TAS-829 #4479

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

sophiamersmann
Copy link
Member

@sophiamersmann sophiamersmann commented Jan 23, 2025

Bakes http://staging-site-bake-chart-views/grapher/_chartViews.json that maps chart view names to chart config IDs.

The Figma plugin uses this information for autocompletion and to fetch a chart view via UUID.

Ideally, we don't trigger a full rebuild when a chart view is created or deleted. I imagine authors creating a chart view going directly to Figma to try to import it, so there shouldn't be a too-long lag.

We wouldn't need to bake if we exposed the map on the Admin API instead, but Mojmir said auth is tricky. I wonder if we could add another auth method to our admin that would make that easier? But I don't think it's a good use of my time to think about admin auth at the beginning of the cycle, so I want to go with this for now. It would be easy to revert these changes if I reconsider during the cycle.

The map is baked to /grapher/_chartViews.json. I named it similarly to /grapher/_grapherRedirects.json, but I'm happy to rename it if the name I chose is awkward.

@github-actions github-actions bot added the staging-viz Let SVG tester fail silently in CI label Jan 23, 2025
@sophiamersmann sophiamersmann force-pushed the bake-chart-views branch 2 times, most recently from d26b0f0 to c9983d2 Compare January 23, 2025 11:31
@owidbot
Copy link
Contributor

owidbot commented Jan 23, 2025

Quick links (staging server):

Site Dev Site Preview Admin Wizard Docs

Login: ssh owid@staging-site-bake-chart-views

SVG tester:

Number of differences (default views): 0 ✅
Number of differences (all views): 0 ✅

Edited: 2025-01-24 10:16:17 UTC
Execution time: 1.32 seconds

@sophiamersmann sophiamersmann force-pushed the bake-chart-views branch 2 times, most recently from da86b74 to c856c45 Compare January 24, 2025 07:54
@sophiamersmann sophiamersmann marked this pull request as ready for review January 24, 2025 08:03
@sophiamersmann sophiamersmann changed the title 🔨 bake chart view map 🔨 bake chart view map / TAS-829 Jan 24, 2025
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
staging-viz Let SVG tester fail silently in CI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants