-
Notifications
You must be signed in to change notification settings - Fork 9
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
Add support for all stacks #522
Comments
Thanks @jpena-r7 - I'm in favor of supporting all stacks across the python buildpack. I am slightly confused as to why we need to switch from It sounds like the proposal to switch to |
You are correct that fixing pip should also resolve the issue for poetry. While the proposed switch to I expect that you would need to update the shebang after the dependency is created or ensure that the dependency is built inside a similar layer directory structure to what will be created in the end. I was trying to avoid changes to the dependency creation process and find a universal solution to the problem, which is why I proposed switching to Let me know which direction you would like to go and I can create an issue for the pip buildpack. |
Sure that makes sense. I'm happy with I see some examples around (e.g. here and here) suggesting that So I'm fairly convinced that this is a reasonable change to make. If you prefer to use |
Excellent! One thing that will need to happen before I can create PRs is that a new release of cpython is needed because pip, pipenv, and poetry all rely on it for integration tests. Once that is in place should I create PRs and post them here for review? |
I just released cpython v1.4.0 so you should be unblocked on that front. Yeah, I think creating PRs in each repo and referencing this tracking issue is probably the best way to proceed. That way they are all easily discoverable and reference the same conversation here. |
The following PRs were created. Both will need to be merged and released before the remaining buildpacks can be updated. |
The remaining PRs have been created.
Once these have been merged and released this issue can be closed out. |
All buildpacks above have been released with support for |
With the release of the Python Buildpack v.2.2.0 this issue can be closed! Thanks for all the PRs, @jpena-r7 🎉 |
Describe the Enhancement
I would like to propose making the
python
buildpack support all stacks similar to thejava
buildpack.The groundwork for this change has already been laid by the PR to the
cpython
buildpack implemented here. This allows python to be installed from source on non-paketo stacks.With the
cpython
buildpack updated, the remaining buildpacks are:pip
,pipenv
,poetry
,miniconda
, andconda-env-update
Possible Solution
For all buildpacks the primary change needed is to update stack definitions in the
buildpack.toml
file as show below. Other changes are noted below. Of course unit and integration tests will be updated accordingly as needed.See below docker hub images and READMEs on how all of these proposed changes were tested before this issue was proposed.
The
pip
buildpack needs to be updated first beforepipenv
andpoetry
because they depend onpip
.The
miniconda
buildpack needs to be updated first beforeconda-env-update
because it depends onminiconda
.pip
I found the following issue in the
pip
buildpack. This is outside of the scope of this issue. I plan to create a separate issue in thepip
buildpack repo for this but noting it here for reference because it is related to thepoetry
buildpack change below.pip3
andpip3.x
shebang lines point to invalid paths for python#!/tmp/d20220606-38-1nlqzzv/bin/python3.10
pip3
directly but have to runpython -m pip
insteadpoetry
Because of the above mentioned issue the
pip
process needs to be updated to usepython -m pip
instead. This change solves the problem regardless of whether thepip
buildpack is updated to fix this issue.Motivation
While most users are well served by paketo stacks and builders, there are instances where stacks based on different operating systems such as RHEL are required. Adding this support will help users with such requirements.
The text was updated successfully, but these errors were encountered: