Skip to content

Commit 97ab5e1

Browse files
committed
chore: add recived path into panic info
1 parent cbba833 commit 97ab5e1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ pub fn is_dependency_tree_root<'a>(manifest: &'a Manifest, locator: &'a PackageL
196196

197197
pub fn find_locator<'a>(manifest: &'a Manifest, path: &Path) -> Option<&'a PackageLocator> {
198198
let rel_path = pathdiff::diff_paths(path, &manifest.manifest_dir)
199-
.expect("Assertion failed: Provided path should be absolute");
199+
.expect(&format!("Assertion failed: Provided path should be absolute but received {}", path.display()));
200200

201201
if let Some(regex) = &manifest.ignore_pattern_data {
202202
if regex.0.is_match(&util::normalize_path(rel_path.to_string_lossy())).unwrap() {

0 commit comments

Comments
 (0)