openforcefield / openff-utilities

A collection of miscellaneous utility functions used throughout the OpenFF stack
MIT License
0 stars 2 forks source link

Pixi Support #87

Open sbtq opened 2 days ago

sbtq commented 2 days ago

With the emergence of pixi (https://pixi.sh) - a new package manager to be an improvement over conda - the openff toolkit does not work anymore because the toolkit has issues to find a conda executable.

You get the following error when trying to import anything openff.utilities.exceptions.CondaExecutableNotFoundError.

This is due to the logic in https://github.com/openforcefield/openff-utilities/blob/main/openff/utilities/provenance.py. Would you be fine with expanding this functionality to also check if pixi is there?

Any reasons to not support pixi?

If you want me to submit a PR please tell me, would be happy to contribute :)

mattwthompson commented 2 days ago

I agree pixi support there would be great, I keep hearing good things about it - the reason it's not there is that I haven't tried it for myself yet. We'd be happy to take a PR that expands that logic block out to handle it. It'd give me a good excuse to try it out!

sbtq commented 2 days ago

okay @mattwthompson, sounds good. I have seen that the ordering for those executables is important based on the comments and an issue I have seen regarding that.

Would there be anything speaking against using pixi as the first if found?

Will create the PR probably tomorrow then.

mattwthompson commented 2 days ago

I'd prefer it be tried third, since our installation recommendations mamba and our developer base uses micromamba. If there's a performance issue, we can look into caching or some shortcuts - happy to iterate on it.

sbtq commented 1 day ago

@mattwthompson according to my tests, the changes in the referenced PR should do the trick. Performance was also completely fine. I could not find an particular automated tests for this part of the code. WDYT?

mattwthompson commented 1 day ago

Thanks - will move discussion about the changes to the PR