Skip to content

Upstream issues for wasm32-emscripten support: instant library and emscripten_get_now #2417

Description

@hoodmane

There is a dependency chain pyo3 ==> parking-lot ==> instant. On wasm32-emscripten, instant tries to use _emscripten_get_now which is misspelled: it should be emscripten_get_now.

Issue: sebcrozet/instant#35
PR: sebcrozet/instant#47

It is possible to work around this via JavaScript: on the Emscripten module one can set Module.__emscripten_get_now = Module._emscripten_get_now and it will work.

There is a second bug related to emscripten_get_now in Emscripten: emscipten_get_now has no signature so it won't work if you dynamically link the PyO3 module. This is now fixed upstream.
emscripten-core/emscripten#17123
There is also a JavaScript workaround for this:
Module._emscripten_get_now.sig = "d"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions