[BUG] Agent repeatedly ignores trigger handler pattern - puts inline logic in trigger instead of service class (Correction BASH on Windows)
Resolved 💬 3 comments Opened Jan 24, 2026 by JoshNorvellITD Closed Jan 24, 2026
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
- 3+ days, 20+ corrections on same issue
- Repeatedly put deletion logic inline in trigger when told to put it in service class
- Added extra method when explicitly told ONE method only
- Failed to read own notes before making edits
- User had to repeat the same instruction ("put it in the service class that's called by the trigger") 20+ times
What Should Happen?
When given explicit architecture instructions (e.g., "trigger calls service class, all logic in service class"):
- Agent should read and acknowledge the instruction
- Agent should follow the instruction on the first attempt
- When corrected, agent should not repeat the same mistake
- Agent should read project notes before making edits
Error Messages/Logs
Steps to Reproduce
- Create project notes with explicit architecture rules: - "Trigger should ONLY call service class"
- "ALL deletion logic in service class"
- "ONE method: deleteUnits()"
- Ask agent to modify error messages in the deletion feature
- Observe: Agent puts deletion logic inline in trigger instead of service class
- Correct agent: "Put it in the service class that's called by the trigger"
- Ask agent to make another change
- Observe: Agent repeats the same mistake - puts logic inline in trigger again
- Have an accepted version of the file that agent refers back to even though it's been stated there was a change
- Repeat steps 4-6 approximately 20 times over 3+ days
Claude Model
Opus
Is this a regression?
I don't know
Last Working Version
_No response_
Claude Code Version
Claude Code CLI: 2.1.19
Platform
Other
Operating System
Windows
Terminal/Shell
Windows Terminal
Additional Information
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