Skip to content

feat: open new Linear issue when agent finds unrelated problems#4

Merged
mr-j90 merged 1 commit intomasterfrom
zyx-78
Mar 19, 2026
Merged

feat: open new Linear issue when agent finds unrelated problems#4
mr-j90 merged 1 commit intomasterfrom
zyx-78

Conversation

@mr-j90
Copy link
Copy Markdown
Collaborator

@mr-j90 mr-j90 commented Mar 19, 2026

Summary

  • Agents can now surface unrelated bugs/issues discovered during a run by writing .symphony/findings.json to their workspace
  • After each agent turn the orchestrator reads this file, creates a Linear issue per finding (with context linking back to the source issue), then removes the file
  • Turn-1 prompts are automatically extended with instructions explaining the findings protocol so agents know how to use it

Changes

  • internal/model/types.go — new Finding struct (title, description)
  • internal/linear/client.goFetchTeamID and CreateIssue methods
  • internal/orchestrator/orchestrator.goprocessFindings helper, wired into both Codex and Claude worker loops; buildTurnPrompt appends findings instructions on turn 1
  • internal/linear/client_test.go — tests for FetchTeamID and CreateIssue (success, GraphQL error, success=false cases)

Test plan

  • go test ./internal/linear/... passes (includes new TestFetchTeamID_* and TestCreateIssue_* tests)
  • go test ./internal/orchestrator/... passes
  • Manually verify: place a .symphony/findings.json in a workspace between turns and confirm a new Linear issue is created and the file is removed

🤖 Generated with Claude Code

When an agent discovers bugs or issues unrelated to the current task,
it now writes them to .symphony/findings.json in the workspace. After
each turn the orchestrator reads this file, creates a Linear issue for
each finding (attributed to the source issue), and removes the file.

- Add Finding model type (title + description)
- Add FetchTeamID and CreateIssue to the Linear client
- Append findings instructions to turn-1 prompts so agents know the protocol
- Wire processFindings into both Codex and Claude worker loops
- Add tests for FetchTeamID and CreateIssue (success, GraphQL error, failure cases)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@linear
Copy link
Copy Markdown

linear Bot commented Mar 19, 2026

@mr-j90 mr-j90 merged commit 5124d74 into master Mar 19, 2026
8 checks passed
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