Openbabel package name conflict
When installing "PLIP" via pip, the "openbabel" version mentioned in the requirements and to be installed shows a conflict. Given requirements shows a version of "~=3.0.0", but while installation shows it shows version " ==3.1.1.1" which never got released.
Expected solution changing the openbabel version to "==3.1.1".
**** Errors occurred ****
- pip install plip
Collecting openbabel Using cached openbabel-3.1.1.1.tar.gz (82 kB) Preparing metadata (setup.py) ... done ....... ...... ... Building wheels for collected packages: openbabel Building wheel for openbabel (setup.py) ... error error: subprocess-exited-with-error
× python setup.py bdist_wheel did not run successfully. │ exit code: 1 ╰─> [15 lines of output] running bdist_wheel running build running build_ext Warning: invalid version number '3.1.1.1'.
- pip install plip "openbabel ==3.1.1"
ERROR: Could not find a version that satisfies the requirement openbabel==3.1.1 (from versions: 1.8, 1.8.1, 1.8.2, 1.8.4, 2.4.0, 2.4.1, 3.1.1.1) ERROR: No matching distribution found for openbabel==3.1.1
I spent 2 hours on this problem and it turned out to be a publishing error with openbabel. In fact, openbabel can be installed correctly using pip install openbabel-wheel, but plip still cannot be installed correctly. My guess is that pip install openbabel is still used when installing dependencies. Now please let us pray that PLIP developers or openbabel developers fix these issues
Since there are different ways to install OpenBabel, such as as part of a distribution, as a Conda package, built locally, installed as a Python wheel, or via Homebrew, and so on, Plip I think should remove its hard dependency on OpenBabel and document that (already done).
Additionally, the Python code of Plip can provide an error message if OpenBabel bindings are not found and suggest one of the ways to install it. This approach is taken by some R libraries for example.
While having a hardcoded dependency on OpenBabel wheel may work for many users, it does not provide the option to use an existing installation of OpenBabel. Also it may be best to wait until the wheel is provided by the official OpenBabel distribution.
For more details about broken vers 3.1.1.1 see this issue: https://github.com/openbabel/openbabel/issues/2408
New release 2.4.0 is supposed to partially solve the issue with OpenBabel installation. There are still many different ways to install Python packages, also, the current setup is considered legacy and needs to be updated.
In order to force the building of the fixed OpenBabel module, one would need to run pip install --no-binary :all: plip otherwise, the binary wheel distribution will be pulled first, and OpenBabel bindings will not be built.
Hey all, I opened a PR to modernize the setup, essentially to address this
the current setup is considered legacy and needs to be updated.
https://github.com/pharmai/plip/pull/182
there, I specified openbabel as an optional dependency, so that users can choose to install openbabel-wheel instead if they want.