upvote
I’m not advocating for no source control, but you can avoid loops like this with Architectural Decision Records. If you’re real lazy, let the agent maintain the ADRs and they will usually call out when these “painted into a corner” scenarios happen and you can then reason them around it.
reply
> Hmm, I have destroyed the file again, that's odd. Let me rebuild it from a half recollection of what it was supposed to do based on my compacted context.

It's the right approach if your business is selling tokens and the customer doesn't know any better.

reply
Right. But how to prevent adversarial agents working on the same code base from treating the ADR list as a form of malicious message exchange?
reply
Don’t let adversarial agents work on your code?? What is protecting an ADR against adversarial agents going to solve if they can just embed a highly advanced, obfuscated ‘rm -rf windows32’ anyway
reply
In theory, an agent could use git-bisect to identify when a bug was introduced. But the operator would have to be more interested in understanding the root cause than in fixing the current form of the bug...
reply
For me, Claude regularly looks at git blame after identifying a bug, then reads the commit message and other changes in the commit to understand the context of why that behavior was introduced like that. I wouldn't be surprised if it pulled out a git bisect

Then again, my standard instruction is something like "{bug description}. Find the root cause and propose possible solutions" so I guess I fit your profile

reply
Same, I basically take the derivative of a bug wrt every major dimension before I fix it.
reply
not really an option when you're working on a large codebase where a bisect means that a lot of steps could be multiple-hours of compiles. E.g if on a simple 12-step bisect you get 6/8 with a full rebuild you've already spent an entire work day on this
reply
> the operator would have to be more interested in understanding the root cause than in fixing the current form of the bug...

Can you even do the latter without the former?

reply
You can "fix" it (make the current reproducer not reproduce it anymore).
reply
I see it all the time, it is fixing the symptoms usually. It kind of works until it doesn’t and it fails miserably.

So yes you can and it works, sometimes…

reply
> Agents use source control, too.

This is true, but at 30,000 merges a day we're talking about nearly 1 million merges a month, and purely autonomous agentic merges tend to be noisy. Is this still a tractable problem, even for an agent? Do revisions older than a few days, other than perhaps release snapshots, have any relevance for such a process?

reply
That won't last. I see that as a disaster waiting to happen. There is absolutely no way they have control over what gets produced at that rate.
reply
Not all merges are equal, even if it's a monorepo, it's probably rare that you'd have to look at the whole codebase to implement a new feature or find the root cause of a bug. Once you start looking at the history of a specific folder, it becomes more tractable.

Of course that does require some folder structure, and agents are not necessarily great at that, but they're still decent enough that you do end up with many folders not being impacted hour or even daily.

reply
I am not sure that I can agree with this at this scale, especially for the hotspots in the code. But I admit that I am speculating here.
reply
> Agents use source control, too. It's a pretty important part of the development process to understand how code has changed.

This is a great idea, now they just have to use/do it. Maybe they can use it effectively by cloning the repo and having all the history at hand, rather than continuously scraping web pages with git content formatted for human brwosing.

reply
Anthropic can just replace pesky source control with a much better source guardrails. Aren't they all the rage and next step evolution in the computer security? Just ask Claud "pretty please do version control" and that should be enough, right?:)
reply
In this sentence who would be understanding the code changes, humans?
reply
The agents obviously.. I thought that was obvious.
reply
That's not super reassuring, until I know they can read, remember, and reference reliably at suitable complexity.
reply
And which is understanding the code changes meant for?
reply
Just have the agent rederive the revert, based on the facts of whatever made the change inappropriate.
reply
[flagged]
reply