Skip to content

feat: agentic runs - #212

Merged
pedronauck merged 5 commits into
mainfrom
agentic
Jun 19, 2026
Merged

pedronauck merged 5 commits into
mainfrom
agentic

Conversation

@pedronauck

@pedronauck pedronauck commented Jun 19, 2026 •

Copy link
Copy Markdown
Member

Summary by CodeRabbit

  • New Features

    • Added dependency-aware parallel task execution via tasks run --parallel-tasks, including agentic conflict resolution and enhanced parallel-run integration UI.
    • Added agentic recovery that can remediate and restart failed runs, with new --recovery* controls.
    • Added support to target and run a single specific task in PRD task mode.
  • Configuration & Documentation

    • Updated tasks run help text and wizard flows for parallel-tasks and recovery flags, including workspace defaulting/validation.
  • Bug Fixes

    • Improved persisted exec-run recovery/result handling and introduced result schema versioning for executor outputs.

@pedronauck pedronauck self-assigned this Jun 19, 2026
@greptile-apps

greptile-apps Bot commented Jun 19, 2026

Copy link
Copy Markdown

Too many files changed for review. (120 files found, 100 file limit)

@coderabbitai

coderabbitai Bot commented Jun 19, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 232b79d3-79d1-4b02-8a09-8737fa801442

📥 Commits

Reviewing files that changed from the base of the PR and between 2807b63 and fe36862.

⛔ Files ignored due to path filters (1)
  • skeeper.lock is excluded by !**/*.lock
📒 Files selected for processing (1)
  • internal/daemon/run_manager_test.go
🚧 Files skipped from review as they are similar to previous changes (1)
  • internal/daemon/run_manager_test.go

Walkthrough

This PR adds recovery and dependency-aware parallel task execution configuration and runtime plumbing, introduces recovery and parallel orchestration in core and daemon paths, updates ACP setup timeout handling, adds parallel run UI/event support, and expands CLI, integration, and end-to-end test coverage.

Changes

Parallel tasks and recovery execution

Layer / File(s) Summary
Config and runtime contracts
go.mod, internal/core/workspace/*, internal/core/api.go, internal/core/model/*, internal/core/tasks/*, internal/core/plan/*, internal/core/kernel/commands/run_start.go
Adds recovery and parallel-task config types/defaults/validation, extends core and runtime models with recovery and target-task fields, derives task IDs from filenames, filters PRD task preparation to a selected target task, and threads recovery into run-start commands.
CLI flags and wizard wiring
internal/cli/daemon_commands.go, internal/cli/state.go, internal/cli/workspace_config.go, internal/cli/reviews_exec_daemon.go, internal/cli/tasks_run_wizard.go, internal/cli/testdata/*, internal/cli/*test.go
Adds recovery and --parallel-tasks flags, builds runtime override payloads, applies workspace defaults, updates wizard execution and review steps, documents help output, and adds CLI forwarding and validation tests.
ACP setup and exec handling
internal/core/agent/client.go, internal/core/run/internal/acpshared/*, internal/core/run/exec/*, internal/core/run/executor/*, internal/core/subprocess/*
Separates ACP setup context from run context, introduces init timeout handling and typed cancellation/timeouts, delays activity watchdog start until setup completes, adds exec schema versioning, and supports runtime system prompt overrides.
Recovery framework and journals
internal/core/run/recovery/*, internal/core/run/internal/worktree/snapshot.go, internal/core/extension/*, internal/core/model/run_scope.go
Adds recovery outcomes, remediation strategy/orchestrator contracts, verdict parsing, prompt generation, diff auditing, run outcome readers, journal refresh/event sink plumbing, and richer worktree snapshot metadata.
Parallel orchestration and conflict resolution
internal/core/run/parallel/*
Adds dependency-wave construction, parallel execution orchestration with recovery and conflict resolution, event emission, conflict resolver runtime prompting, and comprehensive orchestrator/resolver/wave tests.
Parallel run UI
internal/core/run/ui/*
Adds parallel event translation, wave-grouped sidebar rendering, integration pane state/rendering, multi-run forwarding of parallel events, and UI tests for wave, conflict, resolve, rollback, and layout behavior.
Daemon recovery and parallel task execution
internal/daemon/*
Resolves daemon recovery and parallel-task overrides, wraps workflow and exec runs with recovery, routes task-multi runs through the parallel orchestrator, wires review-watch recovery, and adds daemon integration tests.

Estimated code review effort

🎯 5 (Critical) | ⏱️ ~120 minutes

Possibly related PRs

  • compozy/compozy#60: Both PRs modify internal/core/api.go’s exported core.Config/Config.Validate() logic.
  • compozy/compozy#68: Both PRs touch the typed core/kernel command path, including internal/core/kernel/commands/run_start.go.
  • compozy/compozy#70: Both PRs extend internal/core/agent/client.go session setup behavior.
🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Title check ⚠️ Warning The PR title 'feat: agentic runs' is vague and does not clearly summarize the main changes in this large, multi-faceted changeset. Use a more specific title that captures the primary feature scope, such as 'feat: add agentic recovery and parallel task orchestration for workflow runs' or break into multiple PRs with clearer scopes.
Docstring Coverage ⚠️ Warning Docstring coverage is 6.93% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch agentic

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 15

🧹 Nitpick comments (27)
internal/core/run/parallel/orchestrator.go (1)

251-253: Avoid silently defaulting to context.Background() in Run.

This violates the coding guideline that forbids context.Background() outside main and focused tests. The fallback can mask caller mistakes and breaks explicit cancellation/deadline ownership at a runtime boundary. No callers currently pass nil context, so this is safe to change to return an error instead.

Suggested diff
 func (o *ExecutionOrchestrator) Run(ctx context.Context, plan ParallelPlan) (ParallelOutcome, error) {
-	if ctx == nil {
-		ctx = context.Background()
-	}
+	if ctx == nil {
+		return ParallelOutcome{}, errors.New("parallel execution: missing context")
+	}
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/parallel/orchestrator.go` around lines 251 - 253, The Run
function currently silently defaults to context.Background() when a nil context
is passed in, which violates the coding guideline forbidding
context.Background() outside main and focused tests. Instead of checking if ctx
is nil and defaulting to context.Background(), remove this fallback logic and
return an error when ctx is nil to ensure callers explicitly provide a context
with proper cancellation and deadline ownership.

Source: Coding guidelines

internal/core/run/ui/multi_remote_test.go (1)

881-935: ⚡ Quick win

Use the required t.Run("Should...") style for this new test case.

Please wrap this scenario in a t.Run("Should ...") block to match the test contract used across the repo.

As per coding guidelines, **/*_test.go: “MUST use t.Run("Should...") pattern for ALL test cases”.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/ui/multi_remote_test.go` around lines 881 - 935, The test
function TestMultiRunForwardsParallelEventsToActiveChild does not follow the
required t.Run("Should...") pattern specified in the repository's coding
guidelines. Wrap all the test logic currently in the function body inside a
t.Run call with a descriptive name following the "Should..." pattern, such as
t.Run("Should forward parallel events to active child", ...), while keeping the
test function signature and t.Parallel() call at the top level.

Source: Coding guidelines

internal/core/run/parallel/resolver.go (1)

128-130: ⚡ Quick win

Avoid context.Background() fallback in production resolver flow.

Using context.Background() here drops caller cancellation/deadline semantics. Prefer rejecting nil context explicitly so external calls (git/make/executor) remain cancellable only via caller-owned context.

Suggested fix
-	if ctx == nil {
-		ctx = context.Background()
-	}
+	if ctx == nil {
+		return ConflictResult{}, errors.New("conflict resolver: context is required")
+	}

As per coding guidelines, “Pass context.Context as the first argument to all functions crossing runtime boundaries; avoid context.Background() outside main and focused tests`.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/parallel/resolver.go` around lines 128 - 130, The nil
context fallback in the resolver flow is dropping caller cancellation and
deadline semantics by assigning context.Background(). Remove the conditional
check that assigns context.Background() when ctx is nil, and instead ensure the
context is always provided by the caller so that external calls to git, make, or
executor remain cancellable through the caller-owned context. This aligns with
the coding guideline to avoid context.Background() outside of main and focused
tests.

Source: Coding guidelines

internal/core/run/parallel/orchestrator_test.go (1)

23-618: 🏗️ Heavy lift

Use the required t.Run("Should...") pattern for added test cases.

This file adds many direct top-level cases without the repository’s required subtest naming/pattern. Please wrap scenarios with t.Run("Should ...") (table-driven where possible) to match test conventions.

As per coding guidelines, **/*_test.go: “MUST use t.Run("Should...") pattern for ALL test cases” and “Use table-driven tests with subtests (t.Run) as the default pattern”.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/parallel/orchestrator_test.go` around lines 23 - 618, The
test file contains multiple top-level test functions (such as
TestParallelFSMModelsRequiredHappyPathTransitions,
TestParallelExecutionOrchestratorBoundsWaveConcurrency,
TestParallelExecutionOrchestratorMergesWaveSeriallyInTaskOrder, and others) that
do not follow the repository's required testing pattern. Refactor these tests to
use the t.Run("Should...") pattern with descriptive subtest names that clearly
indicate what behavior is being tested. Where applicable, convert test logic
into table-driven test structures using t.Run() for each test case to improve
readability and maintainability while adhering to the coding guidelines that
require ALL test cases in *_test.go files to use the t.Run("Should...") pattern.

