747513bc591edeab1d4971141c605bd6dd024b0e
35 Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
747513bc59 |
chore(testing): enforce semgrep gate for suppressed exceptions
Fix broken escape hatch mechanism and address reviewer feedback: - Replace non-functional comment-based pattern-not clauses with Semgrep's native # nosemgrep mechanism for the escape hatch. Semgrep strips comments from the AST so pattern-not clauses matching inline comments never fire; # nosemgrep is the only reliable per-line suppression mechanism. - Require both # nosemgrep: <rule-id> AND # error-propagation: allow on the same line: the former is the actual suppression, the latter is the mandatory human-readable audit annotation. - Add raise $EXC from $CAUSE pattern-not entries for both Exception and BaseException variants to prevent false positives on legitimate exception chaining (raise ServiceError from e). - Switch nox -s lint Semgrep invocation to audit mode (no --error) for the phased rollout: the codebase has ~337 existing suppressions that must be triaged before enforcement mode is enabled. A comment in noxfile.py documents the migration path and references #9103. - Update CONTRIBUTING.md examples and enforcement description to reflect the dual-comment requirement. |
||
|
|
153acf0861 |
chore(testing): enforce semgrep gate for suppressed exceptions
Added two new Semgrep rules to enforce the CONTRIBUTING.md guideline against broad exception suppression: - python-no-suppressed-exception: Detects except Exception/BaseException blocks without re-raising - python-no-suppress-exception: Detects contextlib.suppress(Exception/BaseException) usage Both rules support an escape hatch annotation '# error-propagation: allow' for documented recovery logic. Integrated Semgrep into the nox lint session to run alongside Ruff checks. Updated CONTRIBUTING.md to document the escape hatch policy and automated enforcement. Pre-commit hook already configured to run these rules. ISSUES CLOSED: #9103 |
||
|
|
6a4a49158c |
fix(cli): address review feedback on docstring example validator
- Fix error suppression in validate_all_commands: log at DEBUG level instead of silently swallowing exceptions - Fix multi-word command name parsing bug: use command_token_count to skip the full command prefix when extracting positional values - Add @cli tag to features/cli_docstring_example_validation.feature - Update CONTRIBUTING.md with CLI docstring example style guide - Update CHANGELOG.md with entry for automated docstring validation - Update CONTRIBUTORS.md with contribution entry - Fix test design flaws: separate Given/When/Then steps per scenario - Add validate_all_commands test coverage via new Behave scenario - Fix _extract_positional_args to only count required positional args |
||
|
|
d25a060c58 |
Revert "feat(ci): implement TDD bug tag quality gate for bug fix PRs"
CI / lint (pull_request) Successful in 50s
CI / quality (pull_request) Successful in 1m2s
CI / push-validation (pull_request) Successful in 39s
CI / helm (pull_request) Successful in 43s
CI / typecheck (pull_request) Successful in 1m31s
CI / security (pull_request) Successful in 1m32s
CI / build (pull_request) Successful in 1m3s
CI / integration_tests (pull_request) Successful in 3m42s
CI / unit_tests (pull_request) Successful in 6m13s
CI / docker (pull_request) Successful in 2m2s
CI / coverage (pull_request) Successful in 11m15s
CI / status-check (pull_request) Successful in 3s
CI / build (push) Successful in 53s
CI / lint (push) Successful in 1m1s
CI / helm (push) Successful in 26s
CI / quality (push) Successful in 1m16s
CI / typecheck (push) Successful in 1m20s
CI / security (push) Successful in 1m37s
CI / benchmark-regression (push) Failing after 40s
CI / push-validation (push) Successful in 21s
CI / integration_tests (push) Successful in 3m17s
CI / unit_tests (push) Successful in 4m28s
CI / e2e_tests (push) Successful in 3m22s
CI / docker (push) Successful in 1m52s
CI / coverage (push) Successful in 12m50s
CI / status-check (push) Successful in 3s
CI / benchmark-publish (push) Successful in 1h20m0s
This reverts commit
|
||
|
|
e8d2f76466
|
feat(ci): implement TDD bug tag quality gate for bug fix PRs
CI / push-validation (pull_request) Successful in 45s
CI / helm (pull_request) Successful in 57s
CI / build (pull_request) Successful in 1m8s
CI / lint (pull_request) Successful in 1m31s
CI / tdd_quality_gate (pull_request) Failing after 1m26s
CI / quality (pull_request) Successful in 1m30s
CI / typecheck (pull_request) Successful in 1m43s
CI / security (pull_request) Successful in 1m42s
CI / e2e_tests (pull_request) Failing after 4m10s
CI / integration_tests (pull_request) Successful in 5m2s
CI / unit_tests (pull_request) Successful in 6m6s
CI / docker (pull_request) Successful in 1m32s
CI / coverage (pull_request) Successful in 12m12s
CI / status-check (push) Blocked by required conditions
CI / status-check (pull_request) Failing after 3s
CI / tdd_quality_gate (push) Has been skipped
CI / benchmark-regression (push) Failing after 1m8s
CI / build (push) Successful in 1m2s
CI / lint (push) Successful in 1m16s
CI / helm (push) Successful in 45s
CI / push-validation (push) Successful in 45s
CI / quality (push) Successful in 1m37s
CI / typecheck (push) Successful in 2m1s
CI / security (push) Successful in 2m1s
CI / integration_tests (push) Successful in 3m34s
CI / unit_tests (push) Successful in 5m14s
CI / docker (push) Successful in 1m37s
CI / coverage (push) Failing after 19m17s
CI / benchmark-publish (push) Successful in 1h20m43s
CI / e2e_tests (push) Successful in 4m13s
Add an automated quality gate that enforces TDD bug fix workflow rules on pull requests. The gate parses PR descriptions for bug-closing keywords (Closes/Fixes/Resolves #N, ISSUES CLOSED: #N), searches the codebase for corresponding TDD tests tagged @tdd_bug_N, and verifies that @tdd_expected_fail tags have been removed. Key components: - scripts/tdd_quality_gate.py: Main quality gate script with PR description parsing, TDD test discovery, and tag removal verification. All public functions validate arguments fail-fast and are statically typed. - noxfile.py: New tdd_quality_gate session that reads PR_DESCRIPTION from the environment and runs the quality gate script. - .forgejo/workflows/ci.yml: New tdd_quality_gate CI job that runs only on pull_request events, passing the PR body as PR_DESCRIPTION. - features/tdd_quality_gate.feature: 46 Behave scenarios covering PR parsing, TDD test search, tag removal verification, full gate logic, robot diff handling, edge cases, argument validation, bool guards, co-located bug false-positive guard, and main() CLI entry point. - features/steps/tdd_quality_gate_steps.py: Step definitions for all Behave scenarios using temporary directories for isolation. - robot/tdd_quality_gate.robot: 15 Robot Framework integration tests exercising the gate end-to-end via a helper subprocess. - robot/helper_tdd_quality_gate.py: Helper script for Robot tests with sentinel-based sub-commands. Review-round fixes applied: - check_expected_fail_removed now uses _contains_tag_token for word-boundary matching (avoids false positives on partial tag names) - Diff expected-fail removal detection tracks flags at file level instead of per-hunk (fixes false negatives when tags span hunks) - parse_bug_refs filters out issue number zero - Redundant double error reporting eliminated (file-level check short-circuits the diff-level check) - run_quality_gate returns (errors, bug_refs) tuple to avoid redundant re-parsing in main() - Regex compilation cached via functools.lru_cache - Nox session no longer installs the full project (stdlib only) - CI checkout uses fetch-depth: 0 for reliable merge-base resolution Review-round 2 fixes applied: - _diff_has_expected_fail_removal_for_bug now requires the removed line to contain both the expected-fail tag and the specific bug tag (fixes false positives when two bugs share the same test file) - check_expected_fail_removed error messages use the correct tag prefix per file type (@tdd_bug_N for .feature, tdd_bug_N for .robot) - bool values rejected by bug-number validation guards in find_tdd_tests, check_expected_fail_removed, and _diff_has_expected_fail_removal_for_bug - File-read error handling catches UnicodeDecodeError alongside OSError (root-safe unreadable-file handling via invalid-UTF-8 test fixture) - Temp directory cleanup added to after_scenario hook in environment.py - 8 new Behave scenarios: bool type guards (2), co-located bug false-positive regression (1), run_quality_gate argument validation (3), and main() CLI entry point exit codes (2) Review-round 3 fixes applied: - Synthetic PR diff helper (_default_pr_diff_for_bug_refs) now auto-detects .robot vs .feature file type from the temp search tree and generates the matching diff format (fixes under-tested robot-format diff code path in multi-bug integration scenarios) - check_expected_fail_removed test step now filters files by bug tag via find_tdd_tests before checking (matches production path in run_quality_gate) - after_scenario temp directory cleanup no longer sets context.temp_dir = None (fixes cleanup conflict with cli_init_yes_flag_steps.py cleanup functions that run after hooks) - 2 new Behave scenarios: multi-line PR description parsing, and non-string pr_diff type guard for run_quality_gate ISSUES CLOSED: #629 |
||
|
|
cc24d8c8ac |
fix(cli): remove legacy plan commands from help output
Completely removed all legacy plan commands from the CLI:
- Removed tell, build, new, current, cd, continue CLI commands
- Removed programmatic wrapper functions (tell_command, build_command, etc.)
- Removed legacy deprecation message
- Updated help text to indicate V3 Plan Lifecycle exclusively
- Removed stale references to tell/build in help output and command validation
Removes the legacy 'tell' and 'build' CLI shortcuts from main.py:
- Removed echo lines advertising tell/build commands
- Removed tell/build from valid_cmds list
- Removed tell/build from _LIGHTWEIGHT_COMMANDS frozenset
- These dead entries were preventing helpful error messages
Test infrastructure improvements:
- Event bus exception test: Patch the module-level logger during emit() so that
structlog.testing.capture_logs() can capture the logs. Without patching, the
module-level logger created at import time is not captured by the context manager.
- Session create/list commands: Suppress cleveragents.mcp logger to CRITICAL level
during JSON/YAML output formatting to prevent health check warnings with ANSI codes
from being written to stdout before JSON output, which breaks JSON parsing.
- Extended plan_cli_coverage_boost with scenarios for estimation_result,
invariants, execution_environment, validation_summary, and checkpoint
coverage in _plan_spec_dict
Documentation:
- Created docs/Legacy_to_V3_Guide.md with comprehensive migration instructions
- Updated CONTRIBUTING.md to document removal of legacy workflow
- Updated CHANGELOG.md to reference issue #4181 instead of PR #10800
ISSUES CLOSED: #4181
|
||
|
|
f67e8a2e07
|
fix(testing): document and harden non-AssertionError guard in apply_tdd_inversion to reduce flaky CI
CI / lint (pull_request) Successful in 18s
CI / build (pull_request) Successful in 17s
CI / helm (pull_request) Successful in 18s
CI / quality (pull_request) Successful in 53s
CI / typecheck (pull_request) Successful in 56s
CI / security (pull_request) Successful in 57s
CI / push-validation (pull_request) Successful in 40s
CI / unit_tests (pull_request) Successful in 3m13s
CI / integration_tests (pull_request) Successful in 4m23s
CI / e2e_tests (pull_request) Successful in 4m37s
CI / docker (pull_request) Successful in 1m34s
CI / coverage (pull_request) Successful in 10m46s
CI / status-check (pull_request) Successful in 1s
CI / lint (push) Successful in 17s
CI / quality (push) Successful in 17s
CI / build (push) Successful in 24s
CI / helm (push) Successful in 24s
CI / push-validation (push) Successful in 37s
CI / typecheck (push) Successful in 52s
CI / security (push) Successful in 52s
CI / e2e_tests (push) Successful in 3m13s
CI / unit_tests (push) Successful in 6m37s
CI / integration_tests (push) Successful in 6m39s
CI / docker (push) Successful in 1m35s
CI / coverage (push) Successful in 11m13s
CI / status-check (push) Successful in 1s
Surface the non-AssertionError guard warning in standard Behave output by emitting to stderr in addition to the structured logger, and add infrastructure coverage that asserts this guard path is visible during test runs. Document the @tdd_expected_fail expectation that bug-signaling failures must use AssertionError so infrastructure exceptions are not accidentally treated as expected bug failures. ISSUES CLOSED: #8294 |
||
|
|
97c45ab780 |
chore(policy): reduce PR review requirement from 2 approvals to 1
CI / helm (push) Successful in 23s
CI / build (push) Successful in 24s
CI / push-validation (push) Successful in 30s
CI / lint (push) Successful in 35s
CI / quality (push) Successful in 42s
CI / typecheck (push) Successful in 53s
CI / security (push) Successful in 59s
CI / e2e_tests (push) Successful in 3m11s
CI / integration_tests (push) Successful in 4m1s
CI / unit_tests (push) Successful in 5m12s
CI / docker (push) Successful in 1m18s
CI / coverage (push) Successful in 11m2s
CI / status-check (push) Successful in 9s
CI / benchmark-publish (push) Has been cancelled
CI / benchmark-regression (push) Has been cancelled
- Update CONTRIBUTING.md to require only 1 approving review instead of 2
- Allow self-approval including for automated bot PRs (HAL9000)
- Approval can be formal review OR approval comment (LGTM, Approved, ✅)
- Remove distinction between human and bot PRs in review requirements
- Update agent definitions to reflect new policy
- Update system watchdog and documentation to match new requirements
This change unblocks PR merges while maintaining quality through CI checks
and still requiring at least one approval before merge.
|
||
|
|
300a5d6ddc |
fix(cli): disallow mixing legacy and v3 plan workflows
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 18s
CI / helm (pull_request) Successful in 23s
CI / lint (pull_request) Failing after 26s
CI / quality (pull_request) Successful in 34s
CI / security (pull_request) Failing after 46s
CI / typecheck (pull_request) Failing after 50s
CI / coverage (pull_request) Has been skipped
CI / benchmark-regression (pull_request) Has been skipped
CI / unit_tests (pull_request) Failing after 1m46s
CI / docker (pull_request) Has been skipped
CI / e2e_tests (pull_request) Failing after 14m9s
CI / integration_tests (pull_request) Failing after 20m57s
CI / status-check (pull_request) Failing after 1s
Add ULID format validation to all v3 plan commands to prevent users from
accidentally mixing legacy ('agents tell') and v3 ('agents plan use')
workflows. The two systems use separate storage backends and cannot be
mixed; this change detects the mismatch early and provides actionable
error messages.
Changes:
- Add _validate_plan_ulid() with proper Crockford Base32 regex
(^[0-9A-HJKMNP-TV-Z]{26}$, re.IGNORECASE) that correctly rejects
invalid characters (I, L, O, U), hyphens, and wrong-length strings
- Add _PLAN_ULID_RE compiled regex and _ULID_VALIDATION_ERROR_MSG constant
with actionable guidance explaining the legacy/v3 incompatibility
- Apply ULID validation to all v3 commands: execute_plan,
_lifecycle_apply_with_id, lifecycle_apply_plan, plan_status,
plan_errors, cancel_plan (only on user-provided IDs, not auto-discovered)
- Update _LEGACY_DEPRECATION_MSG and tell/build command warnings to
explicitly state that the two workflows are INCOMPATIBLE and cannot be mixed
- Add comprehensive BDD tests in features/plan_ulid_validation.feature
with step definitions using Typer CLI runner (not subprocess)
- Update CONTRIBUTING.md with 'Workflow Choice: Legacy vs. v3 Plan
Lifecycle' section documenting the incompatibility and migration path
ISSUES CLOSED: #1560
|
||
|
|
b51df2ee0f |
feat(server): add Kubernetes Helm chart for server deployment (#1085)
CI / docker (push) Blocked by required conditions
CI / status-check (push) Blocked by required conditions
CI / build (push) Successful in 20s
CI / helm (push) Successful in 23s
CI / lint (push) Successful in 3m19s
CI / typecheck (push) Successful in 3m57s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m5s
CI / integration_tests (push) Successful in 7m25s
CI / unit_tests (push) Failing after 13m18s
CI / quality (push) Failing after 13m19s
CI / e2e_tests (push) Failing after 18m16s
CI / coverage (push) Failing after 19m20s
CI / benchmark-publish (push) Failing after 28m16s
## Summary This PR adds Kubernetes Helm deployment support for the CleverAgents server. Closes #928 ### What this PR includes - Helm chart under `k8s/` with Deployment, Service, optional Ingress, ConfigMap, ServiceAccount, Secrets, NOTES, and optional Redis subchart configuration. - Multi-stage `Dockerfile.server` for server runtime deployment. - Deployment-focused docs in `k8s/README.md`. - Behave + Robot + benchmark coverage for chart/deployment wiring. ### Review fixes applied (cycle 11 — hurui200320 review #2687) **Critical fix:** 1. **CI SHA256 checksum verification fixed** — All 3 Helm install blocks (`unit_tests`, `integration_tests`, `helm` jobs) now save the tarball using its original filename (`helm-v3.16.4-linux-amd64.tar.gz`) instead of `helm.tgz`, so the `.sha256sum` file can correctly locate and verify it. This was causing all 3 CI Helm jobs to fail with "No such file or directory". **Major fixes (test coverage gaps):** 2. **405 Allow header now tested** — The existing "POST to known path returns method not allowed" scenario now asserts that the `Allow: GET` header is present. Added a second 405 scenario testing `POST /live` for broader `_KNOWN_PATHS` coverage (review item #11). 3. **Security-hardening headers now tested** — New scenario "HTTP responses include security-hardening headers" verifies `content-length`, `x-content-type-options: nosniff`, and `cache-control: no-store` headers are present on HTTP responses. 4. **Lifespan warning logging now tested** — New scenario "Unrecognised lifespan message type logs warning and continues" queues `lifespan.startup` → `lifespan.bogus` → `lifespan.shutdown` and verifies: (a) the app completes the lifespan cycle cleanly, (b) a warning is logged mentioning the unrecognised type. ### Review fixes applied (cycle 10) **Critical/Major fixes (from hurui200320's prior REQUEST_CHANGES):** 1. **Rebased branch onto master** — Removed merge commit per CONTRIBUTING.md rebase-only policy. Clean linear history restored. 2. **Fixed commit message body** — Replaced literal `\n` sequences with actual newlines. `ISSUES CLOSED: #928` footer is now on its own line after a blank separator. 3. **Moved uvicorn import to module top level** — `from uvicorn import run as uvicorn_run` is now at the top of `src/cleveragents/cli/commands/server.py` per Import Guidelines. Updated test mock target from `uvicorn.run` to `cleveragents.cli.commands.server.uvicorn_run`. 4. **Added SHA256 checksum verification** — All three Helm CLI install blocks in `.forgejo/workflows/ci.yml` now download and verify `helm.sha256sum` before extracting the binary. **Minor fixes:** 5. **Added `Dockerfile.server` build to CI** — New "Build Docker image (Server)" step in the `docker` job validates the server Dockerfile. 6. **ASGI 405 Method Not Allowed** — Known paths (`/`, `/live`, `/ready`, `/health`) now return 405 with `Allow: GET` header for non-GET methods, per RFC 9110 §15.5.6. Added `_KNOWN_PATHS` frozenset. 7. **WebSocket close protocol fix** — App now calls `await receive()` to consume the `websocket.connect` event before closing. Changed close code from 1000 (Normal Closure) to 1008 (Policy Violation). 8. **Lifespan handler logging** — Unrecognised lifespan message types are now logged as warnings instead of silently consumed. 9. **Security-hardening headers** — `_send_response` now includes `content-length`, `x-content-type-options: nosniff`, and `cache-control: no-store` on all HTTP responses. 10. **`.dockerignore` credential patterns** — Added `*.pem`, `*.key`, `*.p12`, `*.pfx`, `credentials*.json`. 11. **`--log-level` validation** — Constrained to `click.Choice(["critical", "error", "warning", "info", "debug", "trace"])` for clean CLI validation errors. 12. **Reverted unrelated semgrep pre-commit change** — `pass_filenames` and `entry` restored to original values per atomic commit hygiene. 13. **Removed unused `ReceiveCallable` type alias** and `Callable`/`Awaitable` imports from `asgi_app_steps.py`. 14. **Fixed redundant `shutil.which("helm")` check** — `_skip_if_helm_missing` now returns `bool` to eliminate the duplicate check in `_render_chart`. 15. **Improved test deque error handling** — Lifespan test receive mock now raises descriptive `AssertionError` instead of opaque `IndexError`. 16. **Scope type dispatch** — Changed `if/if/if` to `if/elif/elif` for mutually exclusive ASGI scope types. 17. **Dockerfile.server base image** — Standardised to `python:3.13-slim` (floating minor) consistent with CLI Dockerfile. 18. **Dockerfile layer caching** — Split `uv pip install build` and `python -m build` into separate `RUN` instructions. 19. **Removed extraneous double blank line** in Dockerfile.server. ### Deferred items (acknowledged, not in scope) - PodDisruptionBudget, HorizontalPodAutoscaler, NetworkPolicy — Follow-up for production hardening. - `appVersion: "1.0.0"` placeholder — Needs tracking issue for release versioning alignment. - Readiness probe with downstream dependency checks — Documented limitation. - Cross-system test for probe paths matching ASGI routes — Test enhancement. - Improved benchmarks (helm template timing vs PyYAML parsing) — Benchmark quality improvement. - CI DRY violation (Helm install 3×) — Code quality improvement, consider composite action. - File length limits exceeded (`k8s_helm_chart_steps.py` 551 lines, `helper_k8s_helm_chart.py` 678 lines) — Non-blocking, can be split in follow-up. - `runAsGroup: 1000` in pod security context — Defense-in-depth improvement. - HEAD method support on known paths — RFC compliance, does not affect K8s probes. - `click.Choice` log-level validation via CLI runner test — Test gap. ### Scope note: status-check CI gate The `status-check` job now includes `integration_tests`, `e2e_tests`, and `helm` in its `needs` list. The `helm` job is new in this PR. The `integration_tests` and `e2e_tests` additions fix previously-missing gate checks — included here since this PR modifies both of those jobs to install Helm. ### Quality gates - `nox -e lint` ✅ - `nox -e typecheck` ✅ - `nox -e unit_tests` ✅ (12,321 scenarios passed, 4 skipped) - `nox -e integration_tests` — 3 pre-existing failures in unrelated areas (plan correction, resource types) - `nox -e e2e_tests` — pre-existing failures (LLM API keys not available in local env) - `nox -e coverage_report` ✅ (**97.7%**) Reviewed-on: #1085 Reviewed-by: Jeffrey Phillips Freeman <jeffrey.freeman@cleverthis.com> Co-authored-by: Brent E. Edwards <brent.edwards@cleverthis.com> Co-committed-by: Brent E. Edwards <brent.edwards@cleverthis.com> |
||
|
|
1878998b7a |
refactor(testing): rename tdd_bug/tdd_bug_N tags to tdd_issue/tdd_issue_N
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 25s
CI / lint (pull_request) Successful in 3m19s
CI / typecheck (pull_request) Successful in 3m56s
CI / security (pull_request) Successful in 4m6s
CI / quality (pull_request) Successful in 4m10s
CI / integration_tests (pull_request) Successful in 7m20s
CI / unit_tests (pull_request) Successful in 7m44s
CI / docker (pull_request) Successful in 1m8s
CI / e2e_tests (pull_request) Successful in 13m1s
CI / coverage (pull_request) Successful in 12m25s
CI / status-check (pull_request) Successful in 1s
CI / build (push) Successful in 26s
CI / lint (push) Successful in 3m31s
CI / quality (push) Successful in 3m40s
CI / typecheck (push) Successful in 3m57s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 4m1s
CI / integration_tests (push) Successful in 8m55s
CI / unit_tests (push) Successful in 9m14s
CI / docker (push) Successful in 9s
CI / e2e_tests (push) Successful in 11m42s
CI / coverage (push) Successful in 11m37s
CI / status-check (push) Successful in 4s
CI / benchmark-publish (push) Successful in 29m25s
CI / benchmark-regression (pull_request) Successful in 54m8s
Rename the TDD tag system from tdd_bug/tdd_bug_<N> to tdd_issue/tdd_issue_<N> across the entire codebase. The tdd_expected_fail tag is unchanged. The TDD expected-failure workflow is not limited to bug fixes — it applies equally to any issue type (features, tasks, refactors). The _bug suffix was misleading and narrowed the perceived scope. The new _issue suffix accurately reflects that the TDD tagging system applies to any Forgejo issue. Changes span 92 files: - features/environment.py: validate_tdd_tags(), should_invert_result(), and apply_tdd_inversion() updated — regex, variables, error messages - robot/tdd_expected_fail_listener.py: _validate_tdd_tags(), _should_invert_result(), start_test(), end_test() updated consistently - 33 Behave .feature files: all @tdd_bug/@tdd_bug_<N> tags renamed - 29 Robot .robot files: all tdd_bug/tdd_bug_<N> tags renamed - 3 Robot fixture files renamed (tdd_bug_alone, tdd_missing_tdd_bug, tdd_expected_fail_missing_bug_n) with content and references updated - Tag validation tests and helpers updated (function names, command dispatch keys, output strings, fixture references) - CONTRIBUTING.md: section renamed from 'TDD Bug Test Tags' to 'TDD Issue Test Tags', all tag references and examples updated - noxfile.py: comment references updated - Step definition files, mock helpers, and benchmark files: docstring references updated ISSUES CLOSED: #965 |
||
|
|
00897be24a |
feat(ci): CI/CD pipeline definitions (#983)
CI / build (push) Successful in 21s
CI / lint (push) Successful in 3m30s
CI / typecheck (push) Successful in 3m55s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 3m57s
CI / quality (push) Successful in 3m59s
CI / integration_tests (push) Successful in 5m52s
CI / e2e_tests (push) Successful in 8m15s
CI / coverage (push) Failing after 13m33s
CI / unit_tests (push) Failing after 17m29s
CI / benchmark-publish (push) Successful in 19m11s
CI / docker (push) Has been skipped
CI / status-check (push) Failing after 3s
## Summary Complete CI/CD pipeline definitions: release workflow, caching, status-check consolidation, and documentation. ### Changes **New: Release pipeline** (`.forgejo/workflows/release.yml`): - Triggered on `v*` tags - 3 jobs: `build-wheel` → `build-docker` → `create-release` - Builds wheel via `nox -s build`, Docker image via multi-stage Dockerfile - Creates Forgejo release via API with wheel artifact attached - Configurable registry push via `REGISTRY_*` secrets **Updated: CI pipeline** (`.forgejo/workflows/ci.yml`): - Added `actions/cache@v3` for `~/.cache/uv` on all 8 primary jobs (keyed on `pyproject.toml` hash) - Added `status-check` consolidation job depending on all required checks — single gate for branch protection **Updated: CONTRIBUTING.md**: - New CI/CD section: pipeline overview, job table, required merge checks, release process, secrets documentation **Tests**: - 13 new Behave scenarios validating workflow YAML structure, tag triggers, job definitions, dependencies - 9 new Robot tests validating file existence, content, nox session references ### Quality Gates | Session | Result | |---|---| | `nox -s lint` | PASS | | `nox -s typecheck` | PASS (0 errors) | | `nox -s unit_tests` | PASS (10,819 scenarios) | | `nox -s coverage_report` | 97.9% (>= 97%) | Closes #858 Reviewed-on: #983 Co-authored-by: Brent E. Edwards <brent.edwards@cleverthis.com> Co-committed-by: Brent E. Edwards <brent.edwards@cleverthis.com> |
||
|
|
21a8e672a3
|
Docs: Contributing now enforces 97% coverage
CI / lint (push) Successful in 28s
CI / quality (push) Successful in 28s
CI / typecheck (push) Successful in 39s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 48s
CI / e2e_tests (push) Successful in 50s
CI / build (push) Successful in 1m0s
CI / integration_tests (push) Successful in 3m43s
CI / coverage (push) Successful in 7m36s
CI / unit_tests (push) Successful in 8m25s
CI / docker (push) Successful in 9s
CI / benchmark-publish (push) Successful in 21m30s
|
||
|
|
67291b4614
|
Docs: Updated chat room | ||
|
|
a8bb543f96
|
Docs: Updated contributings general section to include prohibition on integration test mocks
CI / lint (push) Successful in 15s
CI / build (push) Successful in 17s
CI / quality (push) Successful in 19s
CI / security (push) Successful in 36s
CI / typecheck (push) Successful in 39s
CI / benchmark-regression (push) Has been skipped
CI / integration_tests (push) Successful in 5m16s
CI / unit_tests (push) Successful in 6m4s
CI / coverage (push) Successful in 5m53s
CI / docker (push) Successful in 52s
CI / benchmark-publish (push) Successful in 18m57s
|
||
|
|
ca4621f9ec |
Docs: Updated CONTRIBUTING.md to reflect new TDD bug workflow
CI / build (push) Successful in 16s
CI / quality (push) Successful in 55s
CI / security (push) Successful in 1m11s
CI / typecheck (push) Successful in 1m15s
CI / lint (push) Successful in 3m7s
CI / benchmark-regression (push) Has been skipped
CI / unit_tests (push) Successful in 3m34s
CI / integration_tests (push) Successful in 3m52s
CI / docker (push) Successful in 40s
CI / coverage (push) Successful in 4m28s
CI / benchmark-publish (push) Successful in 16m57s
|
||
|
|
1249f3c8cc |
Docs: small clarification about labels
CI / lint (push) Successful in 15s
CI / build (push) Successful in 15s
CI / typecheck (push) Successful in 34s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 1m51s
CI / quality (push) Successful in 3m33s
CI / integration_tests (push) Successful in 4m15s
CI / coverage (push) Successful in 5m36s
CI / unit_tests (push) Successful in 7m8s
CI / docker (push) Successful in 40s
CI / benchmark-publish (push) Successful in 14m11s
|
||
|
|
a60cda1f02 |
Docs: Fixed CONTRIBUTING.md error in stating dependency link direction
CI / lint (push) Successful in 14s
CI / build (push) Successful in 14s
CI / quality (push) Successful in 16s
CI / security (push) Successful in 31s
CI / typecheck (push) Successful in 46s
CI / benchmark-regression (push) Has been skipped
CI / unit_tests (push) Successful in 2m10s
CI / docker (push) Successful in 43s
CI / integration_tests (push) Successful in 3m12s
CI / coverage (push) Successful in 4m2s
CI / benchmark-publish (push) Successful in 14m52s
|
||
|
|
5f96255f2d |
Docs: Fixed contradiction in CONTRIBUTING.md
CI / lint (push) Successful in 16s
CI / build (push) Successful in 16s
CI / quality (push) Successful in 17s
CI / security (push) Successful in 32s
CI / typecheck (push) Successful in 34s
CI / benchmark-regression (push) Has been skipped
CI / integration_tests (push) Successful in 2m43s
CI / benchmark-publish (push) Successful in 12m38s
CI / unit_tests (push) Successful in 25m49s
CI / docker (push) Successful in 39s
CI / coverage (push) Has been cancelled
|
||
|
|
05310391c1 |
docs(spec): add devcontainer integration and resource type inheritance
CI / benchmark-publish (pull_request) Has been skipped
CI / lint (pull_request) Successful in 14s
CI / build (pull_request) Successful in 15s
CI / quality (pull_request) Successful in 17s
CI / security (pull_request) Successful in 30s
CI / typecheck (pull_request) Successful in 33s
CI / integration_tests (pull_request) Successful in 2m46s
CI / unit_tests (pull_request) Successful in 12m45s
CI / docker (pull_request) Successful in 9s
CI / benchmark-regression (pull_request) Successful in 21m45s
CI / coverage (pull_request) Successful in 48m39s
CI / lint (push) Successful in 14s
CI / build (push) Successful in 14s
CI / quality (push) Successful in 15s
CI / security (push) Successful in 30s
CI / typecheck (push) Successful in 38s
CI / benchmark-regression (push) Has been skipped
CI / integration_tests (push) Successful in 2m44s
CI / benchmark-publish (push) Successful in 12m32s
CI / unit_tests (push) Successful in 12m43s
CI / docker (push) Successful in 38s
CI / coverage (push) Successful in 47m56s
Created ADR-042 (Resource Type Inheritance) defining single-inheritance `inherits` field on resource type definitions with field resolution, collection merging, handler inheritance, polymorphic tool binding, auto-discovery, and DAG query matching. Max depth 5, single inheritance. Created ADR-043 (Devcontainer Integration) defining devcontainer-instance as a subtype of container-instance with lazy activation lifecycle, devcontainer.json parsing, three container-project association patterns (auto-detect, explicit mount, clone-into), and execution environment routing with a 6-level precedence chain. Specification updates across 20+ sections: - Glossary: Resource Type Inheritance, Devcontainer, Execution Environment - Resource type YAML schema: `inherits` field with structure reference - Handler, sandbox strategy, and coherence tables: devcontainer-instance - Auto-discovery: devcontainer detection subsection with WBS diagram - Tool capability metadata: structured environment subfields - Technology stack: devcontainer CLI row - Project model: execution environment subsection with YAML example - CLI agents resource add: --mount, --clone-into flags + 4 new examples - CLI agents plan use: --execution-environment, --execution-env-priority - CLI agents project context set: same execution environment flags - Command synopsis block: updated for all new flags - Execution environment routing section with precedence table + algorithm - Resource type YAML Example 6: Devcontainer Instance (inherited type) - End-to-end Example 16: Devcontainer-Driven Development - End-to-end Example 17: Explicit Container with Directory Mount - End-to-end Example 18: Container with Remote Repo Clone Also fixed ADR index: added missing ADR-036 through ADR-040 entries, updated next ADR number to 044. CONTRIBUTING.md fixes backported from sister project: - Fixed State label capitalization (State/In Progress -> State/In progress, State/In Review -> State/In review) to match label definitions. - Subtasks section: changed from optional to required, with exception clause for trivially simple issues. - Parent links: updated to use Forgejo dependency system instead of textual references in issue descriptions. - Fixed nox session flag typos: nox -e -> nox -s (7 occurrences). - Replaced "Epics and Legendaries" section with comprehensive "Ticket Type Hierarchy" defining the three-tier hierarchy (Issue -> Epic -> Legendary) with formal criteria tables, cross-cutting rules for hierarchy enforcement, completion semantics, promotion/demotion, and milestone relationship rules. - Fixed broken internal links referencing old "Epics and Legendaries" anchor to use "Ticket Type Hierarchy" (3 occurrences). - Traceability example: replaced project-specific code reference with generic example. - Removed stray horizontal rule before Project-Specific Guidelines. ISSUES CLOSED: #491 |
||
|
|
1282bc03b3 |
Docs: Updated timeline
CI / lint (push) Successful in 17s
CI / quality (push) Successful in 27s
CI / security (push) Successful in 36s
CI / build (push) Successful in 25s
CI / typecheck (push) Successful in 1m3s
CI / benchmark-regression (push) Has been skipped
CI / integration_tests (push) Successful in 3m24s
CI / benchmark-publish (push) Successful in 13m40s
CI / unit_tests (push) Successful in 14m50s
CI / docker (push) Successful in 1m10s
CI / coverage (push) Successful in 38m15s
|
||
|
|
417d17478f
|
Docs: Explicitly indicated dependency direction for blocking characteristics in CONTRIBUTING.md
CI / benchmark-publish (pull_request) Has been skipped
CI / lint (pull_request) Successful in 15s
CI / quality (pull_request) Successful in 18s
CI / build (pull_request) Successful in 20s
CI / security (pull_request) Successful in 29s
CI / typecheck (pull_request) Successful in 32s
CI / integration_tests (pull_request) Successful in 3m12s
CI / unit_tests (pull_request) Successful in 6m51s
CI / docker (pull_request) Successful in 15s
CI / benchmark-regression (pull_request) Successful in 16m15s
CI / coverage (pull_request) Successful in 23m13s
CI / lint (push) Successful in 13s
CI / quality (push) Successful in 18s
CI / build (push) Successful in 21s
CI / typecheck (push) Successful in 33s
CI / benchmark-regression (push) Has been skipped
CI / security (push) Successful in 36s
CI / integration_tests (push) Successful in 2m33s
CI / unit_tests (push) Successful in 6m58s
CI / docker (push) Successful in 8s
CI / benchmark-publish (push) Successful in 10m17s
CI / coverage (push) Successful in 22m57s
|
||
|
|
a7c51ed78c |
docs: clarify branch/tag ref rules for development vs non-development issues
CI / benchmark-publish (pull_request) Has been skipped
CI / lint (pull_request) Successful in 16s
CI / build (pull_request) Successful in 15s
CI / quality (pull_request) Successful in 19s
CI / security (pull_request) Successful in 30s
CI / typecheck (pull_request) Successful in 42s
CI / integration_tests (pull_request) Successful in 2m42s
CI / unit_tests (pull_request) Successful in 6m44s
CI / docker (pull_request) Successful in 21s
CI / coverage (pull_request) Has been cancelled
CI / benchmark-regression (pull_request) Has been cancelled
Refined the branch/tag (Ref) field requirement: development issues (features, fixes, chores) must set it to the same branch as the one in the Metadata section once the issue reaches State/In Progress, and must always reference a branch not a tag. Non-development issues (bug reports, questions, support) may leave it blank or optionally point to the branch or tag being referenced. Refs: #408 |
||
|
|
0d5e97ff62 |
docs: require branch/tag ref field on all issues in contributing guidelines
CI / benchmark-publish (pull_request) Has been skipped
CI / lint (pull_request) Successful in 15s
CI / build (pull_request) Successful in 16s
CI / quality (pull_request) Successful in 19s
CI / typecheck (pull_request) Successful in 31s
CI / security (pull_request) Successful in 37s
CI / integration_tests (pull_request) Successful in 3m50s
CI / benchmark-regression (pull_request) Has been cancelled
CI / coverage (pull_request) Has been cancelled
CI / unit_tests (pull_request) Has been cancelled
CI / docker (pull_request) Has been cancelled
Added requirement that every issue must have its Forgejo branch/tag (Ref) field set to the working branch once work begins. This field is separate from the branch name in the issue body Metadata section but must match it. Setting the field allows Forgejo to associate issues with branches in its UI. Refs: #408 |
||
|
|
bdda79f24b |
docs: add PR description and dependency link requirements to contributing guidelines
CI / benchmark-publish (pull_request) Has been skipped
CI / lint (pull_request) Successful in 15s
CI / quality (pull_request) Successful in 16s
CI / build (pull_request) Successful in 22s
CI / security (pull_request) Successful in 29s
CI / typecheck (pull_request) Successful in 30s
CI / integration_tests (pull_request) Successful in 4m3s
CI / coverage (pull_request) Has been cancelled
CI / benchmark-regression (pull_request) Has been cancelled
CI / unit_tests (pull_request) Has been cancelled
CI / docker (pull_request) Has been cancelled
Added explicit requirement that every PR must include a detailed description with a summary, closing keywords for linked issues, and a Forgejo dependency link. Updated the merge checklist with PR description and dependency link verification items. Reworked PR Process item 1 to be comprehensive about both the description body and the issue linkage. Refs: #408 |
||
|
|
31094b20b9 |
docs: add milestone and PR label requirements to contributing guidelines
CI / benchmark-publish (pull_request) Has been skipped
CI / lint (pull_request) Successful in 14s
CI / build (pull_request) Successful in 14s
CI / quality (pull_request) Successful in 18s
CI / typecheck (pull_request) Successful in 31s
CI / security (pull_request) Successful in 35s
CI / integration_tests (pull_request) Successful in 2m45s
CI / unit_tests (pull_request) Successful in 6m53s
CI / docker (pull_request) Has been cancelled
CI / coverage (pull_request) Has been cancelled
CI / benchmark-regression (pull_request) Has been cancelled
Added milestone requirements: issues beyond State/Unverified must be assigned to a milestone; PRs must be assigned to the same milestone as their linked issues. Added PR label rules: every PR must carry exactly one Type/ label matching the nature of the change. Updated the triaging checklist to include milestone assignment and updated the merge checklist with milestone and label verification items. Refs: #408 |
||
|
|
87d842732b |
docs: Clarified metadata on CONTRIBUTING.md
Refs: #408 |
||
|
|
9563da6485 |
docs: Fixed broken image link in CONTRIBUTING.md
Refs: #408 |
||
|
|
96516f4944 |
docs: Expanded the CONTRIBUTING.md document to give more details to the process of contributing issues, and pull requests
Refs: #408 |
||
|
|
9559414dc2 |
docs: Added commit guidlines to the contributing document
Refs: #408 |
||
|
|
e53c301ab6 |
docs: Updated CONTRIBUTING.md to be inclusive of everything relevant from the implementation plan
Refs: #408 |
||
|
|
496f565a57
|
Chore: Completed stage 1.5 | ||
|
|
3af47249ba
|
Added better guidlines for working with behave | ||
|
|
b14ef1fd7f
|
Final guidlines added to implementation plan, ready to execute I think. | ||
|
|
635b100322
|
Initial commit |