Skip to content

Migrate the Hypothesis engine from Python to Rust #4740

@Liam-DeVoe

Description

@Liam-DeVoe

This epic-style issue tracks our work towards migrating the core Hypothesis engine from Python to Rust.

We expect this to both bring better performance, and allow us to expose Hypothesis as a shared backend for PBT in other languages, for example for use by Hegel.

This change should not otherwise be user-visible in any way. We are treating this as a minor, not a major, version bump.

Background

As a small bit of background: we have long toyed with the idea of porting the Hypothesis engine to Rust. Some things have changed since then: the Rust<->Python ecosystem (e.g.) has matured, and Hegel, which @DRMacIver and I work on, would benefit substantially from native bindings into Hypothesis, so we can bring the power of Hypothesis and PBT to every language. And of course, no Python user of Hypothesis will complain about a speedup!

We think now is the right time to complete a migration of the core of Hypothesis into Rust. Many parts of Hypothesis—for example, those that interface with the user—will remain in Python.

Roadmap

  • Ship a version of Hypothesis with a trivial amount of Rust code.
    • This lets us get the build infrastructure and deployment story right, before moving on to any of the actual work.
  • ??? (will fill in as we get a more clear idea of the work to be done)

Metadata

Metadata

Assignees

No one assigned

    Labels

    internalsStuff that only Hypothesis devs should ever see

    Type

    No type
    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