You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed this while setting up a virtual environment using matplotlib 1.4.0 to test #18190. __version__ sometimes returns a string and other times returns a unicode object in Python 2.7. When returning unicode, the comparisons that occur in plotting/_compat.py will raise
In some cases, the versions are converted to str objects in plotting/_compat.py to presumably avoid this error, but it is not done consistently. As perhaps a better approach, we could create LooseVersion objects from all the __version__ properties so that the comparison is done between equal types across the board.
Python 2.7.14 | packaged by conda-forge | (default, Nov 4 2017, 10:22:41)
[GCC 4.2.1 Compatible Apple LLVM 6.1.0 (clang-602.0.53)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
I've seen this error when a library imports unicode_literals.
As perhaps a better approach, we could create LooseVersion objects from all the version properties so that the comparison is done between equal types across the board.
I noticed this while setting up a virtual environment using matplotlib 1.4.0 to test #18190.
__version__
sometimes returns a string and other times returns a unicode object in Python 2.7. When returning unicode, the comparisons that occur inplotting/_compat.py
will raiseIn some cases, the versions are converted to
str
objects inplotting/_compat.py
to presumably avoid this error, but it is not done consistently. As perhaps a better approach, we could createLooseVersion
objects from all the__version__
properties so that the comparison is done between equal types across the board.Output of
pd.show_versions()
Python 2.7.14 | packaged by conda-forge | (default, Nov 4 2017, 10:22:41)
[GCC 4.2.1 Compatible Apple LLVM 6.1.0 (clang-602.0.53)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
INSTALLED VERSIONS
commit: 2c903d5
python: 2.7.14.final.0
python-bits: 64
OS: Darwin
OS-release: 17.2.0
machine: x86_64
processor: i386
byteorder: little
LC_ALL: None
LANG: en_US.UTF-8
LOCALE: None.None
pandas: 0.22.0.dev0+283.g2c903d594.dirty
pytest: 3.3.0
pip: 9.0.1
setuptools: 38.2.3
Cython: 0.27.3
numpy: 1.9.3
scipy: None
pyarrow: None
xarray: None
IPython: None
sphinx: None
patsy: None
dateutil: 2.6.1
pytz: 2017.3
blosc: None
bottleneck: None
tables: None
numexpr: None
feather: None
matplotlib: 1.4.0
openpyxl: None
xlrd: None
xlwt: None
xlsxwriter: None
lxml: None
bs4: None
html5lib: None
sqlalchemy: None
pymysql: None
psycopg2: None
jinja2: None
s3fs: None
fastparquet: None
pandas_gbq: None
pandas_datareader: None
The text was updated successfully, but these errors were encountered: