You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In VS Code dev containers, there is no /run/user folder in the default Python container.
This means using user_runtime_path and trying to put anything there (or using the ensure_exists argument) will result in a crash, with PermissionError: [Errno 13] Permission denied: '/run/user'.
I'm not certain what the best route forwards is here, and this is not my area of expertise! Some tentative thoughts:
A good solution might be to fall back to a different user runtime directory location if /run/user doesn't exist.
An alternative would be to push this back to users of this package, warning them in the docs that the directory might not exist and they should check it beforehand (although this seems unideal).
Or maybe the default Python dev container should be updated so it does have a runtime dir.
The text was updated successfully, but these errors were encountered:
If $XDG_RUNTIME_DIR is not set applications should fall back to a replacement directory with similar capabilities and print a warning message. Applications should use this directory for communication and synchronization purposes and should not place larger files in it, since it might reside in runtime memory and cannot necessarily be swapped out to disk.
I think we should provide a different location if it doesn't exist.
Since user_runtime_dir takes appname and appauthor parameters, a decent tmp dir fallback folder name would be f"{appauthor}-{appname}-{username}".
When ensure_exists is used, the fallback folder should be explicitly created with 700 permissions when it's outside the user's home directory (and hence won't get user-only permissions by default).
In VS Code dev containers, there is no
/run/user
folder in the default Python container.This means using
user_runtime_path
and trying to put anything there (or using theensure_exists
argument) will result in a crash, withPermissionError: [Errno 13] Permission denied: '/run/user'
.I'm not certain what the best route forwards is here, and this is not my area of expertise! Some tentative thoughts:
/run/user
doesn't exist.The text was updated successfully, but these errors were encountered: