Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Module Not found error: ModuleNotFoundError: No module named 'distutils' #1742

Open
MajesticMinhaz opened this issue Feb 15, 2024 · 2 comments

Comments

@MajesticMinhaz
Copy link

My code

# create the driver instance
options = ChromeOptions()
options.add_argument("--headless")
driver = Chrome(options=options, driver_executable_path=config.get('DRIVER_PATH'), use_subprocess=False)
# driver = Chrome(options=options, driver_executable_path=config.get('DRIVER_PATH'))
driver.get(config.get("www.example.com"))

Error

Traceback (most recent call last):
  File "C:\Users\MD. MINHAZ\PycharmProjects\LinkedInProfileScraper\linkedin_profile_scraper.py", line 4, in <module>
    from undetected_chromedriver import Chrome, ChromeOptions
  File "C:\Users\MD. MINHAZ\PycharmProjects\LinkedInProfileScraper\.venv\Lib\site-packages\undetected_chromedriver\__init__.py", line 44, in <module>
    from .patcher import IS_POSIX
  File "C:\Users\MD. MINHAZ\PycharmProjects\LinkedInProfileScraper\.venv\Lib\site-packages\undetected_chromedriver\patcher.py", line 4, in <module>
    from distutils.version import LooseVersion
ModuleNotFoundError: No module named 'distutils'
@L0garithmic
Copy link

This can be fixed by installing setuptools

pip install --upgrade setuptools

However distutils was deprecated in Python 3.10 so this function should be updated or removed

@rookiexun
Copy link

This can be fixed by installing setuptools

pip install --upgrade setuptools

However distutils was deprecated in Python 3.10 so this function should be updated or removed

great ! thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants