Home

Awesome

rustafarian

Musings with Rust and Python with PyO3

How to work with this repo

There currently is some redundancy when it comes to specifying dependencies. This originates from a number of factors:

  1. Rust and Python have different ways of managing dependencies.
  2. I use Nix to ensure I have reproducible development environments. This clashes massively with Python dependency management.
  3. We also want to make this usable when Conda orchestrates the Python environment.

In addition:

In a real-world repository shell.nix and .envrc would not be checked in, but rather tracked in a "stash branch" using git-along

pipenv install --dev . installs the project and its development dependencies. This is an editable install and puts the scripts (entry points) in the right places.

maturin develop builds the Rust extension. Needs to be done to actually get python -c "import rustafarian" to work without problem from the root of the project.

I guess if one has tests for the scripts pipenv install --dev and maturin develop might be enough?

Copyright

Copyright (c) 2018, Charles J. C. Scott, Roberto Di Remigio Licensed under MPL v2.0.