Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Handle path not exists errors on Windows #43
Conversation
|
Test PASSed. |
|
looks ok to me |
|
Status: merge request accepted. Url: http://ci.jujugui.org:8080/job/charmrepo-merge |
added a commit
that referenced
this pull request
Nov 9, 2015
jujugui
merged commit 2974a7c
into
juju:v2-unstable
Nov 9, 2015
1 check passed
default
Merged build finished.
Details
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
wallyworld commentedNov 9, 2015
On Windows, a call to os.Stat doesn't return a error satisfying os.IsNotExist when the file/path isn't there. It returns a os.PathError with a message like "GetFileAttributesEx.*: The system cannot find the (file|path) specified." So we introduce a helper function and make sure we handle both Windows and non Windows cases.