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

fix(docker): Switch to pip install and remove repoze-lru workaround #3281

Merged
merged 1 commit into from
Jan 24, 2025

Conversation

hneiva
Copy link
Contributor

@hneiva hneiva commented Jan 23, 2025

  • Replaces python setup.py install with pip install in the Docker image
  • Removes the hard-coded repoze.lru (- to .) workaround in pin-helper

The issue arose because pip-compile switches . to - when following PEP-0503 package name normalization rules. While pip seamlessly handles the aliased name (installing the package with .), setuptools does not manage the mismatch well. By moving to pip install, we avoid the naming conflict entirely and prevent future mishaps.

- Replaces `python setup.py install` with `pip install` in the Docker image
- Removes the hard-coded `repoze.lru` (`-` to `.`) workaround in `pin-helper`

The issue arose because `pip-compile` switches `.` to `-` when following [PEP-0503](https://peps.python.org/pep-0503/#normalized-names) package name normalization rules. While `pip` seamlessly handles the aliased name (installing the package with `.`), `setuptools` does not manage the mismatch well. By moving to `pip install`, we avoid the naming conflict entirely and prevent future mishaps.
Copy link
Contributor

@bhearsum bhearsum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent sleuthing! Thank you for fixing the root cause!

@hneiva hneiva merged commit 19dbbfb into main Jan 24, 2025
9 checks passed
@hneiva hneiva deleted the hneiva/fix-backend-docker branch January 24, 2025 05:03
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

Successfully merging this pull request may close these issues.

2 participants