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
{{ message }}
This repository has been archived by the owner on Nov 17, 2024. It is now read-only.
When I run Python code with isolate, I receive this error:
Failed to import the site module
Traceback (most recent call last):
File "/usr/lib/python3.6/site.py", line 544, in <module>
main()
File "/usr/lib/python3.6/site.py", line 530, in main
known_paths = addusersitepackages(known_paths)
File "/usr/lib/python3.6/site.py", line 282, in addusersitepackages
user_site = getusersitepackages()
File "/usr/lib/python3.6/site.py", line 258, in getusersitepackages
user_base = getuserbase() # this will also set USER_BASE
File "/usr/lib/python3.6/site.py", line 248, in getuserbase
USER_BASE = get_config_var('userbase')
File "/usr/lib/python3.6/sysconfig.py", line 601, in get_config_var
return get_config_vars().get(name)
File "/usr/lib/python3.6/sysconfig.py", line 558, in get_config_vars
_CONFIG_VARS['userbase'] = _getuserbase()
File "/usr/lib/python3.6/sysconfig.py", line 205, in _getuserbase
return joinuser("~", ".local")
File "/usr/lib/python3.6/sysconfig.py", line 184, in joinuser
return os.path.expanduser(os.path.join(*args))
File "/usr/lib/python3.6/posixpath.py", line 247, in expanduser
userhome = pwd.getpwuid(os.getuid()).pw_dir
KeyError: 'getpwuid(): uid not found: 60002'
Exited with error status 1
I did that operations:
cd`isolate --box-id 3 --init`/box
cat > a.py
#!/bin/pythonprint ("asdf")
chmod +x a.py
isolate --box-id 3 --run -- ./a.py
The text was updated successfully, but these errors were encountered:
Your installation of Python requires the current user to have an entry
in /etc/passwd corresponding to his UID.
Your Isolate runs under UID 60002 and there is either no passwd file
inside the sandbox at all, or there is one which does not contain
this UID.
I fail to find any reason why this error should be fatal, so please
consider filing a bug report for your Python package.
As a work-around, you can add a proper passwd file in your sandbox.
There are two easy possibilities:
(1) Create it as etc/passwd in your box directory (that is, the one
printed by `isolate --init`).
(2) Add an entry to your system-wide /etc/passwd and use the `--dir`
option to bind /etc in the sandbox.
When I run Python code with isolate, I receive this error:
Failed to import the site module Traceback (most recent call last): File "/usr/lib/python3.6/site.py", line 544, in <module> main() File "/usr/lib/python3.6/site.py", line 530, in main known_paths = addusersitepackages(known_paths) File "/usr/lib/python3.6/site.py", line 282, in addusersitepackages user_site = getusersitepackages() File "/usr/lib/python3.6/site.py", line 258, in getusersitepackages user_base = getuserbase() # this will also set USER_BASE File "/usr/lib/python3.6/site.py", line 248, in getuserbase USER_BASE = get_config_var('userbase') File "/usr/lib/python3.6/sysconfig.py", line 601, in get_config_var return get_config_vars().get(name) File "/usr/lib/python3.6/sysconfig.py", line 558, in get_config_vars _CONFIG_VARS['userbase'] = _getuserbase() File "/usr/lib/python3.6/sysconfig.py", line 205, in _getuserbase return joinuser("~", ".local") File "/usr/lib/python3.6/sysconfig.py", line 184, in joinuser return os.path.expanduser(os.path.join(*args)) File "/usr/lib/python3.6/posixpath.py", line 247, in expanduser userhome = pwd.getpwuid(os.getuid()).pw_dir KeyError: 'getpwuid(): uid not found: 60002' Exited with error status 1
I did that operations:
The text was updated successfully, but these errors were encountered: