Solves the "shared bot account problem" by introducing a separate Forgejo
reviewer account (FORGEJO_REVIEWER_PAT / FORGEJO_REVIEWER_USERNAME).
- pr-reviewer.md: rewrote review protocol to use reviewer credentials,
formal APPROVED reviews are now the primary path (not a workaround)
- pr-review-pool-supervisor.md: passes reviewer credentials to dispatched reviewers
- pr-merge-pool-supervisor.md: updated approval detection to recognize
reviewer account as primary approver
- product-builder.md: passes reviewer creds when launching review pool
- shared/credential_security.md: added FORGEJO_REVIEWER_PAT and
FORGEJO_REVIEWER_USERNAME to required credentials
Per Subagent Specialization Principle: removed 17 duplicated rolling
average calculation blocks from all supervisors. The ATM now handles
interval calculation internally via --sleep-interval-default parameter.
- automation-tracking-manager.md: added sleep_interval_default to CREATE_TRACKING_ISSUE,
added CYCLE_ANNOUNCEMENT_REVIEW operation (#11)
- All 17 supervisor agents: replaced 7-line interval calc with --sleep-interval-default param
- shared/tracking_discovery_guide.md: updated to reference ATM-handled interval
- automation-tracking-manager.md: added estimated_cycle_interval to READ_TRACKING_STATE return
- system-watchdog-pool-supervisor.md: replaced hardcoded interval lookup with parsing from
status issue body, changed staleness threshold from 1.2x to 2x
- backlog-grooming-pool-supervisor.md: added Pass 20 for duplicate status issue deduplication
- shared/tracking_discovery_guide.md: added rolling average calculation pattern
- automation-tracking-manager.md: enhanced READ_TRACKING_STATE to return full
comments, creation timestamp, and offline duration for crash recovery
- implementation-pool-supervisor.md: added state recovery as mandatory first
action (before PR analysis), with branch/PR target extraction and resume logic
- product-builder.md: replaced manual curl state detection with ATM
READ_TRACKING_STATE for consistent crash recovery
- shared/tracking_discovery_guide.md: added mandatory startup recovery protocol
documenting the correct read-then-delete-then-create sequence
The forgejo_merge_pull_request MCP tool returns 'Pull request merged
successfully' even when the merge silently fails (e.g. branch behind
base). This caused the PR merge supervisor to post false 'Automatically
merged' comments on PRs that were never actually merged (e.g. #6726,
#6695, #5276, #6571).
Three interconnected fixes:
- pr-merge-pool-supervisor: Always verify merge via
forgejo_get_pull_request_by_index (merged==true, state==closed) before
posting success comments. Check merge_base vs base.sha before merge
and auto-rebase when branch is behind. Handle silent merge failures
with rebase-and-retry on next cycle.
- shared/merge_safety: safe_merge_pr() now verifies merge completed by
checking PR state after the API call. Returns failure when PR is still
open despite the tool claiming success.
- implementation-worker: Add rebase-before-merge check and verification
rules to the ready-to-merge workflow.
ISSUES CLOSED: #6726
Root cause: Forgejo rejects formal APPROVED reviews when the reviewer is
the same user who created the PR ("approve your own pull is not allowed").
Since all agents share a single bot account (HAL9000), every PR is both
authored and reviewed by the same user, making formal APPROVED reviews
impossible. All merge agents only checked for formal APPROVED reviews or
issue comments, but the pr-reviewer posted approval language in review
bodies (state=COMMENT) — a source no merge agent inspected.
This created a deadlock: PRs had passing CI, were mergeable, and had been
reviewed with approval language, but no agent could detect the approval.
Changes:
- shared/merge_safety.md: Add review-body scanning to check_flexible_approval
so COMMENT/PENDING reviews containing approval keywords (lgtm, approved,
decision: approved, etc.) count as valid approvals alongside formal
reviews and issue comments.
- pr-merge-pool-supervisor.md: Update check_pr_approval() with the same
3-tier detection (formal review → review body → issue comment). Update
has_blocking_reviews() to compare REQUEST_CHANGES timestamps against
approval signals from all three sources.
- implementation-worker.md: Update both has_required_approvals() functions
with 3-tier approval detection matching the shared utilities.
- pr-reviewer.md: Replace single-step review with two-step protocol:
(1) Always post an issue comment with clear approval keywords — this is
the durable signal merge automation detects. (2) Also attempt a formal
APPROVED review — succeeds for non-self PRs, gracefully fails for self
PRs. The comment from step 1 is sufficient on its own.
- devcontainer configs: Add explicit -url and -token flags to forgejo-mcp
command; update deprecated GITEA_ env vars to FORGEJO_ equivalents.
- Update pr-merge-pool-supervisor to accept both formal reviews and approval comments
- Add support for self-approval via comments (LGTM, approved, ✅, ready to merge, etc.)
- Implement comprehensive approval detection that checks formal reviews and comments
- Add blocking review detection to prevent merging with unresolved change requests
- Update merge safety utilities to use flexible approval detection
- Include approval details in merge success comments
- Maintain backward compatibility with existing formal review workflows
This fixes the issue where PRs with passing quality gates and comment-based
approvals (including self-approval) were not being merged automatically.
- Fix automation-tracking.md to use new pool supervisor names
- Update session_state.md to reference implementation-pool-supervisor
- Fix pr-status-analyzer.md to reference pr-ci-test-fixer
- Fix implementation-pool-supervisor references to '32 workers'
- Remove hardcoded comment about '10 for this session'
- Update remaining old agent name references in tracking files
- Ensure all pool supervisors reference CA_MAX_PARALLEL_WORKERS env var
- Extended automation-tracking-manager to support announcement issues
- Added CREATE_ANNOUNCEMENT_ISSUE operation with priority support
- Added CLOSE_ANNOUNCEMENT_ISSUE and LIST_TRACKING_ISSUES operations
- Added READ_ANNOUNCEMENTS for cross-agent awareness
- Added REVIEW_OWN_ANNOUNCEMENTS for lifecycle management
- Updated all operations to use forgejo-label-manager for labels
- Removed search limits to ensure all issues are found
- Standardized tracking issue title formats
- Status: [PREFIX] Status: <description> (Cycle N)
- Announcements: [PREFIX] Announce: <message>
- Enhanced backlog-groomer announcement cleanup
- Different age thresholds by priority (Critical: 72h, High: 48h, Medium: 24h, Low: 12h)
- Smarter relevance detection based on content patterns
- Two-stage closure process with confidence levels
- Detects and closes duplicate status tracking issues
- Added announcement reading to key agents
- Supervisors read critical announcements before each cycle
- Workers read announcements from system agents and orchestrator
- Priority-based filtering to reduce noise
- Periodic review of own announcements for cleanup
- Updated all agents to use automation-tracking-manager for announcements
- Replaced direct API calls with centralized subagent invocations
- Ensures consistent formatting and priority handling
- Enables proper lifecycle management
- Added clone isolation requirement to architect agent
This enables agents to be aware of critical system issues discovered by other agents
and adjust their behavior accordingly, while preventing announcement accumulation
through intelligent cleanup and relevance-based filtering.
- Create automation-tracking-manager subagent as single source of truth
- Migrate 7 key agents to use centralized tracking manager
- Fix AUTO-WATCHDOG skipping cycles 22-23 (was commenting on old issues)
- Fix AUTO-IMP-POOL creating duplicate tracking issues for same cycle
- Fix AUTO-TIME and AUTO-PROJ-OWN potential issue reuse patterns
- Ensure cycle numbers persist across agent restarts
- Delete shared/automation_tracking.md in favor of subagent pattern
The new system ensures:
- One tracking issue per cycle (never reuse old issues)
- Sequential cycle numbers that persist across restarts
- Proper cleanup of previous cycles before creating new ones
- Consistent tracking patterns across all agents
- Impossible for agents to comment on old tracking issues
Migrated agents:
- system-watchdog (most problematic - missing cycles)
- implementation-orchestrator (duplicate issues)
- timeline-updater (potential reuse)
- project-owner (potential reuse)
- product-builder (critical orchestrator)
- backlog-groomer (for consistency)
Fixes the issue where agents incorrectly report future cycles as comments
on older status update tickets instead of creating new tracking issues.
BREAKING CHANGE: Migrate all CleverAgents from shared session state issue
system to individual tracking issues with 'Automation Tracking' labels
Changes:
- Replace SESSION_STATE_ISSUE_NUMBER with individual tracking issues
- Add automation tracking systems to 10 core agents
- Implement standardized agent prefixes (AUTO-UAT-POOL, AUTO-PROJ-OWN, etc.)
- Add cleanup protocols for one-issue-per-cycle management
- Remove session state dependencies from supervisor launch prompts
- Update health signaling to create individual tracking issues
- Preserve announcement issues while cleaning up cycle reports
Affected agents:
- agent-evolver.md: Added AUTO-EVLV tracking system
- bug-hunter.md: Updated tracking documentation
- epic-planner.md: Fixed remaining session state reference
- implementation-orchestrator.md: Updated health signaling
- product-builder.md: Major refactor of supervisor coordination
- project-owner.md: Added AUTO-PROJ-OWN tracking system
- spec-updater.md: Added AUTO-SPEC-UPD tracking system
- test-infra-improver.md: Added AUTO-TEST-INFRA tracking system
- uat-tester.md: Added AUTO-UAT-POOL tracking system
Benefits:
- Better isolation: no shared state conflicts between agents
- Cleaner tracking: one issue per agent per cycle
- Full traceability: each agent's work is independently tracked
- Systematic discovery: standardized labels enable monitoring
This migration follows the automation tracking specification in
.opencode/agents/shared/automation_tracking.md and maintains
compatibility with existing CleverAgents infrastructure.
- Fix tracking issues not always using 'Automation Tracking' label
- Convert agents from session state to individual tracking issues
- Add standardized automation tracking system for all agents
- Enable cross-agent discovery and coordination capabilities
Changes:
- Add shared/automation_tracking.md: standardized tracking functions
- Add shared/tracking_discovery_guide.md: agent coordination guide
- Update continuous-pr-reviewer.md: use AUTO-REV-POOL tracking
- Partial update bug-hunter.md: add AUTO-BUG-POOL system
- Add bug_hunter_tracking_update.md: completion guide
- Add tracking_system_fixes_summary.md: comprehensive overview
All tracking issues now guaranteed to have 'Automation Tracking' label
for auto-discovery. Agents can find each other's activities and coordinate
through standardized prefix system (AUTO-SESSION, AUTO-WATCHDOG, etc).
Resolves issue where tracking tickets weren't discoverable due to
missing required label.
- Remove maximum cap (16) on CA_MAX_PARALLEL_WORKERS in resources.yaml
- Can now be set to any positive value (32, 64, etc.)
- Only minimum validation remains (must be > 0)
- Remove dynamic backpressure/throttling from implementation-orchestrator
- Dispatch always runs at full configured speed
- Resource monitoring remains for visibility only
- No automatic reduction of slots_available based on failures
- Convert system-watchdog from auto-degradation to monitoring + suggestions
- Renamed DEGRADATION_THRESHOLDS to HEALTH_THRESHOLDS
- Removed apply_system_degradation() and check_degradation_recovery()
- Changed findings to include suggestions instead of actions
- Watchdog now reports issues with fix recommendations
- No automatic throttling or pausing of agents
The system now operates at maximum configured speed at all times,
with the watchdog providing diagnostic insights when issues arise.