fix: address PR #149 review findings

- Replace custom contains/searchString with strings.Contains in tests
- Fix variable shadow (r -> reposJSON) in workspace handler
- Wire daemon auth token + server URL into spawned agent env vars
- Remove unused CreateAgentTaskWithContext query (dead code after refactor)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
yushen 2026-03-27 16:15:58 +08:00
parent 327973be08
commit 4d8b2edb2d
5 changed files with 11 additions and 62 deletions

View file

@ -54,11 +54,6 @@ WHERE issue_id = $1 AND status IN ('queued', 'dispatched', 'running');
SELECT * FROM agent_task_queue
WHERE id = $1;
-- name: CreateAgentTaskWithContext :one
INSERT INTO agent_task_queue (agent_id, runtime_id, issue_id, status, priority, context)
VALUES ($1, $2, $3, 'queued', $4, $5)
RETURNING *;
-- name: ClaimAgentTask :one
UPDATE agent_task_queue
SET status = 'dispatched', dispatched_at = now()