Skip to content
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

wasmer run corrupts package on the second run on the hackathon branch #3510

Closed
fschutt opened this issue Jan 20, 2023 · 1 comment · Fixed by #3512
Closed

wasmer run corrupts package on the second run on the hackathon branch #3510

fschutt opened this issue Jan 20, 2023 · 1 comment · Fixed by #3512

Comments

@fschutt
Copy link
Contributor

fschutt commented Jan 20, 2023

In order to reproduce this bug, you need to checkout the hackathon branch, which has some changes of WASIX merged.

$ git checkout hackathon

$ make build-wasmer

$ ./target/release/wasmer run ciuser/customlambda 55
139583862445                                                           

$ ./target/release/wasmer run ciuser/customlambda 55
Fatal Python error: Py_Initialize: Unable to get the locale encoding
Traceback (most recent call last):
  File "lib/python3.6/encodings/__init__.py", line 31, in <module>
  File "<frozen importlib._bootstrap>", line 971, in _find_and_load
  File "<frozen importlib._bootstrap>", line 955, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 665, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 674, in exec_module
  File "<frozen importlib._bootstrap_external>", line 779, in get_code
  File "<frozen importlib._bootstrap_external>", line 487, in _compile_bytecode
EOFError: marshal data too short
error: failed to run `/Users/fs/.wasmer/checkouts/68747470733a2f2f7761706d2e696f2f6369757365722f637573746f6d6c616d626461@0.1.0/atoms/self::[email protected]:python`
│   1: RuntimeError: unreachable
╰─▶ 2: unreachable

$ ./target/release/wasmer -vV    
wasmer 3.1.0 (799ec 2023-01-20)
binary: wasmer-cli
commit-hash: 799ecbab394627594944e86196414b2347b7d2e6
commit-date: 2023-01-20
host: aarch64-apple-darwin
compiler: singlepass,cranelift

In the hackathon I could work around this bug by clearing the ~/.wasmer/checkouts directory before every run, but obviously this is not a long-term solution.

I am not sure if this is fixed in master because of #3509 - I can't really test it.

@fschutt
Copy link
Contributor Author

fschutt commented Jan 20, 2023

This bug also appears on master:

./target/release/wasmer run ciuser/customlambda --disable-cache 55
Fatal Python error: Py_Initialize: Unable to get the locale encoding
Traceback (most recent call last):
  File "lib/python3.6/encodings/__init__.py", line 31, in <module>
  File "<frozen importlib._bootstrap>", line 971, in _find_and_load
  File "<frozen importlib._bootstrap>", line 955, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 665, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 674, in exec_module
  File "<frozen importlib._bootstrap_external>", line 779, in get_code
  File "<frozen importlib._bootstrap_external>", line 487, in _compile_bytecode
EOFError: marshal data too short
error: failed to run `/Users/fs/.wasmer/checkouts/68747470733a2f2f7761706d2e696f2f6369757365722f637573746f6d6c616d626461@0.1.0/atoms/self::[email protected]:python`
│   1: RuntimeError: unreachable
╰─▶ 2: unreachable

./target/release/wasmer -vV
wasmer 3.1.0 (580ba 2023-01-20)
binary: wasmer-cli
commit-hash: 580baeb5090ab825d082e4d5dbcafb9e880d3e06
commit-date: 2023-01-20
host: aarch64-apple-darwin
compiler: singlepass,cranelift

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

Successfully merging a pull request may close this issue.

2 participants