- Extract FakeEmbeddings, RelevanceScoringStrategy, AdaptiveContextSelector,
ContextFusionStrategy, and _pack_budget from features/steps/ into new
features/mocks/advanced_context_strategies_mocks.py per mock-placement rules
- Remove sys.path manipulation from robot/helper_advanced_context_strategies.py;
import directly from features.mocks instead of features/steps
- Add None guard before selected.assemble() in step_assemble_context_query
- Add explicit ValueError for unknown strategy types in step_load_yaml_strategy
and load_strategy_from_yaml_impl
ISSUES CLOSED: #7574
- Add Behave feature file with 30+ scenarios for semantic search, relevance scoring, adaptive selection, and context fusion strategies
- Implement step definitions for all advanced context strategy tests
- Add FakeEmbeddings mock for deterministic testing without real API calls
- Create Robot Framework integration tests for E2E validation
- Implement helper functions for Robot Framework test execution
- All tests use proper type annotations and follow CONTRIBUTING.md guidelines
- Tests verify strategy selection, budget handling, deduplication, and YAML configuration
- Integration tests validate ContextAssembler compatibility and strategy priority handling
- Replace non-existent 'session create --name' with 'session create --format json'
- Replace non-existent 'plan create --session --description' with 'plan list --format json'
- Replace 'session delete <name>' with 'session delete <ULID> --yes' using extracted session ID
- Remove invalid '--format json' from context list/show commands that don't support it
- Use Safe Parse Json Field keyword to extract session_id from JSON output
- Align all test commands with actual CLI interface
- Add test_a2a_local_facade.robot with session and plan lifecycle tests
- Add test_context_workflow.robot with context configuration and execution tests
- Tests validate output format matches specification
- Tests run against real CLI without mocking
- Covers A2A session initialization, plan creation, listing, and deletion
- Covers context loading, validation, and plan execution workflows
- Replace hardcoded gpt-4/openai/gpt-4 references with Resolve LLM Actor
keyword so the test falls back to Anthropic when OpenAI is unavailable
- Add explicit return-code check (rc==0) for actor registration in Step 2
- Update CHANGELOG.md with entry for PR #11191
The M2 acceptance test was incomplete (truncated at line 48).
Restore the full test case that exercises the complete M2 milestone:
- Actor YAML compilation and registration
- Resource registration and project creation
- Action creation with custom actor configuration
- Full plan lifecycle: use, strategize, execute, diff, apply
- Verification of plan status and integrity
Exercises real LLM API integration using OpenAI GPT-4 model.
ISSUES CLOSED: #10812
- Remove unused `import ast` and fix `set_function_registry` to store
callable values directly instead of calling eval() on a function object
- Replace try/except/pass with contextlib.suppress (SIM105)
- Add strict=False to zip() call (B905)
- Wrap long line in execute_graph (E501)
- Use list unpacking in assert_topo_order_equals (RUF005)
- Fix keyword name: Remove hyphen from 'Non-Functional' (Python method
has no hyphen so Robot generates 'Non Functional')
- Rewrite Set Double And Increment Registry to evaluate lambdas directly
rather than iterating a list of tuples (which paired whole tuples as
loop variables instead of unpacking them)
- Pass node/function name lists via Robot list variables instead of
space-delimited positional args
ISSUES CLOSED: #9531
- Remove features/pure_graph_coverage.feature to resolve duplicate BDD scenarios
conflict with existing consolidated_langgraph.feature (lines 440-474) that was
introduced by prior consolidation commit 60887308. Duplicate scenario execution
causes unit_tests CI failure.
- Replace Robot Framework stub tests in robot/langraph/pure_graph.robot with real
PureGraph integration tests:
* Topological order verifies start/end boundaries and node sequence
* Function execution validates sequential transformation (double=1->2, increment=2->3)
* Missing function test confirms graceful skip behavior without exceptions
* Non-functional nodes verify pass-through semantics
- Create pure_graph_lib.py Robot Framework library module with proper keywords
for graph construction, topo order computation, and execution under test.
ISSUES CLOSED: #9531
Add comprehensive test coverage for PureGraph module:
- Created features/pure_graph_coverage.feature with BDD scenarios for topological ordering, function execution, missing function handling, and non-functional nodes
- Added robot/langgraph/pure_graph.robot with Robot Framework integration tests
- Created benchmarks/pure_graph_bench.py with ASV benchmarks for execution throughput and ordering performance
This addresses the test infrastructure gap identified in issue #9531 where PureGraph had orphaned step definitions but no feature file, and lacked integration and performance test coverage.
ISSUES CLOSED: #9531
Extends the budget utilization summary in `context show` to display
hot/warm/cold tier utilization percentages individually, satisfying
the spec requirement for a per-tier breakdown. Previously only hot
tier utilization was shown.
- Hot tier: tokens used vs. max_tokens_hot budget
- Warm tier: fragment count vs. max_decisions_warm budget
- Cold tier: fragment count vs. max_decisions_cold budget
Also updates Robot Framework helper to verify per-tier breakdown
is present in output, and updates CHANGELOG/CONTRIBUTORS.
ISSUES CLOSED: #9586
- Fix integration test failure: Context Show Validates Empty View Name
- typer.Exit is click.Exit (RuntimeError subclass), not SystemExit
- Robot helper now catches typer.Exit using exit_code attribute
- Helper path insertion now always places clone src at sys.path[0]
to prevent /app/src from shadowing the PR branch source
- Fix information disclosure: CleverAgentsError handler now logs
exception internally via _logger.exception() and shows generic
user-facing message instead of str(e)
- Fix budget utilization: use actual per-tier token counts instead
of hot_count * 100 (fragment count * arbitrary factor)
- Fix type safety: _remove_fragments now uses _TierServiceProtocol
instead of object, enabling proper static type checking
- Fix overly broad except: cancellation handled with early return
instead of catching typer.Exit(0) in the except block
- Add broad glob pattern warning when --path matches > 50 entries
- Remove duplicate HAL 9000 entry from CONTRIBUTORS.md
- Fix Behave steps to catch typer.Exit in addition to SystemExit
ISSUES CLOSED: #9586
The ACMS context CLI commands ('context show' / 'context clear') were fully
implemented in 'acms_context.py' with comprehensive tests, mocks, benchmarks,
and documentation — but the module was never imported or registered in
'cli/main.py'. This commit wires up the 'acms_context.app' Typer sub-app
so that 'agents acms context show' and 'agents acms context clear' are
actually accessible from the CLI.
Changes:
- Import acms_context in _register_subcommands()
- Register acms_context.app as the 'acms' sub-app on the main Typer app
- Add 'acms' to valid_cmds list in main() for fast-path validation
- Add 'acms context' entry to _print_basic_help() output
- Minor formatting cleanup applied by ruff
ISSUES CLOSED: #9586
Refs: #9675
- Rewrote production CLI to use real ContextTierService (get_scoped_view, get_all_fragments, evict_lru) instead of non-existent ACMSService
- Removed unused imports (Path, Panel, ScopedView) from production code
- Fixed all lint issues: trailing whitespace, import ordering, nested with statements
- Replaced typer.Abort() with typer.Exit(code=1) for error exits
- Added input validation for empty/whitespace view parameter
- Fixed error handling to use str(e) instead of e.message
- Added guards against negative budget values in _format_budget_utilization
- Added warning when clearing context with no filters (clear ALL)
- Removed module-level console side effect
- Moved mocks to features/mocks/acms_context_mocks.py per CONTRIBUTING.md
- Fixed test assertions to capture real CLI output (not placeholder)
- Fixed duplicate step definitions (AmbiguousStep errors)
- Fixed feature file step mismatch for tier count parameter
- Added Robot Framework integration tests in robot/acms_context_cli.robot
- Added performance benchmarks in benchmarks/acms_context_cli_bench.py
- Updated CHANGELOG.md with ACMS context CLI feature entry
- Updated CONTRIBUTORS.md with ACMS context CLI contribution
ISSUES CLOSED: #9586
The tdd_expected_fail listener (robot/tdd_expected_fail_listener.py and
features/environment.py) inverts test results: a test tagged
@tdd_expected_fail that PASSES is forced to FAIL with the message
"Bug appears to be fixed. Remove the tdd_expected_fail tag…".
After rebasing onto master, 22 scenarios across 11 files were triggering
that forced-failure path because the underlying bugs (#4199, #4201,
#4202, #4203, #4205, #4206, #4243, #4252, #4301, #4303, #4304) have
been fixed on master but the @tdd_expected_fail tags were never removed.
This commit removes the stale tag (keeping @tdd_issue and
@tdd_issue_<N> for traceability, per the master-side pattern in
robot/tdd_skill_add_regression.robot:9 "tag removed after bug fix").
Files touched (lines: where the stale tag was):
features/plan_cli_spec_alignment.feature (121, 128, 136)
robot/a2a_facade.robot (40)
robot/actor_cli_show.robot (13, 30)
robot/actor_configuration.robot (8)
robot/actor_context_export_import.robot (20, 71, 92)
robot/cli_extensions.robot (61)
robot/cli_formats.robot (14, 23, 30, 48, 57, 85)
robot/cli_lifecycle_e2e.robot (77, 87)
robot/config_project_scope.robot (37)
robot/config_resolution.robot (13)
robot/container_tool_exec.robot (137)
Verified locally: targeted unit_tests run on
features/plan_cli_spec_alignment.feature now passes 20/20 (was 17/20
with 3 scenarios forced-failed by the inversion).
ISSUES CLOSED: #3677
- What was implemented
- Added PLAN_ROLLED_BACK event type to the EventType enum at src/cleveragents/infrastructure/events/types.py to properly represent successful rollbacks in the domain model.
- Implemented rollback_plan(plan_id: str, checkpoint_id: str) -> RollbackResult in PlanLifecycleService (src/cleveragents/application/services/plan_lifecycle_service.py) with:
- Plan state validation: rejects rollback when the plan is in terminal APPLIED or CANCELLED states.
- Delegation to CheckpointService.selective_rollback() to perform the actual rollback logic and obtain a RollbackResult.
- Emission of PLAN_ROLLED_BACK as a domain event to reflect the completed rollback.
- checkpoint_service is accepted as an optional constructor parameter; if not provided, a PlanError is raised to preserve backward compatibility.
- Updated CLI behavior in src/cleveragents/cli/commands/plan.py so agents plan rollback routes through PlanLifecycleService.rollback_plan() rather than calling CheckpointService.selective_rollback() directly.
- Updated PlanLifecycleService module docstring to include rollback_plan in the documented API.
- Added Behave feature file features/plan_lifecycle_rollback.feature with 11 scenarios covering state validation, domain events, and delegation.
- Added step implementations in features/steps/plan_lifecycle_rollback_steps.py to support the new scenarios.
- Key design decisions
- rollback_plan returns RollbackResult (the same result type produced by CheckpointService.selective_rollback) so the CLI can display rollback details consistently.
- Terminal states APPLIED and CANCELLED are disallowed for rollback to prevent inconsistent or invalid state transitions.
- checkpoint_service is optional in the PlanLifecycleService constructor; when omitted (None), a PlanError is raised to retain backward compatibility while signaling explicit dependency requirements.
- CLI UI remains powered by CheckpointService for metadata enrichment (e.g., confirmation prompts), but the actual rollback action is performed via PlanLifecycleService to ensure proper domain workflow and event emission.
- Technical implications
- All rollback logic now flows through the domain service layer (PlanLifecycleService) to preserve invariants and emit domain events, rather than allowing ad-hoc UI routes to bypass service validation.
- The UI can still retrieve checkpoint metadata for user confirmation, but the operation that modifies state uses the new rollback_plan pathway.
- Tests and behavior coverage were expanded via the new Behave feature and step implementations to validate state handling, events, and delegation.
- Affected modules/components
- src/cleveragents/infrastructure/events/types.py
- src/cleveragents/application/services/plan_lifecycle_service.py
- src/cleveragents/cli/commands/plan.py
- PlanLifecycleService module docstring
- features/plan_lifecycle_rollback.feature
- features/steps/plan_lifecycle_rollback_steps.py
ISSUES CLOSED: #3677
Addresses remaining CI review feedback from HAL9001 on PR #8304:
1. Moved all cleveragents imports from inside function bodies to module-level
in features/steps/container_clone_into_steps.py (5 functions fixed)
2. Moved BUILTIN_TYPES import from inside step_look_up_in_builtin_types()
to module level in features/steps/devcontainer_sandbox_strategy_steps.py
3. Removed redundant inline import of EMPTY_CONTENT_HASH and BaseResourceHandler
inside diff() method of devcontainer.py (already available at module level)
4. Fixed stale docstring referencing old 'detected' terminology in
robot/helper_devcontainer_lifecycle.py cmd_transition_valid()
All files pass ruff format and ruff check.
- Remove committed build artifacts (test_reports/summary.txt,
test_reports/test_results.json) and add test_reports/ to .gitignore
- Fix CLI resource.py: update lifecycle state condition and warning
banner from 'detected (not built)' to 'discovered (not built)' and
'Devcontainer detected' to 'Devcontainer discovered' to align with
ContainerLifecycleState.DISCOVERED rename
- Fix BDD feature file: update resource_list_lifecycle_state.feature
scenario title and assertion from 'Devcontainer detected' to
'Devcontainer discovered'
- Fix robot/helper_devcontainer_lifecycle.py: update enum value check
from 'detected' to 'discovered' in cmd_enum_values()
- Fix robot/helper_devcontainer_handler.py: update strategy check
assertion from 'none' to 'snapshot' to match PR #8304 change
- Update CONTRIBUTORS.md with HAL 9000 feature contribution entry
Closes#7555 (via PR #8304)
Fixes: CI unit_tests and integration_tests failures from PR #8304
Apply ruff format to features/steps/auto_debug_prompt_injection_steps.py
and robot/helper_auto_debug_agent_prompt_injection.py to resolve CI lint
failures (missing blank lines between top-level definitions).
- Add _sanitize_user_input() helper that catches PromptInjectionDetected and falls back to wrap_user_content() instead of crashing the agent
- Remove dead code (_bs, _be variables) from all three agent methods
- Use wrap_user_content() for error_analysis (internal LLM output) in _generate_fix() to avoid crashing on the agent's own output
- Add @security @prompt-injection BDD tags to feature file and all scenarios
- Add missing @then("the boundary markers should be present") step definition
- Add Robot Framework integration tests (auto_debug_agent_prompt_injection.robot)
- Update CHANGELOG.md and CONTRIBUTORS.md
ISSUES CLOSED: #9110
Four CI failures fixed:
1. JSON/YAML progress scenarios (features/output_rendering.feature:588 and :1584):
The conflict resolver had preserved master's test assertions expecting
ProgressIndicator elements in JSON/YAML data arrays, but the PR's
_snapshot_to_dict correctly omits them per spec §26936 ("progress is
omitted from JSON output"). Removed the assertions that contradict the
spec-compliant implementation.
2. ColumnDef all-fields scenario (:1885):
Test checked for "col_type" in raw JSON output, but _column_def_to_dict
serialises the field under the key "type" (via Pydantic alias). Changed
assertion to "width_hint" which IS a serialised key in the ColumnDef dict.
3. Rich-with-cursor scenario (:2154):
Step constructed TerminalCapabilities(supports_cursor=True, term=...) using
the old field names — now backward-compat properties, not Pydantic fields.
Pydantic silently ignores unknown kwargs, leaving supports_cursor_movement=False
and causing select_materializer("rich") to return TableMaterializer. Updated
to supports_cursor_movement=True and term_program="xterm-256color".
4. Robot json-all / yaml-all helpers:
Same conflict-resolution issue as #1: helper expected all 10 element types
including "progress" in JSON/YAML data arrays. Removed "progress" from both
expected lists to match the spec-compliant implementation.
Implement the three missing architectural components of the Output Rendering
Framework as specified in issue #917:
1. RendererRegistry (spec §27249-27350): Central registry for format
(MaterializationStrategy, ElementRenderer) pairs with register(),
resolve(), available_formats(), is_registered() methods and a
FormatRegistration model. Built-in formats pre-registered in
default_registry. Replaces hardcoded if/elif chains for format
resolution.
2. ElementRenderer Protocol (spec §26557-26654): Per-element render
methods (render_panel, render_table, render_tree, etc.) plus
serialize() and can_render(). Six concrete implementations:
PlainElementRenderer, ColorElementRenderer, TableElementRenderer,
RichElementRenderer, JsonElementRenderer, YamlElementRenderer.
Each format now has a paired (Strategy, Renderer).
3. TerminalCapabilities (spec §27264-27301): Extended from 4 fields to
all 11 spec-defined fields: width, height, supports_256_color,
supports_truecolor, supports_unicode, supports_alternate_screen,
no_color, plus renames supports_cursor → supports_cursor_movement,
term → term_program. Backward-compatible properties preserved.
Additional fixes:
- ColumnDef serialises column type as 'type' (not 'col_type') per spec
§26199, with alias for backward compatibility
- YAML output uses sort_keys=True per spec §27168
- Progress elements omitted from JSON/YAML per spec §26936
- MaterializationStrategy.bind(renderer, terminal_caps) method added
to protocol and all strategy implementations (SD-19 resolved)
- Updated SD documentation in __init__.py
ISSUES CLOSED: #917
- Extract AWS-specific logic into cloud_aws.py and cloud_providers.py to keep all files under the 500-line limit (cloud.py: 490 lines, cloud_aws.py: 498 lines, cloud_providers.py: 181 lines)
- Fix sandbox test regression: change cloud_resources.feature sandbox create scenario from "aws" to "gcp" provider (AWS no longer raises NotImplementedError)
- Add ImportError handling to step_sandbox_create/commit/rollback in cloud_resources_steps.py
- Remove all 9 type: ignore comments from production code using proper type narrowing and boto3/botocore type stubs in typings/
- Move plan_id validation before logger.info() in all three sandbox methods (fail-fast principle)
- Fix exception suppression: discover_aws_resources() now propagates exceptions instead of catching bare Exception
- Move deferred imports (PhysVirt, ResourceCapabilities, _derive_child_id) to module level in cloud_aws.py
- Split cloud_aws_sdk_steps.py (755 lines) into focused modules: cloud_aws_helpers.py, cloud_aws_session_steps.py, cloud_aws_discover_steps.py, cloud_aws_sandbox_steps.py
- Add CHANGELOG.md entry for AWS SDK integration feature
- Update robot/helper_cloud_resources.py to handle ImportError/ NotImplementedError for AWS sandbox operations
ISSUES CLOSED: #1021
Update integration test helpers to use definition_of_done values that
satisfy the new TextMatchEvaluator gate (criterion text must appear as
a substring of a plan argument key or value). Also fix _evaluate_dod
to merge DoD metadata into plan.validation_summary without overwriting
Execute-phase validation counts, preserving the coverage/tool-validation
gate used by apply_with_validation_gate. Update CONTRIBUTORS.md.
Fixes: wf02, wf04, wf06, wf07 integration test suites.
ISSUES CLOSED: #7927
integration_tests (Robot/pabot) failed on robot/coverage_threshold.robot
"Noxfile Contains Coverage Threshold Constant": it asserted the literal
`COVERAGE_THRESHOLD = 96.5` in noxfile.py, but the coverage_report session now
delegates the constant to pyproject's single source
(`COVERAGE_THRESHOLD = _read_coverage_fail_under()`).
This was the last WS5 reconciliation gap (the plan enumerated behave feature
steps + ci.yml + guidelines prose, but not the Robot suite). Assert the
delegation plus the pyproject floor (`fail_under = 96.5`) instead of the literal,
mirroring the behave step fix in b499834c0. The other assertions in the suite
(--fail-under= substring, [tool.coverage.run], branch=true, source=["src"]) are
unaffected; verified no other robot/behave/pytest test depends on the literal.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The Robot Framework `Catenate` keyword treats 2+ consecutive spaces as
field separators and strips them, which breaks Python's mandatory
indentation when a nested `assert` follows a `for` line. As a result
the "TUI Help Command Groups By Namespace" test produced a script with
a de-indented `assert` body, causing an IndentationError under
`python -c` and the test to fail with rc=1.
Rewrite the namespace-presence check as a single-line list
comprehension over the expected group headers, mirroring the pattern
already used by the sibling "Lists All Catalogued Commands" test in
the same file. The check is semantically equivalent — both fail with
the same diagnostic message when a group header is missing — but the
flattened form survives Robot's argument tokenisation intact.
ISSUES CLOSED: #3434
Replace the hardcoded help string in TuiCommandRouter.handle() with a
dynamic lookup against SLASH_COMMAND_SPECS from slash_catalog.py.
Changes:
- Add _help_command(), _help_list_all(), _help_for_command() methods to
TuiCommandRouter
- /help (no args): iterates SLASH_COMMAND_SPECS, groups commands by
namespace (sorted alphabetically), renders all 70 commands with
descriptions in colon-namespaced format (e.g. persona:list)
- /help <command>: looks up the given command in SLASH_COMMAND_SPECS and
renders its full help (group, description)
- /help <unknown>: returns 'Unknown command: /<cmd>' message
- /help /persona:list (with leading slash): strips the slash and resolves
correctly
- Import defaultdict and SLASH_COMMAND_SPECS at module level
Tests:
- Update tui_commands_coverage.feature: replace old exact-match scenario
for help text with new dynamic-listing assertions
- Add tui_commands_coverage_steps.py: new 'should contain' step definition
- Add tui_help_command_full_catalog.feature: 12 BDD scenarios covering
/help no-args, /help <command>, /help <unknown>, namespace grouping,
colon-namespaced format, and regression against old hardcoded string
- Add tui_help_command_full_catalog_steps.py: step definitions for the
new feature (all-commands check, not-equal assertion)
- Add robot/tui_help_command.robot: 5 Robot Framework integration tests
verifying the help command via direct Python invocation and headless
TUI startup
Closes#3434
---
**Automated by CleverAgents Bot**
Supervisor: Implementation | Agent: ca-issue-worker
Add ContextTierService mock to step_m5_invoke_project_context_show
so the CLI command can call _get_context_tier_service() without
failing. Also patch _load_policy_json to prevent JSON decode errors
from MagicMock session objects. Update CHANGELOG.md and CONTRIBUTORS.md.
ISSUES CLOSED: #6323
The Behave test expected the error message to contain '--url is only valid
for git resources' but the code was producing '--url only for git resources'.
Updated the validation error message to match the test assertion.
Also updated the Robot Framework integration test to expect the corrected
message, ensuring consistency across both test suites.
Fixes the failing Behave scenario: 'Using --url with a non-git resource type
is rejected' by correcting the error message text output from the CLI.
ISSUES CLOSED: #6322
The TDD regression files for bug #968 were incorrectly deleted instead of
updated to assert the spec-compliant fixed behaviour from issue #6325.
Per CONTRIBUTING.md the regression guard must be kept and updated — not
removed — once the bug is fixed.
Restore and update all three files to assert the new expected behaviour:
- plan explain rejects a non-decision-id argument with rc=1
- error output contains "not found"
- decision data fields are absent from output
Also pair the orphaned robot/helper_tdd_plan_explain_plan_id.py with a
restored robot test file and update it to verify rc=1 rejection behaviour.
ISSUES CLOSED: #6325
The executable resource type was not defined in the specification
(docs/specification.md lines 10567-10575). The supported resource types
are: git-checkout, git, fs-mount, fs-directory, fs-file,
container-instance, and devcontainer-instance.
Additionally, the agents resource list output included a Location column
that is not part of the spec-defined columns (Name, ID, Type, Phys/Virt,
Children, Projects per line 11051).
Changes:
- Remove executable type registration from _resource_registry_lsp.py
- Remove executable from BUILTIN_TYPE_NAMES in _resource_type_validation.py
- Update resource list table columns to match spec (Name, ID, Type,
Phys/Virt, Children, Projects) removing Location and Description
- Remove all executable-related test scenarios from
features/resource_type_lsp.feature
- Update robot/helper_resource_type_lsp.py to reflect 3 LSP types
(not 4) and add assertions that executable is absent
ISSUES CLOSED: #3077
The automation-profile remove command was only printing a plain checkmark
message after deletion. The spec requires a Rich Panel titled 'Profile Removed'
containing the profile name, followed by the success message.
Changes:
- Replace plain console.print checkmark with Panel render + success message
- Panel displays 'Name: <profile-name>' under 'Profile Removed' title
- Success message updated to '✓ OK Profile removed' per spec
- Behave feature: add panel assertions to existing remove scenario
- Behave feature: add new 'Remove custom profile shows Profile Removed panel' scenario
- Robot Framework helper: update test_remove_profile() to assert panel presence
ISSUES CLOSED: #2966
The format_output() function in src/cleveragents/cli/formatting.py had two
routing bugs that caused incorrect output for the 'rich' and 'color' formats:
1. The 'rich' format had no explicit dispatch branch and silently fell through
to the final JSON fallback, returning raw JSON instead of styled terminal
output. Since 'rich' is the default CLI format (per ADR-021), this meant
all commands using format_output() (version, info, diagnostics) produced
JSON by default.
2. The 'color' format was incorrectly routed to _format_plain() instead of a
color-aware renderer, producing plain text with no ANSI color codes.
Fix:
- Added _format_rich() helper that delegates to RichMaterializer via
OutputSession, producing ANSI-styled terminal output consistent with
format_output_session().
- Added _format_color() helper that delegates to ColorMaterializer via
OutputSession, producing ANSI-colored terminal output.
- Added explicit OutputFormat.RICH dispatch in format_output() routing.
- Fixed OutputFormat.COLOR dispatch to use _format_color() instead of
_format_plain().
Tests:
- Updated existing BDD scenario that was validating the buggy behavior
(expected JSON for rich format) to now assert correct styled output.
- Added new BDD scenarios: 'rich format produces styled terminal output not
JSON' and 'color format produces ANSI-colored output not plain text'.
- Added Robot Framework integration tests in cli_formats.robot and
helper_cli_formats.py verifying end-to-end styled output for both formats.
All nox sessions pass: lint, typecheck, unit_tests, security_scan.
ISSUES CLOSED: #2921
- Updated SkeletonCompressorService.compress() to accept
(fragments: tuple[ContextFragment, ...], skeleton_budget: int)
-> tuple[ContextFragment, ...], matching the SkeletonCompressor protocol
- Removed skeleton_ratio and CompressionResult from the public API
- Added @runtime_checkable to SkeletonCompressor protocol in acms_service.py
- Added structural subtype assertion at module level to prevent future
protocol drift
- Rewrote all Behave feature scenarios and step definitions to use
skeleton_budget
- Updated benchmarks and robot helpers to use absolute token budgets
- Removed CompressionResult export from services __init__.py and
vulture_whitelist.py
- The depth_breadth_projection.py call site already correctly computed
and passed skeleton_budget
ISSUES CLOSED: #2925
Fix pre-existing lint, typecheck, and security failures that were
blocking the PR from passing CI:
- Fix E501 line-too-long in session_service.py (remove erroneous
"sha256:" string prefix from dict comprehension on line 268)
- Fix W293 trailing whitespace in tool.py line 249
- Fix typecheck error in session_service.py: data.get("checksum")
can return None, remove invalid string concatenation
- Fix typecheck error in schema.py: add explicit dict[str, Any]
type annotation for wrapper variable to resolve str|None issue
- Fix vulture false positive: add "destination" Protocol parameter
to vulture_whitelist.py
- Fix @tdd_issue/@tdd_issue_1472 tag placement in skill_schema.feature
(remove blank line between tags and scenario)
- Add @tdd_issue/@tdd_issue_1472 tags to all new wrapper key scenarios
- Add Robot integration test for spec-compliant skill: wrapper YAML
Add Behave feature file and Robot Framework integration tests covering
the two compiler functions fixed in issue #1429:
- _map_node(): SUBGRAPH node's NodeConfig.subgraph is now populated from
node.actor_ref instead of config.get("actor_ref") which always returned None
- compile_actor(): metadata.subgraph_refs is now populated from
node_def.actor_ref instead of node_def.config.get("actor_ref", "") which
always returned an empty string
Three Behave scenarios tagged @tdd_issue @tdd_issue_1429 covering:
1. NodeConfig.subgraph field populated from actor_ref (_map_node fix)
2. metadata.subgraph_refs populated from actor_ref (compile_actor fix)
3. Both fields correct together with a realistic actor ref
Two Robot Framework integration tests in tdd_actor_compiler_actor_ref_1429.robot
with a self-contained Python helper that exercises both code paths in isolation.
ISSUES CLOSED: #1429
Add the missing workflow validation example and keep the #1039 TDD regression active by removing the expected-fail tag and updating scenario narrative.\n\nTo satisfy the required full quality gates, stabilize flaky integration behavior encountered during this issue run: use a shared SQLAlchemy session in resource DAG scripts, isolate RxPY validation temp paths per test run, extend transient subprocess timeouts/retry behavior, and clear stale pabot worker artifacts before integration runs so repeated nox executions are reliable.\n\nISSUES CLOSED: #1039
AuditService.record() was generating its own timestamp internally,
discarding the original DomainEvent.timestamp. This means audit entries
recorded when an event was audited, not when the domain event actually
occurred, breaking forensic accuracy per §Audit Logging (SEC7).
Changes:
- Add `timestamp: datetime | None = None` keyword parameter to
AuditService.record(). When provided, uses it as created_at;
falls back to datetime.now(tz=UTC) for backward compatibility.
Applied to both the async queue path and the synchronous DB path.
- AuditEventSubscriber._handle_event() now passes timestamp=event.timestamp
so the original event creation time is preserved in audit entries.
- Add 3 Behave BDD scenarios covering: full pipeline timestamp
preservation, direct record() with explicit timestamp, and backward
compatibility (record() without timestamp auto-generates created_at).
- Add preserve_event_timestamp Robot integration test and helper subcommand.
- Add static source check in security_audit.robot verifying the
timestamp parameter signature exists.
ISSUES CLOSED: #719
Three BDD scenarios and two Robot Framework integration tests verifying that
_get_service() in automation_profile.py resolves AutomationProfileService
through the DI container rather than manually calling create_engine or
sessionmaker (bug #990).
Bug #990 was fixed by PR #1181 before this TDD test PR merged; the
@tdd_expected_fail tag is therefore absent and these tests serve as
permanent regression guards confirming the fix remains in place.
ISSUES CLOSED: #1031