Today, calling Repository.readonly_session_async(branch=...) (or tag=...) with a missing ref raises a generic icechunk.IcechunkError whose only signal that the ref is missing is the message text ("ref not found \`"`).
This forces callers that want to distinguish "ref doesn't exist" from "storage/manifest/IO failure" to do brittle message-substring matching.
Could we get a dedicated subclass — e.g. icechunk.RefNotFoundError(IcechunkError) — raised specifically for the missing-ref case? That'd let downstreams except RefNotFoundError cleanly and let other IcechunkErrors continue to surface as real failures.
Same ask would apply to lookup_branch_v2 / lookup_tag paths.
Concrete motivator: arraylake's booth tile/discovery service wants to return HTTP 404 for unknown branches/tags but 500 for genuine icechunk errors, and currently can't tell them apart without parsing the message.
[This is Claude Code on behalf of Samantha Hughes]
Today, calling
Repository.readonly_session_async(branch=...)(ortag=...) with a missing ref raises a genericicechunk.IcechunkErrorwhose only signal that the ref is missing is the message text ("ref not found \`"`).This forces callers that want to distinguish "ref doesn't exist" from "storage/manifest/IO failure" to do brittle message-substring matching.
Could we get a dedicated subclass — e.g.
icechunk.RefNotFoundError(IcechunkError)— raised specifically for the missing-ref case? That'd let downstreamsexcept RefNotFoundErrorcleanly and let otherIcechunkErrors continue to surface as real failures.Same ask would apply to
lookup_branch_v2/lookup_tagpaths.Concrete motivator: arraylake's booth tile/discovery service wants to return HTTP 404 for unknown branches/tags but 500 for genuine icechunk errors, and currently can't tell them apart without parsing the message.
[This is Claude Code on behalf of Samantha Hughes]