Autodesk / Autodesk/notebook-molecular-visualization
Unable to use on Ubuntu
- Dominant language
- Python
- Stars
- 88
- Forks
- 21
- PR merge metrics
- No merged PRs in 30d
Description
When installing via pip, there is an error saying that it cannot import `utils`, e.g. `from nbmolviz import utils`. When I install from source, I get this error:
```
---------------------------------------------------------------------------
ImportError Traceback (most recent call last)
in ()
----> 1 import nbmolviz
2 import pybel
3 benzene = pybel.read_string('smi','c1cccc1').next()
4 nbmolviz.visualize(benzene)
/home/herman/repos/universe/notebook-molecular-visualization/nbmolviz/__init__.py in ()
16
17 from nbmolviz import utils
---> 18 from nbmolviz import base_widget, widget3d, interfaces3d, drivers3d, widget2d
19
20 # package metadata
/home/herman/repos/universe/notebook-molecular-visualization/nbmolviz/drivers3d.py in ()
16 from traitlets import Bool, Dict, Float, List, Set, Unicode
17
---> 18 from moldesign import units as u
19
20 from nbmolviz.utils import JSObject, translate_color
/usr/local/lib/python2.7/dist-packages/moldesign/__init__.pyc in ()
26 from . import utils
27 from . import units
---> 28 from . import uibase
29 from . import widgets
30
/usr/local/lib/python2.7/dist-packages/moldesign/uibase/__init__.py in ()
4 __all__ = []
5
----> 6 from .selector import *
7 from .components import *
8 from .plotting import *
/usr/local/lib/python2.7/dist-packages/moldesign/uibase/selector.py in ()
16
17 import moldesign as mdt
---> 18 from moldesign import utils, viewer
19
20
/usr/local/lib/python2.7/dist-packages/moldesign/viewer/__init__.py in ()
6 from .common import *
7 from .viewer2d import *
----> 8 from .viewer3d import *
9 from .bondclicker import *
/usr/local/lib/python2.7/dist-packages/moldesign/viewer/viewer3d.py in ()
21 from moldesign import utils
22 from moldesign.helpers import VolumetricGrid, colormap
---> 23 from nbmolviz.drivers3d import MolViz_3DMol
24 from . import toplevel, ColorMixin
25
ImportError: cannot import name MolViz_3DMol
```
I have a slightly messed up environment with previous attempts using conda to install `chemview` and `nglview`. But AFAIK there is nothing that could affect this. I'm running Ubuntu 16.04
Contributor guide
Research direction
Start with nbmolviz/__init__.py and drivers3d.py, then follow the moldesign import chain shown in the traceback. Reproduce the pip and source installations in the reported Ubuntu environment and inspect the package dependencies and import cycle. Done means a clean installation can import nbmolviz without the reported utils or MolViz_3DMol errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- jupyter, python
- Domain
- build-system, developer-experience
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100