Skip to content

Commit

Permalink
Fix builtin import in py3 (#3817)
Browse files Browse the repository at this point in the history
  • Loading branch information
philippjfr committed Jul 11, 2019
1 parent 8cf3e27 commit b4c631c
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions holoviews/core/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,10 @@
except:
from collections import OrderedDict

try:
import __builtin__ as builtins # noqa (compatibility)
except:
import builtins as builtins # noqa (compatibility)

# Python3 compatibility
if sys.version_info.major >= 3:
import builtins as builtins # noqa (compatibility)

basestring = str
unicode = str
long = int
Expand All @@ -40,6 +37,8 @@
get_keywords = operator.attrgetter('varkw')
LooseVersion = _LooseVersion
else:
import __builtin__ as builtins # noqa (compatibility)

basestring = basestring
unicode = unicode
from itertools import izip
Expand Down

0 comments on commit b4c631c

Please sign in to comment.