pip install et_xmlfile failure

0

Brand new python installation

-Python 3.7.3 (v3.7.3:ef4ec6ed12, Mar 25 2019, 22:22:05) [MSC v.1916 64 bit (AMD64)] on win32
-pip 19.1

I tried to install Openpyxl that relies on Et_xmlfile that pip fails to install:

>pip install openpyxl
Collecting openpyxl
  Using cached https://files.pythonhosted.org/packages/ba/06/b899c8867518df19e242d8cbc82d4ba210f5ffbeebb7704c695e687ab59c/openpyxl-2.6.2.tar.gz
Collecting jdcal (from openpyxl)
  Using cached https://files.pythonhosted.org/packages/f0/da/572cbc0bc582390480bbd7c4e93d14dc46079778ed915b505dc494b37c57/jdcal-1.4.1-py2.py3-none-any.whl
Collecting et_xmlfile (from openpyxl)
  Using cached https://files.pythonhosted.org/packages/22/28/a99c42aea746e18382ad9fb36f64c1c1f04216f41797f2f0fa567da11388/et_xmlfile-1.0.1.tar.gz
    ERROR: Complete output from command python setup.py egg_info:
    ERROR: Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "C:\Users\...\AppData\Local\Temp\pip-install-tgfkoxzc\et-xmlfile\setup.py", line 40, in <module>
        from et_xmlfile import (
    ModuleNotFoundError: No module named 'et_xmlfile'
    ----------------------------------------
ERROR: Command "python setup.py egg_info" failed with error code 1 in C:\Users\...\AppData\Local\Temp\pip-install-tgfkoxzc\et-xmlfile\

Any ideas?

Silas M

Posted 2019-05-03T18:42:07.690

Reputation: 1

Answers

0

I ran into same problem with embedded Python 3.8.1. I extracted et_xmlfile-1.0.1.tar.gz and tried running

python3 setup.py install 

but it failed as you described:

No module named 'et_xmlfile'

It seems sys.path didn't contain current directory, so I added a line into setup.py, just before et_xmlfile import:

# new line:
sys.path.insert(0, here)

from et_xmlfile import (

I then repackaged the dir as tar.gz:

tar -czvf et_xmlfile-1.0.1.tar.gz et_xmlfile-1.0.1

And installed with pip, now with success.

Ilkka Kiistala

Posted 2019-05-03T18:42:07.690

Reputation: 1