Skip to content

Commit b207e32

Browse files
committed
made conditionals for imports
1 parent 8ae2d84 commit b207e32

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

plotly/widgets/graph_widget.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,19 +9,19 @@
99

1010

1111
# TODO: protected imports?
12-
import Ipython
12+
import IPython
1313
from IPython.display import Javascript, display
1414

1515
import plotly.plotly.plotly as py
1616
from plotly import utils, tools
1717
from plotly.graph_objs import Figure
1818

19-
if Ipython.version_info[0] > 3:
19+
if IPython.version_info[0] > 3:
2020
import ipywidgets as widgets
2121
from traitlets import Unicode
2222
else:
23-
import IPython.widgets as widgets
24-
from IPython.trailets import Unicode
23+
from IPython.html import widgets
24+
from IPython.utils.traitlets import Unicode
2525

2626
# Load JS widget code
2727
# No officially recommended way to do this in any other way

0 commit comments

Comments
 (0)