Source: Coding guidelines

internal/core/run/parallel/resolver_test.go (1)

18-217: ⚡ Quick win

Align resolver tests with required t.Run("Should...") naming/pattern.

Please wrap/rename these scenarios to the repo’s required subtest convention (including table rows), so all cases follow Should... semantics consistently.

As per coding guidelines, **/*_test.go: “MUST use t.Run("Should...") pattern for ALL test cases” and “Use table-driven tests with subtests (t.Run) as the default pattern”.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/parallel/resolver_test.go` around lines 18 - 217, Align all
test cases in the resolver_test.go file to follow the required
t.Run("Should...") naming pattern as per coding guidelines. For the single test
functions TestConflictResolverSystemPromptIncludesSkillAndConflictContext,
TestAgenticConflictResolutionBoundsAttemptsAtThree, and
TestAgenticConflictResolutionBuildsRuntimeConfigWithAgentSelection, wrap their
test logic inside a t.Run() call with a descriptive "Should..." name. For the
table-driven test
TestAgenticConflictResolutionDerivesResultFromStatusMarkersAndBuildGate, replace
the existing tt.name values in the test table with descriptive names following
the "Should..." pattern (for example, change "clean status and passing build
resolves" to "Should resolve when status is clean and build passes"). Ensure all
subtests consistently use the t.Run("Should...") convention throughout the file.

Source: Coding guidelines

internal/daemon/run_manager_test.go (1)

1749-1776: ⚡ Quick win

Use the required t.Run("Should...") test-case name.

Rename this new subtest to the repository’s required Should... pattern, e.g. Should merge daemon recovery overrides with project defaults.

As per coding guidelines, “MUST use t.Run("Should...") pattern for ALL test cases.”

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/daemon/run_manager_test.go` around lines 1749 - 1776, The test case
name in the t.Run() call does not follow the repository's required naming
convention. Rename the test case from "resolve recovery config" to follow the
"Should..." pattern (e.g., "Should merge daemon recovery overrides with project
defaults") as required by the coding guidelines for all test cases using
t.Run().

Source: Coding guidelines

internal/daemon/task_multi_test.go (1)

653-816: ⚡ Quick win

Wrap the new cases in t.Run("Should...") subtests.

These new test cases skip the required Should... subtest pattern; the invalid-launch-input checks would also read better as table-driven subtests.

As per coding guidelines, “MUST use t.Run("Should...") pattern for ALL test cases” and “Use table-driven tests with subtests (t.Run) as the default pattern.”

Also applies to: 2037-2315

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/daemon/task_multi_test.go` around lines 653 - 816, The test function
TestRunManagerStartTaskWorktreeChildRejectsInvalidLaunchInputs contains three
separate validation checks that are currently sequential if-statements but
should be refactored into table-driven subtests. Create a table with test case
structs containing fields for the test name (following "Should..." pattern), the
targetTaskNumber, taskMultiWorktreeBase configuration, allocator setup, and
expected error message substring. Then iterate through the table using t.Run
with the "Should..." naming pattern to execute each validation check as an
independent subtest, improving readability and following the required coding
guidelines.

Source: Coding guidelines

internal/core/api.go (1)

189-191: ⚡ Quick win

Wrap recovery validation errors with call-site context.

Returning the raw error loses where validation failed in the core config path.

💡 Suggested change
 if err := workspacecfg.ValidateAgentRecoveryConfig("core config", cfg.Recovery); err != nil {
-	return err
+	return fmt.Errorf("validate core recovery config: %w", err)
 }

As per coding guidelines, prefer explicit wrapped error returns using fmt.Errorf("context: %w", err).

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/api.go` around lines 189 - 191, The error returned from the
workspacecfg.ValidateAgentRecoveryConfig call is being returned directly without
wrapping it with context information. Modify the error return statement to wrap
the error using fmt.Errorf with a descriptive message that indicates this is a
recovery config validation failure in the core config validation flow. This will
preserve the error chain and provide better debugging context about where the
validation failed.

Source: Coding guidelines

internal/cli/reviews_exec_daemon.go (1)

684-686: ⚡ Quick win

Add context when propagating recovery override parsing errors (both builders).

Both paths return bare errors, which makes it harder to identify whether the failure came from review-run or exec override assembly.

💡 Suggested change
 recovery, err := s.recoveryFlagOverrides(cmd)
 if err != nil {
-	return nil, err
+	return nil, fmt.Errorf("build review runtime recovery overrides: %w", err)
 }
 recovery, err := s.recoveryFlagOverrides(cmd)
 if err != nil {
-	return nil, err
+	return nil, fmt.Errorf("build exec runtime recovery overrides: %w", err)
 }

As per coding guidelines, prefer explicit wrapped error returns using fmt.Errorf("context: %w", err).

Also applies to: 765-767

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/cli/reviews_exec_daemon.go` around lines 684 - 686, The error
handling at lines 684-686 and 765-767 returns bare errors without context,
making it unclear whether the failure came from review-run or exec override
assembly. Wrap both error returns using fmt.Errorf with appropriate context
messages that identify which builder or operation failed (e.g., "failed to parse
review-run override: %w" or "failed to parse exec override: %w"). Ensure each
wrapped error clearly indicates which path the error originated from to improve
debuggability.

Source: Coding guidelines

internal/core/run/executor/execution_acp_test.go (1)

328-591: 🏗️ Heavy lift

Refactor the newly added timeout scenarios into table-driven t.Run("Should...") subtests.

The new cases are valid, but they currently duplicate setup/execute/assert scaffolding and don’t follow the repository’s default subtest structure requirement.

💡 Suggested structure
-func TestExecuteJobWithTimeoutSetupInitDeadlineReturnsTypedTimeout(t *testing.T) { ... }
-func TestExecuteJobWithTimeoutSetupHangUsesInitTimeout(t *testing.T) { ... }
-func TestExecuteJobWithTimeoutSetupCancellationReturnsCanceled(t *testing.T) { ... }
+func TestExecuteJobWithTimeoutSetupPaths(t *testing.T) {
+	t.Parallel()
+
+	cases := []struct{
+		name string
+		// setup + expected assertions
+	}{
+		{name: "Should classify setup init-timeout as timeout"},
+		{name: "Should classify setup cancel as canceled"},
+		{name: "Should keep slow setup valid before activity watchdog timeout"},
+	}
+
+	for _, tc := range cases {
+		tc := tc
+		t.Run(tc.name, func(t *testing.T) {
+			t.Parallel()
+			// arrange, execute, assert
+		})
+	}
+}

As per coding guidelines, **/*_test.go must use t.Run("Should...") and table-driven subtests as the default pattern.

