Avoid HF token leaks in static snapshots#535
Merged
Merged
Conversation
Contributor
🪼 branch checks and previews
|
Contributor
🦄 change detectedThis Pull Request includes changes to the following packages.
|
🪼 branch checks and previews
Install Trackio from this PR (includes built frontend) pip install "https://huggingface.co/buckets/trackio/trackio-wheels/resolve/b049f26908b8bee8dbc286ff1a2fdc89b75373c6/trackio-0.25.0-py3-none-any.whl" |
|
The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update. |
Contributor
There was a problem hiding this comment.
Pull request overview
Updates Trackio’s static Space deployment flow to prevent Hugging Face access tokens from being embedded in static snapshot artifacts, aligning static dashboards with a “public snapshot data only” model.
Changes:
- Remove HF token usage from the static frontend data-fetch path (no auth headers).
- Force static sync/freeze outputs (Space + bucket/dataset) to be public and warn when
private=Trueis requested. - Update user-facing docs to clarify that
private=Trueis unsupported forsdk="static"and frozen static snapshots.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
trackio/frontend/src/lib/staticApi.js |
Removes Authorization header injection for static snapshot reads. |
trackio/deploy.py |
Stops writing tokens into static config.json, forces static repos/buckets public, adds warnings for private=True. |
docs/source/deploy_embed.md |
Documents that static dashboards require public snapshot data; removes/adjusts private=True guidance. |
docs/source/cli_commands.md |
Clarifies CLI --private is unsupported with --sdk static and for frozen snapshots. |
README.md |
Adds a short note that static spaces don’t support private=True. |
.changeset/rich-queens-marry.md |
Records the behavior change as a minor release note. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
- Convert private=True warning to ValueError in deploy_as_static_space, sync(sdk=static), and freeze - Add unit test asserting static Space config.json never contains an HF token Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
znation
approved these changes
Apr 26, 2026
Merged
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Static Spaces canot safely pass in HF_TOKENs so now we just reject private static sync/freeze requests instead of exposing HF tokens
Fixes #534