简体   繁体   中英

ModuleNotFoundError: No module named 'setuptools._distutils'

I am getting the exception when I am installing the below package in python.

pip install django_microsoft_auth

Exception

ModuleNotFoundError: No module named 'setuptools._distutils'

What is the problem here?

I have resolved it with the below option.

Linux

export SETUPTOOLS_USE_DISTUTILS=stdlib

Windows

set SETUPTOOLS_USE_DISTUTILS=stdlib

After that, I have executed the pip install command.

pip install django_microsoft_auth

This is the bug in setuptools. See ModuleNotFoundError: No module named 'setuptools._distutils' #2353 .

sudo apt-get install -y python3-distutils

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM