top | item 46659800

(no title)

Filligree | 1 month ago

Yet another reason to use Jujutsu. And put a `jj status` wrapper in your PS1. ;-)

discuss

order

westurner|1 month ago

Start with env args like AGENT_ID for indicating which Merkle hash of which model(s) generated which code with which agent(s) and add those attributes to signed (-S) commit messages. For traceability; to find other faulty code generated by the same model and determine whether an agent or a human introduced the fault.

Then, `git notes` is better for signature metadata because it doesn't change the commit hash to add signatures for the commit.

And then, you'd need to run a local Rekor log to use Sigstore attestations on every commit.

Sigstore.dev is SLSA.dev compliant.

Sigstore grants short-lived release attestation signing keys for CI builds on a build farm to sign artifacts with.

So, when jujutsu autocommits agent-generated code, what causes there to be an {{AGENT_ID}} in the commit message or git notes? And what stops a user from forging such attestations?

diath|1 month ago

> Yet another reason to use Jujutsu

And what would that reason be? You can git revert a git revert.

jsnell|1 month ago

You're correct for an actual git revert, but it seems pretty clear that the original authors have mangled the story and it was actually either a "git checkout" or "git reset". The "file where 1-2 hours of progress had been accumulating" phrasing only makes sense if those were uncommitted changes.

And the reason jj helps in that case is that for jj there is no such thing as an uncommitted change.

mbb70|1 month ago

Probably it actually ran git checkout or reset. As you say git revert only operates on committed snapshots so it will all be in the reflog

glemion43|1 month ago

It's not going to happen...

Stop spamming

dwattttt|1 month ago

The feature of "there is no such thing as an uncommitted working directory" is very relevant to the situation.

NewsaHackO|1 month ago

This is funny. I tried it once and didn't see what the benefit was. Then, when I tried to reset it back to normal git, I realized that the devs had not (at the time) made any clean way to revert it back, just a one-way conversion to jj. I haven't tried it since.