Skip to content

Wire native branch/info/preview commands to CLI entry point - #27

Open
sandshoes wants to merge 2 commits into
mainfrom
tommy/protm-2258-wire-native-branch-info-preview
Open

sandshoes wants to merge 2 commits into
mainfrom
tommy/protm-2258-wire-native-branch-info-preview

Conversation

@sandshoes

Copy link
Copy Markdown
Contributor

Summary

  • branch (list/status/delete), info, and preview previously shelled out to the upstream Forward tb package instead of using the SDK's own native implementations. This wires them to the existing run_branch_list/run_branch_status/run_branch_delete, run_info, and run_preview implementations, same pattern as Wire native build/deploy/dev commands to CLI entry point #25 (build/deploy/dev) and Wire native pull/login commands to CLI entry point #26 (pull/login).
  • tinybird branch list prints branch names; tinybird branch status [name] and tinybird branch delete <name> match the CLI's existing argument shape. tinybird info [--json] prints workspace/project/branch info. tinybird preview [--dry-run] [--check] [--name] [--local|--branch] builds and deploys to a temporary preview branch.
  • Added a README section documenting tinybird preview, which wasn't previously documented.

Closes PROTM-2258: https://linear.app/tinybird/issue/PROTM-2258/python-sdk-wire-native-branchinfopreview-commands-to-cli-entry-point

Checklist

  • CI is green (lint, typecheck, test, secrets)
  • pre-commit run --all-files passes locally
  • Tests were added or updated when behavior changed
  • Public API / typing changes were reviewed
  • Documentation was updated (README.md / CONTRIBUTING.md) if needed
  • Breaking changes are clearly documented
  • CHANGELOG.md was updated when user-facing behavior changed

Note: the secrets/gitleaks pre-commit target fails in this sandbox on an unrelated SSL cert error fetching its environment — not related to this change (same note as PRs #24-#26).

`branch`, `info`, and `preview` previously shelled out to the upstream
Forward `tb` package. Wire them to the SDK's existing native
implementations (run_branch_list/status/delete, run_info, run_preview)
so these commands work without `tb` installed alongside the SDK.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…alled Tinybird CLI

branch, info, and preview already work correctly via the real tb CLI
delegation path (main's SDK_OWNED_COMMANDS policy). Reimplementing
them against the raw API duplicates logic the installed CLI already
owns and can drift from its actual behavior.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
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