1

PyPy を実行するプロセスを作成したいと思います。私は次のことを試しましたが、うまくいきます:

import os
os.chdir('<path-to-pypy-download>/bin/')
os.execl('pypy', 'pypy', '-c', 'print "Hi!"')

ただし、 as を削除するchdirと:

import os
os.execl('<path-to-pypy-download>/bin/pypy', 'pypy', '-c', 'print "Hi!"')

私は得る:

debug: WARNING: Library path not found, using compiled-in sys.path.
debug: WARNING: 'sys.prefix' will not be set.
debug: WARNING: Make sure the pypy binary is kept inside its tree of files.
debug: WARNING: It is ok to create a symlink to it from somewhere else.
debug: OperationError:
debug:  operror-type: ImportError
debug:  operror-value: No module named os

作業ディレクトリを変更せずに PyPy プロセスを生成する方法を知っている人はいますか?

4

1 に答える 1