SteveDoyle2 / pyNastran

A Python-based interface tool for Nastran's file formats
Other
385 stars 148 forks source link

pyNastran on conda-forge #708

Closed stephinity closed 1 year ago

stephinity commented 1 year ago

Hi Steve,

In the installation instructions you warn about installations which mix pip & conda. pyNastran installation docs

It would be very convenient if such a helpful package like pyNastran would be hosted on conda-forge, so that users can do a pure conda installation. Do you have any intention on publishing it there, in addition to the PyPI repository?

If you are not against it, I would offer my help to do so. I am by no means an expert (i.e. have 0 prior experience) in generating "conda-forge recipes", but have read through the process and about the grayskull module, which in theory "easily" creates conda-forge recipes automatically for pure Python packages.

Please let me know what you think.

Also, is the dependency on cpylog (today not available on conda-forge) a blocking point?

Related links: https://github.com/conda-forge/staged-recipes https://github.com/conda-incubator/grayskull

SteveDoyle2 commented 1 year ago

I don't see the advantage conda-fore offers over just PyPi. PyPI works with Anaconda.

You just have to know how to use it (i.e., don't use pip for binary packages when you're using conda). PyNastran isn't a binary package, so I see it as a non-issue. Same thing goes for cpylog.

stephinity commented 1 year ago

(sorry for the delay - I got swamped with work...)

The main advantage (for me) would be the convenience of having the entire installation use the conda install, which has some nice additional features. It is not a must have, as the pip install also works.

For background: I am trying to collect the most-used packages for my team, to offer an (air-gapped) installation. During a conda install, it copies the .tar.bz files for each package into a /.conda/pgks/ directory. This lets me in one shot get all the source files I need, and then store them locally for the internal installation. I tested downloading the pyNastran-1.3.4.tar.gz, and installing it with pip install ./pyNastran-1.3.4.tar.gz and this works fine. I will try to do the same for cpylog & docopt-ng.

And just for info: conda-forge offers are more open licensing than the anaconda repo, which became a blocking point for me in a enterprise setting. PyPI is no problem either.

SteveDoyle2 commented 1 year ago

I'm very confused. You're using Anaconda which has licensing issues. Stock Python doesn't have those issues.

You're also on an air-gapped system, so don't you have to manually install each package separately anyways? Why not just download the *.whl, which works well as long as you don't have binaries? How does putting pyNastran on conda-forge solve a problem?

I strongly recommend against using Anaconda. I used to use Anaconda for 6 years because Python hadn't created *.whl files and Anaconda solved the Windows binary problem first (and worse). It may have gotten better since I bailed on it, but the issues seemed very fundamental. I had major issues with it downgrading my version of python and making an exe that was 5x the size of an exe built using stock python.

stephinity commented 1 year ago

Sorry for mixing up the terminology and making things confusing!

In the end, using pip install with the .tar.gz file copied locally on the machine worked for me. Thanks again for the support.