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

drake/lock permissions #1232

Closed
2 tasks done
danwwilson opened this issue Mar 26, 2020 · 4 comments
Closed
2 tasks done

drake/lock permissions #1232

danwwilson opened this issue Mar 26, 2020 · 4 comments

Comments

@danwwilson
Copy link

Prework

Description

When creating a new drake project that is stored on a network drive the .drake/drake/history/lock file doesn't have group read permissions. This tends to cause issues for backup jobs (run under a backup user), as it isn't able to read the lock file.

What it means for me personally is needing to adjust the permissions for the lock file for each new drake project. While it's not a deal breaker, I was wondering if there might be something in the way that use_drake() creates objects that might allow the read permissions for the group to be applied.

@wlandau
Copy link
Member

wlandau commented Mar 27, 2020

use_drake() actually just creates script files. The cache gets created when you run make(), new_cache() or drake_config(). If you do not need drake_history(), you can set history = FALSE in make() or drake_config() to prevent history/lock from being generated at all. All the files in history/ are a txtq, and the lock file is generated by filelock. It will probably be easier on your end to troubleshoot similar issues with only those lighter packages.

@wlandau
Copy link
Member

wlandau commented Apr 14, 2020

You could also try and install wlandau/txtq@ba15026. That commit forces txtq to remove the lockfile periodically. It should solve this issue except if the drake session crashes at the wrong time and does not clean up.

@wlandau
Copy link
Member

wlandau commented Apr 14, 2020

Hmm... that turns out to not work on Windows for some reason. Try wlandau/txtq@4bf8876. In that commit, the lockfile is created in advance and outside filelock, which just might resolve permissions issues. I don't know.

@wlandau
Copy link
Member

wlandau commented Jun 23, 2020

From r-lib/filelock#26, it looks like this error came from the fact that some file systems do not support file locking. Should be fixed for drake in 2ffd42a. Feel free to give it a try.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants