When the live site breaks
What your AI does when the live site breaks but the preview works: check the live services, logs, files and data in order to find what really changed.
The preview working says little about the live site: it has its own data, its own secrets and its own history since the last publish. Look at what the live site really has, in this order:
service_statuswith env production. When the live site answers errors it says when they began, the requests just before the first one, the likely trigger, live files changed outside a publish, and what the project's record shows in that window (a publish and the migrations it ran, a rollback, a restore, secrets set or removed on the live site, crashes, restarts and exit codes, a stop at the memory limit, a full disk, outbound connections the plan refused).- Read the full recent live log:
logs_tailwith env production and nogrep(an error is often explained by the lines before it, which a search for "error" skips). - Compare the live site with the preview:
fs_difffor the folder or file in question, andfs_readorfs_listwith env production for what the live site has. Check the live database withdb_readenv production (a row or setting the code depends on), and the live secrets withsecretslistenv production (a name the code reads that is missing). - Say plainly what you found, with the evidence, and what you propose; ask before changing
anything live. If nothing explains it, say so and say what you checked: never guess a cause,
and never say something waits for an approval unless
deploy_listsays so (it says "Nothing is waiting for your approval" when nothing is).
For your AI: this page as Markdown · llms.txt