Also applies to: 994-1082

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/executor/execution_acp_test.go` around lines 328 - 591, The
timeout-related test functions
TestJobRunnerRetriesSetupErrorAfterInitTimeoutThenSucceeds,
TestExecuteJobWithTimeoutClassifiesSetupErrorAfterInitTimeout,
TestExecuteJobWithTimeoutSlowSetupArmsActivityWatchdogAfterSessionEstablished,
TestExecuteJobWithTimeoutSetupInitDeadlineReturnsTypedTimeout, and
TestExecuteJobWithTimeoutSetupCancellationReturnsCanceled are written as
separate test functions with duplicated scaffolding instead of using the
repository's standard table-driven subtest pattern. Consolidate these tests by
creating a single parent test function that uses t.Run with subtests for each
scenario, extracting the common setup and execution logic into table entries
where each entry defines the specific client behavior, assertions, and expected
outcomes for that particular timeout scenario.

Source: Coding guidelines

internal/core/model/model_test.go (1)

545-576: ⚡ Quick win

Wrap this test in a t.Run("Should...") subtest.

TestRuntimeConfigClonePreservesTargetTaskNumber is a direct top-level case; wrap it in a Should... subtest to match the repository’s enforced test pattern.

Suggested patch
 func TestRuntimeConfigClonePreservesTargetTaskNumber(t *testing.T) {
 	t.Parallel()
 
-	targetTaskNumber := 3
-	cfg := &model.RuntimeConfig{
-		TargetTaskNumber: &targetTaskNumber,
-		AddDirs:          []string{"/workspace/docs"},
-	}
-
-	cloned := cfg.Clone()
-	if cloned == nil {
-		t.Fatal("Clone() = nil, want runtime config")
-	}
-	if cloned.TargetTaskNumber == nil {
-		t.Fatal("Clone().TargetTaskNumber = nil, want copied target")
-	}
-	if cloned.TargetTaskNumber == cfg.TargetTaskNumber {
-		t.Fatal("Clone().TargetTaskNumber aliases base pointer")
-	}
-	if *cloned.TargetTaskNumber != targetTaskNumber {
-		t.Fatalf("Clone().TargetTaskNumber = %d, want %d", *cloned.TargetTaskNumber, targetTaskNumber)
-	}
-
-	*cloned.TargetTaskNumber = 7
-	cloned.AddDirs[0] = "/workspace/changed"
-	if *cfg.TargetTaskNumber != targetTaskNumber {
-		t.Fatalf("base TargetTaskNumber changed to %d, want %d", *cfg.TargetTaskNumber, targetTaskNumber)
-	}
-	if cfg.AddDirs[0] != "/workspace/docs" {
-		t.Fatalf("base AddDirs changed to %#v", cfg.AddDirs)
-	}
+	t.Run("Should deep-copy TargetTaskNumber without aliasing", func(t *testing.T) {
+		t.Parallel()
+
+		targetTaskNumber := 3
+		cfg := &model.RuntimeConfig{
+			TargetTaskNumber: &targetTaskNumber,
+			AddDirs:          []string{"/workspace/docs"},
+		}
+
+		cloned := cfg.Clone()
+		if cloned == nil {
+			t.Fatal("Clone() = nil, want runtime config")
+		}
+		if cloned.TargetTaskNumber == nil {
+			t.Fatal("Clone().TargetTaskNumber = nil, want copied target")
+		}
+		if cloned.TargetTaskNumber == cfg.TargetTaskNumber {
+			t.Fatal("Clone().TargetTaskNumber aliases base pointer")
+		}
+		if *cloned.TargetTaskNumber != targetTaskNumber {
+			t.Fatalf("Clone().TargetTaskNumber = %d, want %d", *cloned.TargetTaskNumber, targetTaskNumber)
+		}
+
+		*cloned.TargetTaskNumber = 7
+		cloned.AddDirs[0] = "/workspace/changed"
+		if *cfg.TargetTaskNumber != targetTaskNumber {
+			t.Fatalf("base TargetTaskNumber changed to %d, want %d", *cfg.TargetTaskNumber, targetTaskNumber)
+		}
+		if cfg.AddDirs[0] != "/workspace/docs" {
+			t.Fatalf("base AddDirs changed to %#v", cfg.AddDirs)
+		}
+	})
 }

As per coding guidelines, **/*_test.go MUST use t.Run("Should...") for all test cases and use table-driven tests with subtests as the default pattern.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/model/model_test.go` around lines 545 - 576, Refactor the
TestRuntimeConfigClonePreservesTargetTaskNumber function to match the
repository's test pattern guidelines by wrapping the test logic in a t.Run()
call with a descriptive "Should..." subtest name. Keep the t.Parallel() call at
the function level, then wrap all the test assertions and logic within a t.Run()
that describes what the test validates (e.g., "Should preserve TargetTaskNumber
on clone" or similar). This ensures the test follows the enforced table-driven
test pattern with subtests used as the default pattern across all test files.

Source: Coding guidelines

internal/core/tasks/parser_test.go (1)

291-300: ⚡ Quick win

Rename subtests to the required Should... format.

The table-driven structure is good, but current case names do not follow the enforced t.Run("Should...") convention.

Suggested patch
 	tests := []struct {
 		name string
 		in   string
 		want string
 	}{
-		{name: "canonical filename", in: "task_042.md", want: "task_042"},
-		{name: "extensionless identity", in: "task_15", want: "task_15"},
-		{name: "nested path", in: "features/auth/task_07.md", want: "features/auth/task_07"},
-		{name: "backslash path", in: `features\auth\task_08.md`, want: "features/auth/task_08"},
-		{name: "empty input", in: "   ", want: ""},
+		{name: "Should parse canonical filename", in: "task_042.md", want: "task_042"},
+		{name: "Should keep extensionless identity", in: "task_15", want: "task_15"},
+		{name: "Should preserve nested path identity", in: "features/auth/task_07.md", want: "features/auth/task_07"},
+		{name: "Should normalize backslash path", in: `features\auth\task_08.md`, want: "features/auth/task_08"},
+		{name: "Should return empty for whitespace input", in: "   ", want: ""},
 	}

As per coding guidelines, **/*_test.go MUST use t.Run("Should...") for all test cases.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/tasks/parser_test.go` around lines 291 - 300, The test case
names in the table-driven test do not follow the required Should... naming
convention. Update each name field in the tests slice to start with "Should" and
provide descriptive context. For example, change "canonical filename" to "Should
extract canonical filename", "extensionless identity" to "Should handle
extensionless identity", "nested path" to "Should preserve nested path",
"backslash path" to "Should convert backslash path to forward slashes", and
"empty input" to "Should return empty string for whitespace input". Ensure all
test cases from the table starting at line 291 through the empty input case are
updated to comply with this naming convention.

Source: Coding guidelines

internal/core/run/exec/exec_test.go (1)

59-82: ⚡ Quick win

Align the new tests with the required subtest pattern.

Please wrap these new test cases in t.Run("Should ...") blocks (table-driven if adding more scenarios) to follow the repository test conventions.

As per coding guidelines: **/*_test.go requires “MUST use t.Run("Should...") pattern for ALL test cases” and “Use table-driven tests with subtests (t.Run) as the default pattern.”

Also applies to: 350-394

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/exec/exec_test.go` around lines 59 - 82, The test function
TestPersistedExecRunOmitsRuntimeOnlyRecoveryAttempt does not follow the
repository's required testing pattern of using t.Run("Should ...") for all test
cases. Refactor this test by wrapping all the test logic inside a t.Run() call
with a descriptive subtest name that starts with "Should" (for example,
describing that it should omit runtime-only recovery attempts), passing an
anonymous function that receives the testing.T parameter and contains all the
current test body code.

Source: Coding guidelines

internal/cli/workspace_config_test.go (1)

606-691: ⚡ Quick win

Use subtests for the new test cases.

These newly added cases are top-level tests; please wrap each case in t.Run("Should ...") (table-driven when practical) to match repo test conventions.

As per coding guidelines: **/*_test.go requires “MUST use t.Run("Should...") pattern for ALL test cases” and “Use table-driven tests with subtests (t.Run) as the default pattern.”

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/cli/workspace_config_test.go` around lines 606 - 691, Refactor the
two test functions
TestApplyWorkspaceDefaultsMergesRecoveryAndPreservesExplicitRecoveryIDE and
TestApplyWorkspaceDefaultsNoRecoveryForcesDisabled to use subtests following the
repository's testing conventions. Wrap each test case in a t.Run() call with a
descriptive name following the "Should..." pattern. Either combine them into a
single parent test function with multiple subtests for different recovery
scenarios, or add t.Run() calls within each existing test function to break down
the test cases into logical subtests. Ensure all assertions and setup logic
remain intact while conforming to the table-driven test pattern with subtests.

Source: Coding guidelines

internal/core/run/executor/execution_acp_integration_test.go (1)

121-161: ⚡ Quick win

Wrap this new test case in a t.Run("Should ...") subtest.

The new test is added as a standalone top-level case; please move its assertions under a t.Run("Should ...") block to stay consistent with the repo test standard.

As per coding guidelines: **/*_test.go requires “MUST use t.Run("Should...") pattern for ALL test cases” and “Use table-driven tests with subtests (t.Run) as the default pattern.”

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/executor/execution_acp_integration_test.go` around lines
121 - 161, The test function
TestExecuteJobWithTimeoutACPSlowInitializeCompletesBeforeInitDeadline is defined
as a standalone top-level test instead of using the required t.Run("Should...")
subtest pattern. Convert this test by moving all of its logic (from the tmpDir
initialization through the final assertion checking for slow initialize output)
into a t.Run call with a descriptive "Should..." name, maintaining the same test
logic while conforming to the repository's testing standards for subtest
organization.

Source: Coding guidelines

internal/core/subprocess/transport_test.go (1)

117-146: ⚡ Quick win

Use t.Run("Should ...") wrappers for the newly added test cases.

Please restructure these new top-level tests into t.Run("Should ...") subtests (table-driven where it helps) to match the repository testing convention.

As per coding guidelines: **/*_test.go requires “MUST use t.Run("Should...") pattern for ALL test cases” and “Use table-driven tests with subtests (t.Run) as the default pattern.”

Also applies to: 296-347, 432-447

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/subprocess/transport_test.go` around lines 117 - 146, The test
functions TestTransportCloseClosesEndpointsOnce and
TestTransportCloseIgnoresNonClosableEndpoints are defined as standalone
top-level test functions instead of using the repository's required
t.Run("Should ...") subtest pattern. Refactor these tests by creating a parent
test function (e.g., TestTransportClose) and converting each test case into a
subtest using t.Run with a descriptive name starting with "Should" (e.g.,
t.Run("Should close endpoints only once", ...)). Move the test logic from each
standalone function into its corresponding t.Run callback function, preserving
all the assertions and setup code.

Source: Coding guidelines

internal/core/run/recovery/agentic_test.go (1)

23-174: ⚡ Quick win

Use the required t.Run("Should...") style for all test cases.

Several test cases are still expressed as plain top-level flows (and subtest names like "fixed"/"reject"), instead of the mandated Should... subtest pattern. Please wrap each scenario in t.Run("Should ...") and rename case labels accordingly for consistency with the suite conventions.

As per coding guidelines, **/*_test.go requires: MUST use t.Run("Should...") pattern for ALL test cases and Use table-driven tests with subtests (t.Run) as the default pattern.

Also applies to: 176-233, 235-319

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/recovery/agentic_test.go` around lines 23 - 174, The test
functions TestAgenticRemediationBuildsNonRecursiveRecoveryRunConfig and
TestAgenticRemediationSystemPromptContainsGuidanceAndFailureContext are written
as top-level test functions instead of using the required t.Run("Should...")
pattern. Refactor these tests to follow the suite conventions by replacing each
top-level test function with a parent test that uses t.Run() with descriptive
subtest names starting with "Should", such as "Should build non-recursive
recovery run config" and "Should contain guidance and failure context in system
prompt". Move the existing test logic into these t.Run() subtests while
maintaining the current assertions and test flow.

Source: Coding guidelines

internal/core/run/recovery/prompt.go (1)

111-138: 💤 Low value

Consider using io.SeekStart constant for clarity.

The magic number 0 in file.Seek(offset, 0) works but using the named constant improves readability:

-	if _, err := file.Seek(offset, 0); err != nil {
+	if _, err := file.Seek(offset, io.SeekStart); err != nil {
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/recovery/prompt.go` around lines 111 - 138, The readLogTail
function uses a magic number 0 in the file.Seek call instead of the named
constant. Replace the hardcoded 0 with io.SeekStart in the file.Seek(offset, 0)
method call to improve code clarity and readability. This makes it immediately
obvious that you are seeking from the beginning of the file.
internal/core/run/recovery/orchestrator.go (2)

214-279: 💤 Low value

Unconventional triple return signature may confuse callers.

restartAfterFixedVerdict returns (RunOutcome, error, error) which is unusual in Go. Consider using a struct or named errors to clarify the distinction between "run error" and "orchestration error":

type restartResult struct {
    outcome      RunOutcome
    runErr       error  // error from the restarted run
    orchestrateErr error // error from orchestration (event emit, transition)
}

Alternatively, document the return semantics clearly if the current signature is preferred.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/recovery/orchestrator.go` around lines 214 - 279, The
restartAfterFixedVerdict function has a confusing triple return signature with
two error values that lack semantic clarity. Either refactor the function to
return a struct (such as restartResult with named fields like outcome, runErr,
and orchestrateErr) to clearly distinguish between the run error and
orchestration error, or add comprehensive documentation comments to the function
that explicitly explain what each return value represents and when it will be
non-nil. This will make the function's contract clearer to callers.

94-116: ⚡ Quick win

Defensive ctx == nil fallback creates context.Background() in library code.

Per coding guidelines, context.Background() should be avoided outside main and focused tests. If callers must provide a valid context, consider returning an error instead of silently substituting:

 func (o *RunRecoveryOrchestrator) Run(ctx context.Context, run PreparedRun) (RunOutcome, error) {
-	if ctx == nil {
-		ctx = context.Background()
-	}
+	if ctx == nil {
+		return RunOutcome{}, errors.New("run recovery: nil context")
+	}

However, if this is intentional for resilience in edge cases, document the rationale.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/recovery/orchestrator.go` around lines 94 - 116, In the Run
method of RunRecoveryOrchestrator, the defensive check that creates
context.Background() when ctx is nil violates library code guidelines. Either
remove the ctx == nil check and return an error if the caller fails to provide a
valid context, or if this defensive behavior is intentional for resilience
reasons, add a comment explaining the rationale for allowing a nil context
fallback in this library function.

Source: Coding guidelines

internal/core/run/internal/worktree/snapshot.go (1)

105-175: 💤 Low value

Minor inefficiency: head is trimmed twice.

bytes.TrimSpace(head) is called at line 138 to populate snapshot.head, but the same raw head slice is trimmed again at line 162 when computing the digest. Consider reusing the already-trimmed value:

 	h.Write([]byte{0})
-	h.Write(bytes.TrimSpace(head))
+	h.Write([]byte(snapshot.head))
 	h.Write([]byte{0})

This also ensures the digest is computed from the exact same bytes stored in the snapshot.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/internal/worktree/snapshot.go` around lines 105 - 175, The
Capture function trims the head bytes twice unnecessarily: once at the
assignment to snapshot.head and again when computing the digest hash. Store the
result of bytes.TrimSpace(head) in a variable once, use that trimmed value to
assign to snapshot.head (converting to string), and then reuse the same trimmed
bytes when calling h.Write for the digest computation instead of calling
bytes.TrimSpace(head) again.
internal/core/run/recovery/audit.go (1)

168-201: 💤 Low value

Avoid double call to snapshot.Porcelain() which copies the slice twice.

snapshot.Porcelain() returns a defensive copy each time it's called. Lines 190 and 192 both call it, creating two copies:

-	doc := auditSnapshotDocument{
+	porcelain := snapshot.Porcelain()
+	doc := auditSnapshotDocument{
 		SchemaVersion:          recoveryDiffAuditSchemaVersion,
 		Supported:              snapshot.IsSupported(),
 		GitAvailable:           snapshot.GitAvailable(),
 		IsGitRepo:              snapshot.IsGitRepo(),
 		HasCommits:             snapshot.HasCommits(),
 		Head:                   snapshot.Head(),
 		Branch:                 snapshot.Branch(),
 		Digest:                 snapshot.Digest(),
 		UnsupportedReason:      string(snapshot.UnsupportedReason()),
-		rawPorcelainForParsing: snapshot.Porcelain(),
+		rawPorcelainForParsing: porcelain,
 	}
-	if porcelain := snapshot.Porcelain(); len(porcelain) > 0 {
+	if len(porcelain) > 0 {
 		doc.RawPorcelainZBase64 = base64.StdEncoding.EncodeToString(porcelain)
 	}
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/recovery/audit.go` around lines 168 - 201, The function
captureAuditSnapshot calls snapshot.Porcelain() twice, creating two defensive
copies unnecessarily - once when assigning to rawPorcelainForParsing in the
auditSnapshotDocument struct initialization and again in the if condition check.
Refactor this by calling snapshot.Porcelain() once and storing the result in a
single variable, then use that variable for both the rawPorcelainForParsing
field assignment and the length check in the if statement.
internal/core/kernel/recovery_prepared_run.go (1)

11-15: ⚡ Quick win

Add compile-time assertions for recovery.PreparedRun implementers.

Adding interface assertions here prevents silent drift between these structs and the recovery seam during refactors.

Suggested refactor
 type kernelWorkflowPreparedRun struct {
 	ops        operations
 	runtimeCfg *model.RuntimeConfig
 	scope      model.RunScope
 }
+
+var _ recovery.PreparedRun = (*kernelWorkflowPreparedRun)(nil)
@@
 type kernelExecPreparedRun struct {
 	ops        operations
 	runtimeCfg *model.RuntimeConfig
 	scope      model.RunScope
 }
+
+var _ recovery.PreparedRun = (*kernelExecPreparedRun)(nil)

As per coding guidelines, "Use compile-time interface verification: var _ Interface = (*Type)(nil)."

Also applies to: 73-77

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/kernel/recovery_prepared_run.go` around lines 11 - 15, Add
compile-time interface assertions to verify that the kernelWorkflowPreparedRun
struct (defined at lines 11-15) and the other struct mentioned at lines 73-77
properly implement the recovery.PreparedRun interface. Use the compile-time
assertion pattern by adding a package-level variable declaration `var _
recovery.PreparedRun = (*kernelWorkflowPreparedRun)(nil)` after the struct
definition for kernelWorkflowPreparedRun, and similarly for the struct around
lines 73-77. This prevents silent drift during refactors by catching at
compile-time if either struct stops implementing the required interface.

Source: Coding guidelines

internal/core/run/recovery/reader_integration_test.go (1)

13-67: ⚡ Quick win

Wrap this scenario in t.Run("Should...") to satisfy test conventions.

This is a single-case test and can be wrapped directly in one Should... subtest for consistency with repo rules.

As per coding guidelines, "**/*_test.go: MUST use t.Run(\"Should...\") pattern for ALL test cases".

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/recovery/reader_integration_test.go` around lines 13 - 67,
The test function TestReadRunOutcomeFromExecutorPersistedResult does not follow
the repository's test convention of using t.Run("Should...") pattern. Wrap all
the existing test logic (from t.Parallel() through the final assertion) inside a
t.Run call with a descriptive name that starts with "Should" to describe what
the test validates, ensuring the t.Parallel() call remains at the top level
before the t.Run invocation.

Source: Coding guidelines

internal/core/run/recovery/reader_test.go (1)

57-75: ⚡ Quick win

Rename nested subtests to the Should... format.

The inner subtests currently use "run status" / "job status"; switch to Should... names to keep the suite compliant and consistent.

As per coding guidelines, "**/*_test.go: MUST use t.Run(\"Should...\") pattern for ALL test cases".

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/recovery/reader_test.go` around lines 57 - 75, The nested
subtests in the test file use generic names like "run status" and "job status"
instead of following the required "Should..." naming convention specified in the
coding guidelines. Update both test case name fields in the tests slice to use
descriptive "Should..." names (for example, changing "run status" to something
like "ShouldUpdateRunStatus" and "job status" to something like
"ShouldUpdateJobStatus") to ensure compliance with the test naming standards for
all test cases in *_test.go files.

Source: Coding guidelines

internal/core/run/recovery/orchestrator_test.go (1)

19-494: 🏗️ Heavy lift

Align new test cases with the required t.Run("Should...") pattern.

This file introduces many standalone top-level scenarios; please group them under t.Run("Should...") cases to match the repo’s enforced test structure.

As per coding guidelines, "**/*_test.go: MUST use t.Run(\"Should...\") pattern for ALL test cases".

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/run/recovery/orchestrator_test.go` around lines 19 - 494, The
test file contains multiple standalone top-level test functions like
TestRecoveryFSMModelsRequiredTransitions,
TestRunRecoveryOrchestratorFixedVerdictRestartsFailedJobsAndRecovers, and others
that do not follow the required t.Run("Should...") pattern. Refactor each of
these standalone test functions by consolidating them into parent test functions
and using t.Run("Should...") subtests for each scenario. For example, move the
test logic from TestRunRecoveryOrchestratorBoundsAttempts into a parent test
function and wrap the existing t.Run blocks with descriptive "Should..." names,
and similarly convert other standalone functions into t.Run subtests within
appropriate parent test functions that describe the behavior being tested.

Source: Coding guidelines

internal/core/kernel/recovery_prepared_run_test.go (1)

27-456: 🏗️ Heavy lift

Convert standalone tests to t.Run("Should...") scenarios for policy compliance.

This file adds many independent top-level tests; please wrap/organize them under Should... subtests to match the enforced test contract.

As per coding guidelines, "**/*_test.go: MUST use t.Run(\"Should...\") pattern for ALL test cases".

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/core/kernel/recovery_prepared_run_test.go` around lines 27 - 456,
The test functions in this file do not follow the required coding guideline of
using t.Run("Should...") pattern for test cases. Convert each standalone test
function (TestKernelWorkflowPreparedRunRestartFailedFiltersBySafeName,
TestRunStartRecoveryDisabledUsesOriginalPreparedPath,
TestRunStartRecoveryRecoversAndRestartsOnlyFailedJobs,
TestRunStartRecoveryIntegrationUsesDeterministicACPAndRealRestart,
TestRunStartRecoverySkipsCanceledAndRecoveryAttemptRuns,
TestRunStartRecoveryRejectFailsLoudlyAndRecordsOneAttempt, and
TestRunExecRecoveryRerunsSingleJob) to wrap their test logic inside t.Run()
calls with descriptive names using the "Should..." pattern (e.g., "Should filter
by safe name", "Should use original prepared path when recovery disabled"). For
tests that already use t.Run like
TestRunStartRecoverySkipsCanceledAndRecoveryAttemptRuns, update the subtest
names to follow the "Should..." convention instead of plain names like
"canceled" and "recovery attempt".

Source: Coding guidelines


ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: c1aca4be-ad1f-47c3-abd2-026d85f74656

📥 Commits

Reviewing files that changed from the base of the PR and between c3461f2 and 769e2ce.

⛔ Files ignored due to path filters (6)
  • docs/events.md is excluded by !**/*.md
  • go.sum is excluded by !**/*.sum
  • internal/core/run/recovery/guidance/no-workarounds.md is excluded by !**/*.md
  • internal/core/run/recovery/guidance/systematic-debugging.md is excluded by !**/*.md
  • skeeper.lock is excluded by !**/*.lock
  • skills/git-rebase/SKILL.md is excluded by !**/*.md
📒 Files selected for processing (114)
  • go.mod
  • internal/cli/daemon_commands.go
  • internal/cli/daemon_commands_test.go
  • internal/cli/reviews_exec_daemon.go
  • internal/cli/root_command_execution_test.go
  • internal/cli/state.go
  • internal/cli/tasks_run_parallel_e2e_test.go
  • internal/cli/tasks_run_wizard.go
  • internal/cli/tasks_run_wizard_test.go
  • internal/cli/testdata/exec_help.golden
  • internal/cli/testdata/tasks_run_help.golden
  • internal/cli/workspace_config.go
  • internal/cli/workspace_config_test.go
  • internal/core/agent/client.go
  • internal/core/api.go
  • internal/core/extension/host_api.go
  • internal/core/extension/host_helpers.go
  • internal/core/extension/runtime.go
  • internal/core/kernel/commands/run_start.go
  • internal/core/kernel/commands/runtime_config.go
  • internal/core/kernel/deps.go
  • internal/core/kernel/deps_test.go
  • internal/core/kernel/handlers.go
  • internal/core/kernel/recovery_prepared_run.go
  • internal/core/kernel/recovery_prepared_run_test.go
  • internal/core/model/artifacts.go
  • internal/core/model/model_test.go
  • internal/core/model/run_scope.go
  • internal/core/model/runtime_config.go
  • internal/core/model/task_review.go
  • internal/core/model/task_runtime.go
  • internal/core/plan/input.go
  • internal/core/plan/prepare.go
  • internal/core/plan/prepare_test.go
  • internal/core/run/exec/aliases.go
  • internal/core/run/exec/exec.go
  • internal/core/run/exec/exec_test.go
  • internal/core/run/exec/prompt_exec.go
  • internal/core/run/executor/execution_acp_integration_test.go
  • internal/core/run/executor/execution_acp_test.go
  • internal/core/run/executor/result.go
  • internal/core/run/executor/result_test.go
  • internal/core/run/internal/acpshared/command_io.go
  • internal/core/run/internal/acpshared/command_io_test.go
  • internal/core/run/internal/acpshared/session_exec.go
  • internal/core/run/internal/acpshared/session_exec_test.go
  • internal/core/run/internal/worktree/snapshot.go
  • internal/core/run/parallel/events.go
  • internal/core/run/parallel/fsm.go
  • internal/core/run/parallel/orchestrator.go
  • internal/core/run/parallel/orchestrator_test.go
  • internal/core/run/parallel/resolver.go
  • internal/core/run/parallel/resolver_test.go
  • internal/core/run/parallel/waves.go
  • internal/core/run/parallel/waves_test.go
  • internal/core/run/recovery/agentic.go
  • internal/core/run/recovery/agentic_test.go
  • internal/core/run/recovery/audit.go
  • internal/core/run/recovery/audit_test.go
  • internal/core/run/recovery/exec_outcome.go
  • internal/core/run/recovery/exec_outcome_test.go
  • internal/core/run/recovery/fsm.go
  • internal/core/run/recovery/job_filter.go
  • internal/core/run/recovery/job_filter_test.go
  • internal/core/run/recovery/orchestrator.go
  • internal/core/run/recovery/orchestrator_test.go
  • internal/core/run/recovery/outcome.go
  • internal/core/run/recovery/prepared_run.go
  • internal/core/run/recovery/prompt.go
  • internal/core/run/recovery/reader.go
  • internal/core/run/recovery/reader_integration_test.go
  • internal/core/run/recovery/reader_test.go
  • internal/core/run/recovery/run_scope_journal.go
  • internal/core/run/recovery/run_scope_journal_test.go
  • internal/core/run/recovery/strategy.go
  • internal/core/run/recovery/verdict.go
  • internal/core/run/ui/integration.go
  • internal/core/run/ui/integration_test.go
  • internal/core/run/ui/model.go
  • internal/core/run/ui/multi_remote.go
  • internal/core/run/ui/multi_remote_test.go
  • internal/core/run/ui/timeline.go
  • internal/core/run/ui/types.go
  • internal/core/run/ui/update.go
  • internal/core/subprocess/handshake.go
  • internal/core/subprocess/transport.go
  • internal/core/subprocess/transport_test.go
  • internal/core/tasks/parser.go
  • internal/core/tasks/parser_test.go
  • internal/core/tasks/walker.go
  • internal/core/workspace/config_merge.go
  • internal/core/workspace/config_test.go
  • internal/core/workspace/config_types.go
  • internal/core/workspace/config_validate.go
  • internal/daemon/recovery_run.go
  • internal/daemon/review_watch.go
  • internal/daemon/review_watch_test.go
  • internal/daemon/run_manager.go
  • internal/daemon/run_manager_test.go
  • internal/daemon/task_multi.go
  • internal/daemon/task_multi_test.go
  • internal/daemon/task_multi_worktree.go
  • internal/daemon/task_multi_worktree_test.go
  • internal/setup/bundle_test.go
  • pkg/compozy/events/docs_test.go
  • pkg/compozy/events/event.go
  • pkg/compozy/events/event_test.go
  • pkg/compozy/events/kinds/docs_test.go
  • pkg/compozy/events/kinds/payload_compat_test.go
  • pkg/compozy/events/kinds/run.go
  • pkg/compozy/events/kinds/task.go
  • pkg/compozy/runs/layout/layout.go
  • sdk/extension-sdk-ts/src/types.ts
  • sdk/extension/types.go

Comment thread internal/cli/daemon_commands_test.go
Comment thread internal/cli/root_command_execution_test.go
Comment thread internal/core/kernel/recovery_prepared_run_test.go
Comment thread internal/core/kernel/recovery_prepared_run.go
Comment thread internal/core/run/parallel/orchestrator_test.go Outdated
Comment thread internal/core/workspace/config_test.go
Comment thread internal/daemon/recovery_run.go Outdated
Comment thread internal/daemon/run_manager.go
Comment thread internal/daemon/task_multi.go
Comment thread internal/daemon/task_multi.go Outdated
coderabbitai[bot]
coderabbitai Bot previously approved these changes Jun 19, 2026

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@internal/daemon/run_manager_test.go`:
- Around line 1748-1750: The test function
TestDaemonWorkflowPreparedRunRestartFailedTreatsEmptyFailedJobIDsAsRestartAll
does not follow the required t.Run("Should...") subtest pattern. Wrap the test
body (everything after t.Parallel()) inside a t.Run call with a descriptive
"Should..." message that explains what the test verifies. This ensures
compliance with the repo's test standard that requires all test cases to use the
t.Run pattern.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: aaf6a78d-6d31-423d-a226-13bc72178ee7

📥 Commits

Reviewing files that changed from the base of the PR and between 769e2ce and 2807b63.

⛔ Files ignored due to path filters (1)
  • skeeper.lock is excluded by !**/*.lock
📒 Files selected for processing (37)
  • internal/cli/daemon_commands_test.go
  • internal/cli/reviews_exec_daemon.go
  • internal/cli/root_command_execution_test.go
  • internal/cli/workspace_config_test.go
  • internal/core/api.go
  • internal/core/kernel/recovery_prepared_run.go
  • internal/core/kernel/recovery_prepared_run_test.go
  • internal/core/model/model_test.go
  • internal/core/run/exec/exec_test.go
  • internal/core/run/executor/execution_acp_integration_test.go
  • internal/core/run/executor/execution_acp_test.go
  • internal/core/run/internal/worktree/snapshot.go
  • internal/core/run/parallel/orchestrator.go
  • internal/core/run/parallel/orchestrator_test.go
  • internal/core/run/parallel/resolver.go
  • internal/core/run/parallel/resolver_test.go
  • internal/core/run/recovery/agentic_test.go
  • internal/core/run/recovery/audit.go
  • internal/core/run/recovery/job_filter.go
  • internal/core/run/recovery/job_filter_test.go
  • internal/core/run/recovery/orchestrator.go
  • internal/core/run/recovery/orchestrator_test.go
  • internal/core/run/recovery/prompt.go
  • internal/core/run/recovery/reader.go
  • internal/core/run/recovery/reader_integration_test.go
  • internal/core/run/recovery/reader_test.go
  • internal/core/run/recovery/run_scope_journal.go
  • internal/core/run/recovery/run_scope_journal_test.go
  • internal/core/run/ui/multi_remote_test.go
  • internal/core/subprocess/transport_test.go
  • internal/core/tasks/parser_test.go
  • internal/core/workspace/config_test.go
  • internal/core/workspace/config_types.go
  • internal/daemon/recovery_run.go
  • internal/daemon/run_manager_test.go
  • internal/daemon/task_multi.go
  • internal/daemon/task_multi_test.go
🚧 Files skipped from review as they are similar to previous changes (30)
  • internal/core/run/recovery/job_filter_test.go
  • internal/core/run/recovery/reader.go
  • internal/core/run/ui/multi_remote_test.go
  • internal/core/run/recovery/reader_integration_test.go
  • internal/core/run/exec/exec_test.go
  • internal/core/api.go
  • internal/core/run/recovery/reader_test.go
  • internal/cli/workspace_config_test.go
  • internal/core/run/executor/execution_acp_integration_test.go
  • internal/cli/reviews_exec_daemon.go
  • internal/core/tasks/parser_test.go
  • internal/core/run/recovery/audit.go
  • internal/cli/daemon_commands_test.go
  • internal/cli/root_command_execution_test.go
  • internal/core/run/recovery/job_filter.go
  • internal/core/workspace/config_types.go
  • internal/core/kernel/recovery_prepared_run.go
  • internal/daemon/recovery_run.go
  • internal/core/run/recovery/run_scope_journal.go
  • internal/core/run/recovery/agentic_test.go
  • internal/core/run/parallel/resolver.go
  • internal/core/run/recovery/prompt.go
  • internal/core/run/recovery/orchestrator_test.go
  • internal/core/run/recovery/orchestrator.go
  • internal/core/run/internal/worktree/snapshot.go
  • internal/core/model/model_test.go
  • internal/core/subprocess/transport_test.go
  • internal/core/run/parallel/orchestrator.go
  • internal/core/workspace/config_test.go
  • internal/daemon/task_multi.go

Comment thread internal/daemon/run_manager_test.go
coderabbitai[bot]
coderabbitai Bot previously approved these changes Jun 19, 2026
@pedronauck
pedronauck merged commit e43aa56 into main Jun 19, 2026
7 of 8 checks passed
@pedronauck
pedronauck deleted the agentic branch June 19, 2026 13:10
@coderabbitai coderabbitai Bot mentioned this pull request Jun 27, 2026
pedronauck added a commit that referenced this pull request Jul 3, 2026
Add human-written release notes for the next release covering the work
merged since v0.2.10:

- feat: dependency-aware parallel task execution (--parallel-tasks) (#212)
- feat: agentic recovery for failed runs (--recovery) (#212)
- feat: COMPOZY_HOME for isolated per-project daemons (#216)
- feat: repo-level default overrides in compozy setup (#90)
- fix: safer worktree management for parallel runs (#217, #223)
- fix: ACP runs consistently apply the selected model (#215)
- fix: run TUI elapsed timer restored across all terminal outcomes (#221)

Co-Authored-By: Claude Fable 5 <[email protected]>
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