feat: add deployment promote and rollback commands#91
Draft
Ruari-Phipps wants to merge 12 commits intomainfrom
Draft
feat: add deployment promote and rollback commands#91Ruari-Phipps wants to merge 12 commits intomainfrom
Ruari-Phipps wants to merge 12 commits intomainfrom
Conversation
This comment has been minimized.
This comment has been minimized.
1 similar comment
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Contributor
There was a problem hiding this comment.
Pull request overview
Adds deployment lifecycle management to ADK by introducing CLI subcommands to promote deployments across environments and rollback sandbox to a previous deployment, wiring these through the project/interface/platform API layers.
Changes:
- Add
poly deployments promoteandpoly deployments rollbackCLI subcommands (with--message,--force,--debug). - Add promote/rollback methods to
AgentStudioProject,AgentStudioInterface, andPlatformAPIHandler. - Refactor Platform API URL construction to move
/adk/v1from base URLs into route constants and add promote/rollback endpoints.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 15 comments.
| File | Description |
|---|---|
src/poly/project.py |
Adds promote_deployment / rollback_deployment methods on the project wrapper. |
src/poly/handlers/platform_api.py |
Refactors URL prefix handling; adds promote/rollback endpoints and request methods; removes headers from debug logs. |
src/poly/handlers/interface.py |
Exposes promote/rollback through the higher-level interface. |
src/poly/cli.py |
Adds new deployments promote / deployments rollback CLI commands and execution paths. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Contributor
Coverage Report
Changed file coverage
|
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.
Summary
Adds
poly deployments promoteandpoly deployments rollbacksubcommands, allowing users to promote a deployment to a target environment (pre-release or live) and rollback sandbox to a previous deployment version.Motivation
Enables deployment lifecycle management directly from the CLI, removing the need to use the Agent Studio UI for promotions and rollbacks.
Changes
poly deployments promote --from <id> --to <env>command with optional--messageand--forceflagspoly deployments rollback --to <id>command with optional--messageand--forceflagspromote_deploymentandrollback_deploymentmethods toAgentStudioProject,AgentStudioInterface, andPlatformAPIHandler/adk/v1prefix from base URLs into individual route constantsPROMOTE_URLandROLLBACK_URLendpoint constantsheadersfrom debug log outputTest strategy
poly <command>)Checklist
ruff check .andruff format --check .passpytestpassespolyCLI interface (or migration path documented)Screenshots / Logs