Skip to content

Commit

Permalink
Improve debug message
Browse files Browse the repository at this point in the history
  • Loading branch information
UebelAndre committed Feb 9, 2025
1 parent 91b6083 commit 063fbdc
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/sparse.rs
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ impl SparseIndex {
.cache_path(name)
.ok_or_else(|| io::Error::new(io::ErrorKind::InvalidInput, "bad name"))?;

let cache_bytes = std::fs::read(cache_path)?;
let cache_bytes = std::fs::read(&cache_path)
.map_err(|e| io::Error::new(e.kind(), format!("{}: `{}`", cache_path.display(), e.to_string())))?;
Ok(Crate::from_cache_slice(&cache_bytes, None)?)
}

Expand Down

0 comments on commit 063fbdc

Please sign in to comment.