Repository navigation
Add failed_deploy_trail: the evidence around a failed deploy in one call - #132
Open
shrijacked wants to merge 8 commits into
Open
shrijacked wants to merge 8 commits into
shrijacked wants to merge 8 commits into
Conversation
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
This branch has not been deployed
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
When a deploy fails, the evidence is spread across several reads.
failed_deploy_trailon bothProoflineClientandAsyncProoflineClientreturns one typedFailedDeployTrailso the next fix starts from evidence.failed_deployandfailing_check: the commit's latestFAILEDor regressed deploy (optionally in oneenvironment_id) and its earliestREGRESSEDcheckpoint.healthy_commit_shaandhealthy_deploy: the newest earlier commit whose deploy in the same environment and deployment task verified healthy (VERIFIEDorVERIFIED_UNTIL_SUPERSEDED, not regressed, not rolled back).commit_range: the failed commit and the commits after the healthy one, newest first, each with its recorded deploys, reviews, and findings. Each commit is listed twice (kind=DEPLOYMENT, then unfiltered) and a review that appears in both is read once.gaps: everything the trail could not establish. A failed read is kept as aProoflineErrorwith its traceback and chained exception removed, so a response body cannot stay attached to the result. API failures do not raise. An invalid SHA or a non-finitetimeoutraisesValueErrorbefore any request.The public API lists no commit history, so the caller passes earlier commits, for example
git rev-list --first-parent -n 50 <sha>~1. Only existing operations are used.timeoutdefaults to 120 seconds and uses the client's existing request deadline.Who it helps
Limits
timeout.reprhides it. Problem details keep the existing token redaction.Still unverified against the live service
list_reviewsacceptskindtogether withsearch. If it rejects that combination, the deployment lookup becomes one gap per commit and the unfiltered lookup still runs.search=<full SHA>returns one run or one per kind.ReviewSummary.public_keyis the valueget_deployment_reviewexpects.Test plan
ruff check .ruff format --check .mypy proofline scriptspython scripts/generate.py --checkpython scripts/contracts.pypytest -q— 267 passed, including after mergingorigin/main(10.2.3)scripts/check.pywas not run locally because it downloads uv and packages. CI runs it.Follow-ups
Made with Cursor