Repository navigation
Add durable waiting steps for external workflow input - #163
Merged
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Important Review skippedToo many files! This PR contains 124 files, which is 24 over the limit of 100. To get a review, reduce the PR to 100 files or fewer by splitting it into smaller PRs or changing its base branch. Upgrade to a paid plan to raise the limit. CodeRabbit couldn't verify your organization's usage billing state, so no usage-priced review was started. Retry after the billing service recovers.
|
Merged
This branch was successfully 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.
User problem
Asset workflows need to wait for an external value before dependent steps can run. Today a project has to invent its own way to pass a build value, approve a step, or choose among generated images. The workflow should record which value it used and keep that decision when the runner exits.
Closes #62.
Resulting behavior
fx/await@1useswith.schemato declare the required JSON value. A request can include a message and artifacts for human review. The workflow receives the value throughoutputs.answer. A keyed candidate mapping also exposes the original value throughoutputs.selected.The CLI, both SDKs, and the local viewer use the same request IDs, validation, and recorded receipts. The first valid submission wins. Retrying it returns the original receipt.
A parked run exits incomplete and can resume after submission.
--wait-for-answerskeeps a runner attached. An optional deadline can fail the step or let the workflow run its own fallback.Awaiting cards offer a Review action that opens the form on the right. They show a countdown when a deadline exists and a semantic outcome after resolution.
Added an Unreleased entry to CHANGELOG.md.
Affected scenarios
Before and after
Run both transcripts from fresh copies of
fixtures/waiting/with Grida installed. The first uses the released 0.11.0 engine. The second uses this branch's build through the samegrida fxlauncher. Invocation IDs are elided below.A. Before
B. After
Demo and evidence
The recording shows the same run through the viewer. The SDK supplies the revision, Review opens three image candidates, and submitting B changes the card to Selected. The review receipt shows the image and original submission channel. The paper finish screenshot shows a schema enum rendered as a picker.
How to test
fixtures/waiting/to a fresh project with the checkout engine and Grida Python SDK installed.grida fx start --backgroundandgrida fx run workflow.yaml --name review --wait-for-answers --max-usd 0 --open.rev-42through the Python SDK usingreview-variants/reviewas the run selector. Open Review on thechoosecard, select B, and submit.outputs/manifest.jsoncontains the supplied revision and the digest ofoutputs/image.png. The fixture README also explains how to exercise the form showcase and timeout paths.Verified with the Rust workspace suite, 1,738 Python tests, 569 JavaScript SDK tests, 309 viewer unit tests, all five waiting-step Chromium scenarios, and all 70 CLI conformance cases. The combined CLI and Python SDK journey also verifies a missing file inside a selected object.
Caveats
V1 uses the local viewer and requires no sign-in. A detached submission records the input immediately. Workflow execution continues on explicit resume. Each request can select one candidate, either as the whole value or by key in one top-level object field.
fx62-pr-review.mp4