In order to get sandbox version of Pypy
, first i build Pypy
from source using this instruction:
pypy ../../rpython/bin/rpython -O2 --sandbox targetpypystandalone
(Then I rename Pypy-c
to Pypy-c-sandbox
)
When i test:
./pyinteractive.py
It works correctly but when i want to run sandbox version using this command:
./pyinteractive.py ../goal/pypy-c-sandbox
Following error appears:
[platform:execute] gcc -shared /tmp/usession-release-2.5.1-15/module_cache/module_0.o /tmp/usession-release-2.5.1-15/module_cache/module_1.o /tmp/usession-release-2.5.1-15/module_cache/module_2.o /tmp/usession-release-2.5.1-15/module_cache/module_3.o -pthread -Wl,--export-dynamic -lrt -o /tmp/usession-release-2.5.1-15/shared_cache/externmod.so
TypeError: compile() expected string without null bytes
What should I do to solve this issue?
You're misreading the docs: it's not pyinteractive.py path/to/pypy-sandbox
. It's pypy_interact.py path/to/pypy-sandbox
(from pypy/sandbox/).
The modules that work in the sandbox are in a very limited number. Recently even the time
module stopped working there, so was removed. We'd welcome contributions, but more of the kind "continued support", which would include special support for more modules and a better pypy_interact.py
--- the present one is only there for demo purposes.