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

Prevent pip-compile showing absolute constraint paths #2196

Closed
wants to merge 1 commit into from

Conversation

rebkwok
Copy link
Contributor

@rebkwok rebkwok commented Oct 29, 2024

If the --constraints path is included in a requirements..in file, the absolute path is shown in the comments in the requirements..txt output. This appears to be related to a pip upgrade. Specifying the --constraints path as a command line arg instead results in the expected relative paths.

We can likely change back when this issue is addressed: jazzband/pip-tools#2131

If the --constraints path is included in a requirements.*.in file,
the absolute path is shown in the comments in the requirements.*.txt
output. This appears to be related to a pip upgrade. Specifying the
--constraints path as a command line arg instead results in the
expected relative paths.

We can likely change back when this issue is addressed:
jazzband/pip-tools#2131
Copy link

Deploying databuilder-docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: 26ed519
Status: ✅  Deploy successful!
Preview URL: https://e466e86e.databuilder.pages.dev
Branch Preview URL: https://compile-reqs.databuilder.pages.dev

View logs

Copy link
Member

@bloodearnest bloodearnest left a comment

Choose a reason for hiding this comment

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

Have approved, but I am not 100% sure this change is worth it or not.

Having the absolute path is not great, but it's not really a big problem, and as you point out, will probably be fixed.

However, I think including the constraints in the .txt is cleaner than having to pass them.

But then again, we may switch to uv soonish, which will make this all moot.

@rebkwok
Copy link
Contributor Author

rebkwok commented Oct 29, 2024

@bloodearnest Yeah, on second thoughts I'm not sure if it's worth it either. Shall we just leave it with the absolute paths and assume it'll go back to the way it was at some point? Also means if you run just pip-compile on its own, you need to remember to pass the constraints path

Also no idea why coverage has decided that a line is no longer covered on this PR

@rebkwok rebkwok closed this Oct 29, 2024
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