Skip to content

Improve mixed-version handling #796

Closed
@llchan

Description

@llchan

I upgraded pybind11 and rebuilt an extension, but there was another extension in an unrelated package/repo that was not rebuilt. When I imported both of them, the process segfaulted.

Can we add some runtime version checking to ensure that an newly imported module is compatible with any existing pybind11 version(s) that have already been loaded? It would be a better user experience to get an informative exception about mismatched versions rather than a segfault + gdb on a core file to figure out it's pybind11-related.

I'm not sure how strict we want to make the version checking, but this particular instance was 2.1.x vs 2.0.x, so minor versions arent compatible. Should we add an internal ABI version that evolves independent of the user-facing API version?

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