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

Support imported functions #28

Closed
turbolent opened this issue May 3, 2019 · 9 comments · Fixed by #140
Closed

Support imported functions #28

turbolent opened this issue May 3, 2019 · 9 comments · Fixed by #140
Assignees
Labels
❓ question Further information is requested

Comments

@turbolent
Copy link

Does this library support importing Python functions into the WebAssembly module instances?

I couldn't find any example and looking at the code at https://github.com/wasmerio/python-ext-wasm/blob/89cecbbd672023f2b12ae183641fba2f9cc4c7e3/src/instance.rs#L133-L134 it seems like it is not supported yet?

@Hywan Hywan self-assigned this May 7, 2019
@Hywan Hywan added the ❓ question Further information is requested label May 7, 2019
@Hywan
Copy link
Contributor

Hywan commented May 7, 2019

Hi,

Not yet. We are working on it. The Wasmer runtime API, with its C and C++ bindings, support that but for statically typed languages. We have to make it compliant with dynamically typed languages.

@Hywan Hywan changed the title Imports Support imported functions May 7, 2019
@filips123
Copy link

@Hywan Is there any update? This is already supported in Go version of Wasmer library.

@Hywan
Copy link
Contributor

Hywan commented Oct 19, 2019

It's easier in Go than it is with Python. I'm working on it at the runtime-core level, see wasmerio/wasmer#882. It's a WIP.

@filips123
Copy link

filips123 commented Oct 20, 2019

@Hywan Great! When do you expect to be finished?

@Hywan
Copy link
Contributor

Hywan commented Oct 21, 2019

I can't specify any date :-).

@sffc
Copy link

sffc commented Nov 21, 2019

Would like to see this feature. I'm trying to port a Rust module compiled with wasm_bindgen to run on Python but am getting "Failed to instantiate the module" errors since there are no function imports available.

@Hywan
Copy link
Contributor

Hywan commented Dec 4, 2019

Yup, working on it :-).

@dholth
Copy link

dholth commented Apr 8, 2020

Still going?

I only thought I needed the emscripten grow memory hook, there may be an alternative solution...

@Hywan
Copy link
Contributor

Hywan commented Apr 9, 2020

Yes, #140 is under review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
❓ question Further information is requested
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants