Skip to content

On parallel builds #325

Description

@agriyakhetarpal

The xbuildenv symlink is rewritten on each pyodide xbuildenv install call. If multiple builds for different Pyodide versions run concurrently (e.g. in cibuildwheel, when running the test suite in parallel), re-resolving through the symlink at a later point could yield the wrong versioned directory. Using self.pyodide_root, which was resolved at construction time, gives us a stable, race-free path.

Thanks for the investigation. Actually, I guess this is something that we need to think more carefully about, not just for emscripten but for other config variables as well. I personally never considered concurrent builds when designing xbuildenv installation. If cibuildwheel is using parallel builds a lot, we should be make pyodide-build more concurrent-robust.

Originally posted by @ryanking13 in #321 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions