1

A script I'm running is failing at one of my imports, and I can't figure out why.

The offending line of code is:

from pandas.compat import lzip

Error message: ImportError: cannot import name 'lzip'

This script is being run in a conda virtual environment, with dependencies installed through conda. Specific to this case, I have pandas and pandas-compat installed, also through conda, and running on Python3.6. (3.6 because 3.7 is incompatible with pandas-compat in an earlier attempt on a python3.7 env)

Help please, or point to where I may find the solution?

Not sure why lzip wouldn't be available, save for the warning at the top of the pandas API reference docu (Warning The pandas.core, pandas.compat, and pandas.util top-level modules are PRIVATE. Stable functionality in such modules is not guaranteed.). The first solution on this page didn't work for me.

Current pandas version: 0.25.3

Current pandas-compat: 0.1.1

Current python: 3.6.7

StayOnTarget
  • 11,743
  • 10
  • 52
  • 81
Tea
  • 21
  • 6
  • It's OK for me: Python 3.6.6 (v3.6.6:4cf1f54eb7, Jun 27 2018, 03:37:03) [MSC v.1900 64 bit (AMD64)] Pandas: 0.23.4 – user4624500 Jan 03 '20 at 13:04

0 Answers0