Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fa5937a commit 1dff056Copy full SHA for 1dff056
plotly/graph_objs/graph_objs_tools.py
@@ -4,8 +4,16 @@
4
import os
5
import sys
6
if sys.version[:3] == '2.6':
7
- from ordereddict import OrderedDict
8
- import simplejson as json
+ try:
+ from ordereddict import OrderedDict
9
+ import simplejson as json
10
+ except ImportError:
11
+ raise ImportError(
12
+ "Looks like you're running Python 2.6. Plotly expects newer "
13
+ "standard library versions of ordereddict and json. You can "
14
+ "simply upgrade with these 'extras' with the following terminal "
15
+ "command:\npip install 'plotly[PY2.6]'"
16
+ )
17
else:
18
from collections import OrderedDict
19
import json
0 commit comments