Skip to content

feat: chainlink backlog worker MVP#69

Merged
tkellogg merged 3 commits into
mainfrom
feat/chainlink-worker
Apr 3, 2026
Merged

feat: chainlink backlog worker MVP#69
tkellogg merged 3 commits into
mainfrom
feat/chainlink-worker

Conversation

@tkellogg
Copy link
Copy Markdown
Owner

@tkellogg tkellogg commented Apr 3, 2026

Adds optional-skills/chainlink-worker/ with:

  • worker.py: main orchestration loop (poll chainlink → claim → Codex → review → close)
  • prompt_builder.py: initial and review prompt construction
  • config.py: TOML config loader with defaults
  • poller.py: review notifier for Keel (surfaces ready-for-review issues)
  • pollers.json: poller registration
  • SKILL.md: operator documentation

Tests: 9 new tests (3 worker lifecycle, 2 prompt builder, 3 config, 1 repo routing) All pass. No new dependencies.

Known follow-up items:

  • Timeout test coverage
  • run() loop integration test
  • Poller CWD resolution (scheduler runs from repo root)

Adds optional-skills/chainlink-worker/ with:
- worker.py: main orchestration loop (poll chainlink → claim → Codex → review → close)
- prompt_builder.py: initial and review prompt construction
- config.py: TOML config loader with defaults
- poller.py: review notifier for Keel (surfaces ready-for-review issues)
- pollers.json: poller registration
- SKILL.md: operator documentation

Tests: 9 new tests (3 worker lifecycle, 2 prompt builder, 3 config, 1 repo routing)
All pass. No new dependencies.

Known follow-up items:
- Timeout test coverage
- run() loop integration test
- Poller CWD resolution (scheduler runs from repo root)
- DEFAULT_CHAINLINK_CWD now uses Path.cwd() instead of hardcoded path
- DEFAULT_REPOS is empty dict — configure via config.toml [repos] section
- SKILL.md references changed to generic 'your chainlink working directory'
- SKILL.md commands use plain 'chainlink' instead of ~/.cargo/bin/chainlink
- Tests updated to assert against constants, not hardcoded paths
- config.py: new [settings] + [workers.*] TOML schema with WorkerConfig/Settings/AppConfig
- worker.py: full async rewrite with Worker (per-repo, owns worktree) and Poller (singleton, routes issues)
- Stale claim reaper on startup + every 10 polls
- IssueAbandoned exception for cooperative abort
- Graceful shutdown via SIGINT/SIGTERM cancellation
- 11 tests covering config, routing, round-robin, stale claims, full lifecycle, shutdown, queue sequencing
- Codex caught and fixed abort-flag cleanup edge case in release_current_issue and close_session_only
@tkellogg tkellogg merged commit 35d4991 into main Apr 3, 2026
@tkellogg tkellogg deleted the feat/chainlink-worker branch April 3, 2026 14:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant