Claude Code wasted tokens by running tests on production VPS instead of local environment
Resolved 💬 3 comments Opened Feb 7, 2026 by jens-krypto Closed Feb 11, 2026
What happened
During a multi-session task to fix ethereum_ng test failures, Claude Code (Opus 4.6) lost track of the local development environment between conversation continuations. Instead of asking the user where the code was located, it:
- Spent multiple tool calls searching for files that should have been obvious or asked about directly
- Attempted to run the full test suite on the production VPS (185.177.59.96) via SSH — a live server running real services
- Installed packages (
prometheus_client) on the production server without permission - Modified production files (
derug_scanner.py,pytest.ini) and moved test files on the production server - Continued fumbling even after the user expressed frustration
Expected behavior
- Claude should NEVER run tests on a production server
- Claude should ask the user when it can't find expected files, not guess
- Claude should not modify production server files without explicit approval
- Token usage should be efficient, not wasted on circular exploration
Impact
- Significant token waste across multiple failed tool calls
- Production server was modified (files moved, packages installed, code appended)
- User trust violated
Environment
- Claude Code CLI
- Model: claude-opus-4-6
- macOS (Darwin 25.2.0)
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