gix notes - #2930
Draft
Sebastian Thiel (Byron) wants to merge 9 commits into
Draft
Conversation
Sebastian Thiel (Byron)
force-pushed
the
gix-notes
branch
from
August 19, 2026 09:01
360eb5c to
612e7a5
Compare
Draft
2 tasks
Sebastian Thiel (Byron)
force-pushed
the
gix-notes
branch
4 times, most recently
from
August 20, 2026 04:24
bd8b425 to
3c50e4d
Compare
Assisted-by: GPT 5.6
Assisted-by: GPT 5.6
Sebastian Thiel (Byron)
force-pushed
the
gix-notes
branch
2 times, most recently
from
August 20, 2026 14:10
81bec68 to
78c14d7
Compare
Even though in the good case, there will be more time spent, the first pass will catch most mistakes which then would cause an expensive re-run. Assisted-by: GPT 5.6 Co-authored-by: GPT 5.6 <codex@openai.com>
This makes it easier to see what failed. Assisted-by: GPT 5.6
Add `CorruptionError`, `NotFoundError`, and the source-preserving `RetryableError` marker, with constructors and message conversions for the concrete classification errors. Expose `Error::{can_retry,is_corrupted,is_not_found,is_validation}` plus a free `can_retry()` helper for classifying arbitrary standard errors.
Inspect complete source chains and recursively enter nested `gix_error::Error` values instead of relying on message text. Treat explicit retry markers and interrupted, unexpected-EOF, out-of-memory, timeout, broken-pipe, address-in-use, connection-aborted, connection-reset, and connection-refused I/O failures as retryable. Recognize missing resources through `NotFoundError` and `io::ErrorKind::NotFound`, while corruption and validation remain explicit typed classifications.
Add `Error::from_boxed()` so boxed `Send + Sync` standard errors can enter gix-error without losing their source chain.
Retain nested gix errors as typed values when converting or raising them instead of copying their sources into string-only frames. Preserve the remainder of copied standard source chains, recursively reveal erased `Untyped` payloads for downcasting, and render retained nested sources when formatting raised errors.
Make `Error::sources()` expand nested gix errors and expose stored payload types in auto-chain mode. Recurse through nested errors when selecting `probable_cause()`, mark the selected frame while flattening error trees, and let the final chained node fall back to the wrapped error source so source traversal and probable-cause identity survive conversion.
Keep classification and cause discovery consistent between tree-error mode and the flattened auto-chain-error representation. Extend both test suites to cover every classification, boxed conversion, nested conversions, typed-source retention, copied source chains, and probable causes after flattening, and update the crate documentation for the new categories and retention behavior.
<!-- agent --> Establish the minimal plumbing API needed to query notes efficiently for many objects, such as every commit visible in a history view. Resolve note blobs through Git notes progressive two-hex-digit fanout trees and use Git tree ordering for direct entry lookup. Load only trees along the requested object path and retain decoded trees in a caller-owned cache that can be reused across lookups and notes roots. Ignore entries that do not form valid notes instead of mistaking arbitrary tree contents for mappings. Use gix-error for contextual failures. Assisted-by: GPT 5.6 Co-authored-by: GPT 5.6 <codex@openai.com>
<!-- agent --> Add plumbing operations to insert, replace, and remove note mappings while returning the rewritten root tree and the previous note id. Rebuild notes using the same dynamic fanout rule as Git so growing and shrinking collections remain compatible with existing notes trees. Preserve unrelated entries during rewriting, reject mixed object-hash kinds, report duplicate mappings, and leave the tree unchanged when removing a missing note. Keep object persistence delegated through Find and Write traits, allowing callers to decide how commits and refs are updated. Assisted-by: GPT 5.6 Co-authored-by: GPT 5.6 <codex@openai.com>
<!-- agent --> Add the notes feature and `Repository::notes` as the porcelain layer over `gix-note` for repeated queries and mutations. Select the default notes ref from `core.notesRef`, including the `GIT_NOTES_REF` environment override represented in `config::tree`, and fall back to `refs/notes/commits`. Discover additional display refs from `notes.displayRef` or `GIT_NOTES_DISPLAY_REF`, expand glob patterns, preserve display order, and avoid duplicates. For mutations, accept conventional short notes-ref names, write note blobs and notes commits, and update refs with compare-and-swap expectations so concurrent changes are not silently overwritten. Assisted-by: GPT 5.6 Co-authored-by: GPT 5.6 <codex@openai.com>
Sebastian Thiel (Byron)
force-pushed
the
gix-notes
branch
from
August 20, 2026 15:28
78c14d7 to
e357100
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Tasks