Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle ENOTDIR errno in Path::exists() #19

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

TryExceptElse
Copy link
Contributor

Previously, Path::exists() would produce an exception when a parent of
the checked path existed, but was not a directory (for example: if
the user called Path("foo/baz.txt").exists() when "foo" was a file).

This change makes Pathie act similarly to path libraries such as
Python's pathlib, which returns false given the same inputs.

Previously, Path::exists() would produce an exception when a parent of
the checked path existed, but was not a directory. For example, if
the user called `Path("foo/baz.txt").exists()` when "foo" was a file.

This change makes Pathie act more similarly to path libraries such as
Python's pathlib, which returns false given the same inputs.
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.

1 participant