UAT: --required/--informational flags regression in agents validation add — removed by commit 1d36449a #1415

Open
opened 2026-04-02 17:45:17 +00:00 by freemo · 0 comments
Owner

Bug Report

Feature Area: Validation Pipeline (v3.4.0)

What Was Tested

The agents validation add CLI command for the --required and --informational flags that allow overriding the mode from the YAML config file.

Expected Behavior (from spec)

Per docs/specification.md line 22355:

The mode is set at registration time (in the validation YAML or via --required/--informational on agents validation add)

The spec also shows numerous workflow examples using --required:

agents validation add --config validations/run-tests.yaml --required local/run-tests

These flags were previously implemented in commit a5cc8135 (fix: add --required/--informational flags to validation add CLI) which closed issue #1038.

Actual Behavior

The --required and --informational flags are not present in the current agents validation add command:

$ agents validation add --config ./validations/run-tests.yaml --required
Error: No such option: --required

Root Cause

Commit 1d36449a (fix(cli): remove extra --mode flag from validation attach) accidentally reverted src/cleveragents/cli/commands/validation.py to the pre-fix version (index d931b97b) instead of the post-fix version (index ee6a060a). This dropped the --required/--informational flags that were added in a5cc8135.

The diff between a5cc8135 and 1d36449a for validation.py shows:

  • Removed required: Annotated[bool, typer.Option("--required", ...)] parameter
  • Removed informational: Annotated[bool, typer.Option("--informational", ...)] parameter
  • Removed mutual exclusivity check
  • Removed mode override logic
  • Reverted docstring back to "Config-Only Add"

Steps to Reproduce

from typer.testing import CliRunner
from cleveragents.cli.commands.validation import app
runner = CliRunner()
result = runner.invoke(app, ['add', '--config', 'any.yaml', '--required'])
# Exit code: 2, Output contains "No such option: --required"

Code Location

src/cleveragents/cli/commands/validation.py — the add() function is missing the --required and --informational parameters.

Severity

High — This is a regression of a previously fixed bug (#1038). The spec explicitly requires these flags and they are used in multiple workflow examples throughout the specification.


Metadata

  • Branch: bugfix/m5-validation-required-flag-regression
  • Commit Message: fix(cli): restore --required/--informational flags to validation add (regression from 1d36449a)
  • Milestone: v3.5.0
  • Parent Epic: #357

Subtasks

  • Identify exact diff between a5cc8135 and 1d36449a for validation.py to confirm regression scope
  • Restore --required and --informational mutually exclusive boolean options to the add() function in src/cleveragents/cli/commands/validation.py
  • Restore mode override logic (flags override YAML config mode field)
  • Restore mutual exclusivity check (reject both flags passed simultaneously)
  • Tests (Behave): Verify existing @tdd_issue_1038 scenarios pass without @tdd_expected_fail
  • Tests (Robot): Verify existing tdd_validation_required_flag.robot tests pass
  • Verify coverage >= 97% via nox -s coverage_report
  • Run nox (all default sessions), fix any errors

Definition of Done

  • All subtasks are completed and checked off
  • --required and --informational flags are accepted by agents validation add
  • Flags override the YAML config's mode value
  • Mutual exclusivity is enforced (both flags together is rejected)
  • All existing @tdd_issue_1038 tests pass without @tdd_expected_fail
  • A PR is opened from the branch to master, reviewed, and merged
  • All nox stages pass
  • Coverage >= 97%
## Bug Report **Feature Area:** Validation Pipeline (v3.4.0) ### What Was Tested The `agents validation add` CLI command for the `--required` and `--informational` flags that allow overriding the mode from the YAML config file. ### Expected Behavior (from spec) Per `docs/specification.md` line 22355: > The mode is set at registration time (in the validation YAML or via `--required`/`--informational` on `agents validation add`) The spec also shows numerous workflow examples using `--required`: ``` agents validation add --config validations/run-tests.yaml --required local/run-tests ``` These flags were previously implemented in commit `a5cc8135` (fix: add --required/--informational flags to validation add CLI) which closed issue #1038. ### Actual Behavior The `--required` and `--informational` flags are **not present** in the current `agents validation add` command: ``` $ agents validation add --config ./validations/run-tests.yaml --required Error: No such option: --required ``` ### Root Cause Commit `1d36449a` (fix(cli): remove extra --mode flag from validation attach) accidentally reverted `src/cleveragents/cli/commands/validation.py` to the pre-fix version (index `d931b97b`) instead of the post-fix version (index `ee6a060a`). This dropped the `--required`/`--informational` flags that were added in `a5cc8135`. The diff between `a5cc8135` and `1d36449a` for `validation.py` shows: - Removed `required: Annotated[bool, typer.Option("--required", ...)]` parameter - Removed `informational: Annotated[bool, typer.Option("--informational", ...)]` parameter - Removed mutual exclusivity check - Removed mode override logic - Reverted docstring back to "Config-Only Add" ### Steps to Reproduce ```python from typer.testing import CliRunner from cleveragents.cli.commands.validation import app runner = CliRunner() result = runner.invoke(app, ['add', '--config', 'any.yaml', '--required']) # Exit code: 2, Output contains "No such option: --required" ``` ### Code Location `src/cleveragents/cli/commands/validation.py` — the `add()` function is missing the `--required` and `--informational` parameters. ### Severity High — This is a regression of a previously fixed bug (#1038). The spec explicitly requires these flags and they are used in multiple workflow examples throughout the specification. --- ## Metadata - **Branch**: `bugfix/m5-validation-required-flag-regression` - **Commit Message**: `fix(cli): restore --required/--informational flags to validation add (regression from 1d36449a)` - **Milestone**: v3.5.0 - **Parent Epic**: #357 ## Subtasks - [ ] Identify exact diff between `a5cc8135` and `1d36449a` for `validation.py` to confirm regression scope - [ ] Restore `--required` and `--informational` mutually exclusive boolean options to the `add()` function in `src/cleveragents/cli/commands/validation.py` - [ ] Restore mode override logic (flags override YAML config `mode` field) - [ ] Restore mutual exclusivity check (reject both flags passed simultaneously) - [ ] Tests (Behave): Verify existing `@tdd_issue_1038` scenarios pass without `@tdd_expected_fail` - [ ] Tests (Robot): Verify existing `tdd_validation_required_flag.robot` tests pass - [ ] Verify coverage >= 97% via `nox -s coverage_report` - [ ] Run `nox` (all default sessions), fix any errors ## Definition of Done - [ ] All subtasks are completed and checked off - [ ] `--required` and `--informational` flags are accepted by `agents validation add` - [ ] Flags override the YAML config's `mode` value - [ ] Mutual exclusivity is enforced (both flags together is rejected) - [ ] All existing `@tdd_issue_1038` tests pass without `@tdd_expected_fail` - [ ] A PR is opened from the branch to `master`, reviewed, and merged - All nox stages pass - Coverage >= 97%
freemo added this to the v3.5.0 milestone 2026-04-02 17:48:02 +00:00
freemo self-assigned this 2026-04-02 18:45:13 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
cleveragents/cleveragents-core#1415
No description provided.