Description
I encountered this error when building docs using cargo doc
for my project. I did some digging. and managed to locate where the error originated: in config::Cache::excludes_file()
it calls self.trusted_file_path()
to get the path for the EXCLUDES_FILE:
in trusted_file_path()
, self.resvoled.path_fillter(...)
returns a value of Some("")
(it's actual type is Path
not &str
but you get the point) which cause path.interpolate(ctx)
to return an Err(interpolate::Error)
:
it turns out in my git config file, there exists an entry for core.excludesfile
, but it's value is blank:
[core]
excludesfile =
I don't remember how it came to be, I think this might be a leftover by the SourceTree GUI app.
and I'm not sure if this is expected behavior or misbehavior, but apparently libgit2
didn't treat this as an error case.
I guess another way to state question is, should path_filter()
return Some("")
or should it return None
for an blank path?