Subagent ignores explicit instruction to skip test execution

Resolved 💬 1 comment Opened Jun 2, 2026 by Akhila-S96 Closed Jul 6, 2026

Summary

When a subagent is explicitly told in the prompt 'Do NOT run mvn test — run mvn compile only', it runs the full test suite anyway.

Environment

  • Claude Code CLI: 2.1.160
  • OS: Windows 11

Steps to reproduce

  1. Dispatch a subagent with prompt containing: 'Do NOT run mvn test or mvn verify. Run mvn compile -q only.'
  2. Observe: agent runs mvn verify (full test suite + Spring context boot)

Expected

Agent respects explicit tool-use constraints in the prompt.

Impact

Causes unnecessary 15-30 min delays per agent from cold Maven dependency downloads.

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