Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

module 'importlib._bootstrap' has no attribute '_w_long'

Tags:

python

pip

django

I am trying to install django-adim-tools using pip, but this is what happens:

C:\Users\hugo.villalobos>pip install django-admin-tools
Could not import runpy module
Traceback (most recent call last):
  File "C:\Python34\Lib\runpy.py", line 14, in <module>
    import importlib.machinery # importlib first so we can test #15386 via -m
  File "C:\Python34\Lib\importlib\__init__.py", line 34, in <module>
    _w_long = _bootstrap._w_long
AttributeError: module 'importlib._bootstrap' has no attribute '_w_long'

I have no idea how to proceed to solve it.

like image 536
HuLu ViCa Avatar asked Oct 01 '17 05:10

HuLu ViCa


1 Answers

In my case, I have multiple Python (3.7, 3.6, 3.4) installed in my PC. The environment var $PATH and $PYTHONPATH is pointing to different version's. After resetting these 2 environment vars correctly everything runs correctly then.

like image 142
JackieLam Avatar answered Nov 13 '22 07:11

JackieLam