fix(data-integrity): remove session.rollback() calls from all repository methods in UnitOfWork pattern #11054

Open
HAL9000 wants to merge 18 commits from pr_fix_8179 into master

18 Commits

Author SHA1 Message Date
CleverAgents Bot c921e76a5a ci: stop master workflow on PR updates
CI / lint (pull_request) Has been cancelled
CI / typecheck (pull_request) Has been cancelled
CI / security (pull_request) Has been cancelled
CI / quality (pull_request) Has been cancelled
CI / unit_tests (pull_request) Has been cancelled
CI / integration_tests (pull_request) Has been cancelled
CI / e2e_tests (pull_request) Has been cancelled
CI / coverage (pull_request) Has been cancelled
CI / build (pull_request) Has been cancelled
CI / docker (pull_request) Has been cancelled
CI / helm (pull_request) Has been cancelled
CI / push-validation (pull_request) Has been cancelled
CI / status-check (pull_request) Has been cancelled
Remove the stale pull_request trigger from master.yml so PR branch commits do not launch the master workflow.

Maintenance patch for PR #11054.
2026-06-10 20:19:41 -04:00
HAL9000 476d7bb718 test(bdd): add repository error handling rollback cleanup scenarios
CI / benchmark-publish (pull_request) Has been skipped
CI / push-validation (pull_request) Successful in 46s
CI / helm (pull_request) Successful in 1m7s
CI / lint (pull_request) Failing after 1m12s
CI / build (pull_request) Successful in 1m16s
CI / benchmark-regression (pull_request) Failing after 1m23s
CI / unit_tests (pull_request) Failing after 1m39s
CI / quality (pull_request) Successful in 1m54s
CI / typecheck (pull_request) Successful in 1m58s
CI / docker (pull_request) Has been skipped
CI / coverage (pull_request) Has been skipped
CI / security (pull_request) Successful in 1m58s
CI / integration_tests (pull_request) Successful in 4m31s
CI / e2e_tests (pull_request) Failing after 4m55s
CI / status-check (pull_request) Failing after 3s
Add BDD tests verifying the #8179 fix: repositories no longer call
session.rollback() on database errors, delegating transaction management
to the UnitOfWork pattern instead. Also fixes formatting issue in
CONTRIBUTORS.md (removed stray << prefix from line).

BDD scenarios verify:
- Database errors propagate through repositories without swallowing
- Cross-repository atomicity preserved within UoW transactions
- Mock-based verification that repo error handlers don't call rollback
- UoW owns session rollback exclusively

ISSUES CLOSED: #8179, #10451
2026-05-08 23:35:39 +00:00
HAL9000 fe0b66a293 fix(data-integrity): remove session.rollback() calls from all repository methods in UnitOfWork pattern
CI / benchmark-publish (pull_request) Has been skipped
CI / push-validation (pull_request) Successful in 50s
CI / helm (pull_request) Successful in 58s
CI / build (pull_request) Successful in 1m19s
CI / lint (pull_request) Successful in 1m24s
CI / quality (pull_request) Successful in 1m35s
CI / benchmark-regression (pull_request) Failing after 1m45s
CI / typecheck (pull_request) Successful in 1m49s
CI / security (pull_request) Successful in 1m58s
CI / integration_tests (pull_request) Successful in 3m48s
CI / e2e_tests (pull_request) Successful in 4m30s
CI / unit_tests (pull_request) Failing after 4m59s
CI / coverage (pull_request) Has been skipped
CI / docker (pull_request) Has been skipped
CI / status-check (pull_request) Failing after 5s
Remove 58 redundant session.rollback() calls across three database
repository files that interfere with the UnitOfWork (UoW) transaction
management. Individual repository-level rollbacks caused data-integrity
violations by rolling back changes from OTHER repositories within the
same UoW transaction, resulting in silent loss of valid operations.

Rollback responsibility is now consolidated in the UoW's transaction()
context manager which handles atomicity per-transaction. Self-committing
repositories (ToolRegistryRepository, ValidationAttachmentRepository,
NamespacedProjectRepository, ProjectResourceLinkRepository) that manage
their own complete lifecycle are unaffected and retain internal rollback.

