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

Install setuptools via pip in base Docker image #20487

Merged
merged 1 commit into from
Dec 10, 2024

Conversation

lantiga
Copy link
Collaborator

@lantiga lantiga commented Dec 10, 2024

What does this PR do?

Module pkg_resources has been removed in Python 3.12, this produces

Traceback (most recent call last):
  File "/__w/13/s/requirements/collect_env_details.py", line 24, in <module>
    import pkg_resources
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2172, in <module>
    register_finder(pkgutil.ImpImporter, find_on_path)
                    ^^^^^^^^^^^^^^^^^^^
AttributeError: module 'pkgutil' has no attribute 'ImpImporter'. Did you mean: 'zipimporter'?

This PR manually installs setuptools via pip in the base Docker image, which now provides pkg_resources.
Moving forward we'll need to migrate away from it but not today.


📚 Documentation preview 📚: https://pytorch-lightning--20487.org.readthedocs.build/en/20487/

@github-actions github-actions bot added ci Continuous Integration dockers labels Dec 10, 2024
Copy link
Contributor

github-actions bot commented Dec 10, 2024

⚡ Required checks status: All passing 🟢

Groups summary

🟢 pytorch_lightning: Docker
Check ID Status
build-cuda (3.10, 2.1.2, 12.1.0) success
build-cuda (3.11, 2.2.2, 12.1.0) success
build-cuda (3.11, 2.3.1, 12.1.0) success
build-cuda (3.11, 2.4.1, 12.1.0) success
build-cuda (3.12, 2.5.1, 12.1.0) success
build-pl (3.10, 2.1, 12.1.0) success
build-pl (3.11, 2.2, 12.1.0) success
build-pl (3.11, 2.3, 12.1.0) success
build-pl (3.11, 2.4, 12.1.0) success
build-pl (3.12, 2.5, 12.1.0) success

These checks are required after the changes to dockers/base-cuda/Dockerfile.


Thank you for your contribution! 💜

Note
This comment is automatically generated and updates for 60 minutes every 180 seconds. If you have any other questions, contact carmocca for help.

@lantiga lantiga merged commit b709985 into master Dec 10, 2024
22 checks passed
@lantiga lantiga deleted the luca/fix-pkg-resources-docker-error branch December 10, 2024 14:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci Continuous Integration dockers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant