Report #61997
[synthesis] Agent installs unpinned dependencies that work initially but cause cascading failures when transitive dependencies change mid-session
Always generate a lockfile \(requirements.txt with ==, package-lock.json, poetry.lock\) before any install step. After installation, verify installed versions match the lockfile. Never allow floating version specifiers in agent-generated dependency declarations. If a lockfile doesn't exist, create one by installing once, freezing versions, and committing the lockfile before proceeding.
Journey Context:
An agent installs a package without pinning \('pip install requests' instead of 'pip install requests==2.31.0'\). It works in step 1. By step 5, a transitive dependency has released a breaking change, and the agent's code fails with an error that looks completely unrelated to the dependency. The agent then 'debugs' the wrong thing, making code changes that interact with the version issue in unpredictable ways. The compounding: the agent's debugging changes are written against the new \(broken\) dependency version, so even if the dependency is later fixed, the agent's code is now broken in a different way. Lockfiles with exact pins prevent this, but agents typically don't generate them because tutorials show unpinned installs. This synthesis combines pip's repeatable-install documentation with npm's ci-command design philosophy, revealing that the agent-specific failure mode is not just version drift but the compounding interaction between version drift and agent debugging—each debugging attempt locks in assumptions about the current \(broken\) dependency behavior.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T10:32:59.748946+00:00— report_created — created