I built an agent that fixes my pull requests every night. It is not allowed to merge them
Every night it boots a sandbox, clones a portfolio company's ๐ณ repos, and goes PR by PR: finds the bug or the missing adjacent work, pushes a fix (its own PR or a teammate's, withโฆ
Every night it boots a sandbox, clones a portfolio company's ๐ณ repos, and goes PR by PR: finds the bug or the missing adjacent work, pushes a fix (its own PR or a teammate's, with a comment saying why), re-runs the tests. Then it tries to merge.
The platform gate blocks every merge attempt. By design. The PR is left open with one comment: verified, one click away. Anything it cannot resolve skips the rest of the run and goes straight to my inbox.
First real run, on one repo: every Dependabot npm PR would have broken the stage build on a stale lockfile. Consolidated into one PR. An OpenTelemetry version conflict across ๐ฑ PRs. Consolidated into one. The root cause fixed in Dependabot's own config. Nothing merged. Three PRs in my inbox, each one click.
The same agent now runs for a second portfolio company. And the piece I am building this week sits above both of them: an agent that reads their nightly reports in my inbox, replies in the PRs to unblock them, and kicks them off again. A manager for the night shift.
Three things stay fixed as the tier grows.
๐ง๐ต๐ฒ ๐ฎ๐ด๐ฒ๐ป๐๐ ๐ฎ๐ฟ๐ฒ ๐ฐ๐ต๐ฒ๐ฎ๐ฝ ๐๐ผ ๐ฏ๐ฒ ๐๐ฟ๐ผ๐ป๐ด. A bad fix costs a re-run. They have no path to production.
๐ง๐ต๐ฒ ๐บ๐ฒ๐ฟ๐ด๐ฒ ๐ถ๐ ๐ฒ๐
๐ฝ๐ฒ๐ป๐๐ถ๐๐ฒ ๐๐ผ ๐ฏ๐ฒ ๐๐ฟ๐ผ๐ป๐ด. So it is gated, not trusted. Main is only even attempted on a Sunday, after an email goes out first.
๐ง๐ต๐ฒ ๐ฟ๐ฒ๐ฐ๐ผ๐ฟ๐ฑ ๐ถ๐ ๐๐ฟ๐ถ๐๐๐ฒ๐ป ๐ฒ๐ถ๐๐ต๐ฒ๐ฟ ๐๐ฎ๐. Merged, held, fixed, blocked, action items. Every night, whether the run succeeded or not.
People ask why not let it merge once it has proved itself. Because the moment the agent can merge, the trust boundary has moved to the wrong side of the wire, and I would be back to reviewing diffs at midnight to feel safe. The gate is what lets me not look.
What is the one action in your pipeline you would never let an agent take, even after a year of clean runs?

Further reading
How the whole company is run this way: https://sage7.ai/blog/one-person-company