Files modified:
  - repositories.py: removed 52 rollback calls
  - changeset_repository.py: removed 5 rollback calls
  - llm_trace_repository.py: removed 1 rollback call

ISSUES CLOSED: #8179
2026-05-08 15:13:37 +00:00
clever-agent 7d3715bd58 build: restricted bash to durther prevent force merges or sudo escalation
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 1m24s
CI / lint (pull_request) Successful in 1m38s
CI / quality (pull_request) Successful in 1m39s
CI / push-validation (pull_request) Successful in 48s
CI / benchmark-regression (pull_request) Failing after 1m29s
CI / helm (pull_request) Successful in 57s
CI / typecheck (pull_request) Successful in 1m58s
CI / security (pull_request) Successful in 2m1s
CI / e2e_tests (pull_request) Successful in 5m57s
CI / integration_tests (pull_request) Successful in 6m56s
CI / unit_tests (pull_request) Failing after 9m12s
CI / docker (pull_request) Has been skipped
CI / coverage (pull_request) Has been skipped
CI / status-check (pull_request) Failing after 3s
2026-05-07 23:17:32 -04:00
clever-agent d53cdc3607 build: Had to re-restrict the permissions on the agents, they were misbehaving 2026-05-07 21:08:31 -04:00
clever-agent 5d02a7c957 Fixed a bad/old escalation table 2026-05-07 18:10:43 -04:00
HAL9000 b9edc377d8 docs(spec): clarify layer boundary DI exception, ULID scope, TUI/ACMS gap-fill [AUTO-ARCH-1]
Add targeted clarifications to docs/specification.md to fill identified gaps:

1. Layer boundary DI Container Exception (Cross-Milestone Architectural Invariants)
2. ULID Scope Clarification - domain vs internal identifiers
3. ACMS Pipeline Protocol Contracts with storage tiers and budget protocol
4. TUI Component Interfaces with verifiable checks

Co-authored-by: CleverAgents Bot <bot@cleveragents.com>

ISSUES CLOSED: #10451
2026-05-07 10:43:39 +00:00
clever-agent df04392ebb build: testing agents with allow first permissions 2026-05-06 22:36:23 -04:00
clever-agent 8758455aaa build: fixed the tiers to now only use qwen and kimi 2026-05-05 23:27:43 -04:00
clever-agent 581b59f070 build: improved the startup script for auto-agents 2026-05-05 20:19:24 -04:00
clever-agent 3da61ba891 build: opened up echo and cat perms to help smooth over some tool calls 2026-05-05 20:11:19 -04:00
clever-agent b75feaf7a3 build: changed permission on auto-agents script 2026-05-05 18:56:03 -04:00
clever-agent 7dda57b054 build: added deny permission for sudo calls 2026-05-05 18:54:42 -04:00
clever-agent fc5a8a9e6d build: implement explicit-vs-fetched variable propagation across all agents
All agents now track which variables were explicitly present in their prompt
versus fetched from environment variables or git remote. When constructing
subagent prompts, only explicitly-present variables are included. Fetched
variables are omitted, allowing each subagent to fetch them independently.

This prevents credentials and other fetched values from being garbled as they
propagate through multiple LLM prompt layers.

Affected agents:
- auto-agents (primary orchestrator)
- implementation-supervisor, pr-merge-supervisor, pr-review-supervisor
- supervisor (generic)
- implementation-worker, pr-merge-worker, pr-review-worker
- task-implementor, tier-dispatcher
- work-group-util, git-clone-util, git-push-util, git-checkout-util
2026-05-05 22:22:09 +00:00
clever-agent f8f74a56d9 build: added critical rule clearly stating no question asking 2026-05-05 16:54:25 -04:00
clever-agent 02e7cb39f6 build: improved some of the standard bash permissions to access fetchable variables at every level 2026-05-05 16:32:01 -04:00
clever-agent e1bfc970a7 build: Fixed models being used to align with new endpoints 2026-05-05 16:18:33 -04:00
clever-agent e16181a7ec build: pulled in new endpoints and fixing permission from experimental branch 2026-05-05 16:12:53 -04:00