Skip to content

fix(run): reject empty tasks - #384

Merged
solomonneas merged 1 commit into
mainfrom
agent/issue-378
Jul 20, 2026
Merged

fix(run): reject empty tasks#384
solomonneas merged 1 commit into
mainfrom
agent/issue-378

Conversation

@solomonneas

Copy link
Copy Markdown
Collaborator

Closes #378.

What changed

  • Reject empty and whitespace-only brigade run task arguments during argparse validation.
  • Return the original string unchanged for valid tasks, including detached forwarding.
  • Add regression coverage that proves blank input reaches none of roster resolution, run-directory allocation, locking, or aboyeur.run().

Root cause

Argparse required the positional task to be present but accepted an explicitly supplied blank string. dispatch() then performed setup and created artifacts before any task-content check.

Verification

  • brigade work verify run --target . --command "./scripts/verify" --capture brigade-work
  • Brigade receipt: 20260720-014725-work-verify-b083f5
  • Result: 3,171 passed, 3 skipped, 82.19% coverage
  • Independent review: no findings; conflict-free rebase followed by a full gate

Risk

The CLI now exits with argparse status 2 for input that never represented a runnable task. Valid task parsing and detached command forwarding are unchanged.

@coderabbitai

coderabbitai Bot commented Jul 20, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are limited based on label configuration.

🏷️ Required labels (at least one) (1)
  • coderabbit-review

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository: escoffier-labs/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 11d105f1-6ca0-4258-ab66-85fc95485398

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch agent/issue-378

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

@solomonneas solomonneas self-assigned this Jul 20, 2026
@solomonneas
solomonneas merged commit 44b9ed3 into main Jul 20, 2026
20 checks passed
@solomonneas
solomonneas deleted the agent/issue-378 branch July 26, 2026 20:37
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.

fix(run): reject empty tasks before artifact creation

1 participant