On 4/13/24 06:41, Fabio Valentini wrote:
On Sat, Apr 13, 2024 at 1:18 PM Zbigniew Jędrzejewski-Szmek
<zbyszek@in.waw.pl> wrote:
Yes. But actually I think Rust is the optimal choice here. Writing
this in Python would be possibly slightly nicer, but we don't want
to pull the interpreter and packages into the buildroot. Python
also has the problem (challenge?) that it needs to be bootstrapped
once per year. The less packages are involved in the bootstrap, the
easier it is. And if the brp was written in Python, we'd need to
deal with that, and it would probably increase the number of builds
which are done without the cleanup. Having this as an indepedent
binary avoids some of the issues with bootstrap.
I think Rust *would* be a good choice here ...
BUT add-determinism uses pyo3 to link to CPython, so it pulls in
python3-libs anyway.
So you get the downsides of pulling in Python without the upsides of
using Rust ...

Would it be possible to shell out to Python instead of using pyo3? I assume add-determinism's Python handler is not that complicated given that marshalparser does most of the work.