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

Better reporting or documentation of failed folder creations due to search permissions #91

Open
TimeTravelPenguin opened this issue Dec 8, 2023 · 0 comments

Comments

@TimeTravelPenguin
Copy link

I am using an Apple M3 Max, Sonoma Version 14.1.2 (23B2091), using path-io v1.8.1.

I just spent some time debugging a personal project of mine, trying to figure out why ensureDir (more generally createDir).
In my application, I am currently just simply storing a json config in the application directory. However, when using stack, this executable is in a directory where all privileges except searchable are given.

When using ensureDir to make sure a subdirectory exists to write some files into, the application throws an error:

myApp-exe: /path/to/.../.stack-work/install/aarch64-osx/.../bin/myApp-exe: createDirectory: inappropriate type (Not a directory)

The docs specify:

InappropriateType The path refers to an existing non-directory object. [EEXIST]

But this didn't really help in solving the problem.

While this is clearly an issue for me to better manage in my application to avoid this problem, either better documentation or reporting would be helpful.

Thanks

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

No branches or pull requests

1 participant