Skip to content

fix: use OID instead of change ID in rewrite_commit_messages#95

Open
segfault-magnet wants to merge 1 commit intoLucioFranco:mainfrom
segfault-magnet:fix-divergent-oid
Open

fix: use OID instead of change ID in rewrite_commit_messages#95
segfault-magnet wants to merge 1 commit intoLucioFranco:mainfrom
segfault-magnet:fix-divergent-oid

Conversation

@segfault-magnet
Copy link
Copy Markdown

Closes: #94

Change IDs can be divergent (e.g. when a collaborator bases work on your stack without updating it), causing jj describe to reject the ambiguous target. Using the git commit OID directly avoids this.

Since OIDs are unstable across rebases — and jj describe rebases all descendants, giving them new OIDs — we reverse the iteration order to top-to-bottom. The topmost commit has no descendants, and each subsequent describe only rebases already-processed commits whose messages are preserved through rebase.

Change IDs can be divergent (e.g. when a collaborator bases work on
your stack without updating it), causing `jj describe` to reject the
ambiguous target. Using the git commit OID directly avoids this.

Since OIDs are unstable across rebases — and `jj describe` rebases all
descendants, giving them new OIDs — we reverse the iteration order to
top-to-bottom. The topmost commit has no descendants, and each
subsequent describe only rebases already-processed commits whose
messages are preserved through rebase.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

jj describe fails when change ID is divergent

1 participant