Skip to content

Conversation

@carlsverre
Copy link
Contributor

Part of a push in Graft: orbitinghail/graft#262

Copilot AI review requested due to automatic review settings December 9, 2025 00:48
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR removes the culprit dependency from the codebase as part of a larger effort tracked in issue #262. The changes convert all error handling from culprit::Result with context tracking to standard Rust Result types.

Key changes:

  • Removed culprit dependency from Cargo.toml and Cargo.lock
  • Converted all function signatures from culprit::Result<T, E> to Result<T, E>
  • Simplified error construction from Culprit::new(err) to direct error returns
  • Removed culprit-specific method calls like .or_into_ctx() and .ctx()
  • Updated assert_error! macro to work with standard Result types
  • Updated documentation examples to reflect the new error handling

Reviewed changes

Copilot reviewed 8 out of 9 changed files in this pull request and generated no comments.

Show a summary per file
File Description
Cargo.toml Removed culprit = "0.4" dependency
Cargo.lock Removed culprit and smallvec (transitive dependency) package entries
src/testutil.rs Updated assert_error! macro to not call .ctx() on errors
src/splinter_ref.rs Converted public API from_bytes to return Result<Self, DecodeErr>, removed Culprit wrapper usage and import, updated doc example
src/cow.rs Converted public API from_bytes to return Result<Self, DecodeErr>, removed Culprit import
src/codec.rs Converted ensure_bytes_available to return standard Result, removed direct error wrapping with Culprit::new(), removed Culprit import
src/codec/tree_ref.rs Converted from_suffix to return standard Result
src/codec/runs_ref.rs Converted from_suffix to return standard Result, removed .or_into_ctx() call and ResultExt import
src/codec/partition_ref.rs Converted all function signatures to standard Result, removed .or_into_ctx() calls and ResultExt import, cleaned up function formatting

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@carlsverre carlsverre merged commit 2f8c881 into main Dec 9, 2025
9 checks passed
@carlsverre carlsverre deleted the feat/remove-culprit branch December 9, 2025 00:51
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.

2 participants