Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Emscripten build with NODERAWFS=1 #36

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

Closed
thomasballinger opened this issue Dec 11, 2021 · 2 comments
Closed

Emscripten build with NODERAWFS=1 #36

thomasballinger opened this issue Dec 11, 2021 · 2 comments

Comments

@thomasballinger
Copy link

thomasballinger commented Dec 11, 2021

It might be helpful for tests? being in a more familiar environment? to do an emscripten build that uses the native filesystem, which is possible with NODERAWFS replacing the Emscripten in-memory filesystem. This would get us close to something like node python.js script.py.

FIle permissions don't quite work the same There are some limitations to going through this layer, but it's pretty seamless for the filesystem access that node does provide. This might let folks install the emscripten-compiled version of Python alongside other python builds like pypy.

WASI support seems strategically more important, but this could be a useful foothold.

@emmatyping
Copy link
Owner

Yeah more broadly we should try building with Emscripten targeting node as that will be easier to test

emmatyping added a commit to emmatyping/cpython that referenced this issue Jan 9, 2022
This adds a "python.js" target to the Makefile. We enable the raw
node fs mode as suggested by @thomasballinger as it will make running
the test suite under node easier, c.f.
emmatyping/python-wasm#36.

The wasm_asset.py script is updated to include the test module. Care is
taken to skip compiling the Python files that are examples of bad syntax
or encoding.

This also turns on memory growth as early into the test suite I was
running into OOMs.
@emmatyping
Copy link
Owner

Fixed in python/cpython#30552

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

No branches or pull requests

2 participants