Add bt datasets snapshots for dataset version control#176
Draft
max-braintrust wants to merge 4 commits intomainfrom
Draft
Add bt datasets snapshots for dataset version control#176max-braintrust wants to merge 4 commits intomainfrom
bt datasets snapshots for dataset version control#176max-braintrust wants to merge 4 commits intomainfrom
Conversation
bt datasets snapshots for better dataset version controlbt datasets snapshots for dataset version control
|
Latest downloadable build artifacts for this PR commit
Available artifact names
|
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.
TL;DR
Follow up to: #104
Added bt datasets snapshots for managing saved dataset snapshots, plus a BTQL structured query fix needed by dataset row previews and snapshot creation.
What changed?
Added dataset snapshot management functionality:
Fixed dataset BTQL structured queries:
Updated structured BTQL select entries to use the current schema with expr and alias
Fixed bt datasets view failures caused by the older shorthand select shape
Added a constrained _xact_id BTQL query for snapshot creation when inferring the current dataset head
Kept required BTQL safety filters on dataset row/head queries
Added test coverage:
Unit tests for snapshot arg parsing, read/write auth routing, response deserialization, and restore target selection
Fixture coverage for snapshot creation, duplicate xact handling via x-bt-found-existing, and snapshot listing
Mock server support for dataset snapshot create and list endpoints
How to test?
Why make this change?
This gives users CLI access to the same saved dataset snapshot workflow used in the UI. It makes it possible to save, inspect, and restore dataset states without leaving the terminal. The BTQL fix also unblocks dataset viewing and snapshot head-xact inference against the current structured query schema.