schrodinger / pymol-open-source

Open-source foundation of the user-sponsored PyMOL molecular visualization system.
https://pymol.org/
Other
1.2k stars 281 forks source link

Import Error (chempy): conflict with chempy from pip #245

Open jfmoulin opened 2 years ago

jfmoulin commented 2 years ago

Hello, upon importing pymol, I get an ImportError related to chempy

import pymol
ImportError: cannot import name 'io' from 'chempy'

I installed pymol from latest git, Importantly, I have (and need) a chempy package installed via pip on my system
I realized that pymol actually has an own chempy module.... Not quite sure how I can solve the conflict though, I cannot find chempy.py in my pymol installation

cgohlke commented 2 years ago

Duplicate of #100.

JarrettSJohnson commented 2 years ago

As mentioned above, the naming was unlucky, but we (maintainers) should have standardized this package a while ago through proper channels if we wanted this to be somewhat independent of PyMOL. I think the proper way would be for us to not have this installed directly in site-packages and perhaps namespace or rename this completely. This change will unfortunately break a lot of older scripts out there that call on PyMOL's chempy directly but probably good for long run since I do consider PyPi to be an authority for packages. This is something we'll consider when we transition to PyMOL 3.0.