examples: add task dependency chain example (06-task-dependencies)#375
Closed
axon-agent[bot] wants to merge 1 commit intomainfrom
Closed
examples: add task dependency chain example (06-task-dependencies)#375axon-agent[bot] wants to merge 1 commit intomainfrom
axon-agent[bot] wants to merge 1 commit intomainfrom
Conversation
Add a new example directory demonstrating how to chain tasks with dependsOn into an implement -> test -> review pipeline. Includes documentation on prompt templating with dependency outputs and results. Addresses the gap that dependsOn is documented in the README and reference docs but has no working example manifests. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
There was a problem hiding this comment.
1 issue found across 6 files
Prompt for AI agents (all issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="examples/06-task-dependencies/README.md">
<violation number="1" location="examples/06-task-dependencies/README.md:129">
P2: Inaccurate failure propagation description. Since `review` depends on `write-tests` (not directly on `implement`), when `implement` fails the message on `review` would be *"Dependency 'write-tests' failed"*, not *"Dependency 'implement' failed"*. The failure also isn't truly "immediate" for `review` — it propagates through `write-tests` first.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
| even without `dependsOn`. The `dependsOn` field adds the additional | ||
| guarantee that a task only starts after its dependencies **succeed** | ||
| (not just finish). | ||
| - If `implement` fails, both `write-tests` and `review` fail immediately |
There was a problem hiding this comment.
P2: Inaccurate failure propagation description. Since review depends on write-tests (not directly on implement), when implement fails the message on review would be "Dependency 'write-tests' failed", not "Dependency 'implement' failed". The failure also isn't truly "immediate" for review — it propagates through write-tests first.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At examples/06-task-dependencies/README.md, line 129:
<comment>Inaccurate failure propagation description. Since `review` depends on `write-tests` (not directly on `implement`), when `implement` fails the message on `review` would be *"Dependency 'write-tests' failed"*, not *"Dependency 'implement' failed"*. The failure also isn't truly "immediate" for `review` — it propagates through `write-tests` first.</comment>
<file context>
@@ -0,0 +1,133 @@
+ even without `dependsOn`. The `dependsOn` field adds the additional
+ guarantee that a task only starts after its dependencies **succeed**
+ (not just finish).
+- If `implement` fails, both `write-tests` and `review` fail immediately
+ with the message "Dependency 'implement' failed".
+- Prompt templates are resolved once, right before the Job is created.
</file context>
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.
🤖 Axon Agent @gjkim42
Summary
examples/06-task-dependencies/with a three-stage pipeline: implement → write-tests → reviewdependsOnfor task chaining and Go template syntax for referencing upstream outputs/resultsexamples/README.mdto include the new example in the tableMotivation
The
dependsOnfeature is fully implemented, tested, and documented in the README ("Chain tasks with dependencies") and reference docs, but there are zero working example manifests in theexamples/directory. Users encounteringdependsOnin the docs have no ready-to-use YAML to learn from.This fills that gap with a realistic pipeline pattern and thorough documentation covering:
Waitingphase worksOutputs,Results, andName--depends-ondependsOnand branch mutexFiles
examples/06-task-dependencies/README.mdexamples/06-task-dependencies/tasks.yamlexamples/06-task-dependencies/workspace.yamlexamples/06-task-dependencies/credentials-secret.yamlexamples/06-task-dependencies/github-token-secret.yamlexamples/README.mdRelated
Test plan
test/integration/task_test.go🤖 Generated with Claude Code
Summary by cubic
Adds a new example that demonstrates chaining tasks with dependsOn in a three-stage pipeline (implement → write-tests → review). Updates the examples index to include it.
Written for commit 9b28937. Summary will update on new commits.