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

Store PIP_INDEX_URL value in pip.ini config when present during assemble #664

Merged
merged 2 commits into from
Apr 16, 2024

Conversation

hrnciar
Copy link
Member

@hrnciar hrnciar commented Mar 25, 2024

Fixes #654

@hrnciar
Copy link
Member Author

hrnciar commented Mar 25, 2024

[test-all]

@hrnciar
Copy link
Member Author

hrnciar commented Mar 25, 2024

[test-all]

test/run Outdated
@@ -6,7 +6,7 @@
# IMAGE_NAME specifies a name of the candidate image used for testing.
# The image has to be available before this script is executed.
#
declare -a COMMON_WEB_APPS=({gunicorn-config-different-port,gunicorn-different-port,django-different-port,standalone,setup,setup-requirements,django,numpy,app-home,locale,pipenv,pipenv-and-micropipenv-should-fail,app-module,pyuwsgi-pipenv{% if spec.version.startswith("3.") %},micropipenv{% endif %}}-test-app)
declare -a COMMON_WEB_APPS=({gunicorn-config-different-port,gunicorn-different-port,django-different-port,standalone,standalone-custom-pypi-index-test-app,setup,setup-requirements,django,numpy,app-home,locale,pipenv,pipenv-and-micropipenv-should-fail,app-module,pyuwsgi-pipenv{% if spec.version.startswith("3.") %},micropipenv{% endif %}}-test-app)
Copy link
Member

Choose a reason for hiding this comment

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

This list uses a shell expansion so the name of the test should not contain -test-app. See the rest of the tests in the list.

@hrnciar
Copy link
Member Author

hrnciar commented Mar 26, 2024

[test-all]

@hrnciar
Copy link
Member Author

hrnciar commented Mar 26, 2024

[test-all]

@hrnciar
Copy link
Member Author

hrnciar commented Mar 26, 2024

[test-all]

@hrnciar
Copy link
Member Author

hrnciar commented Mar 26, 2024

[test-all]

@hrnciar
Copy link
Member Author

hrnciar commented Mar 26, 2024

[test-all]

@hrnciar
Copy link
Member Author

hrnciar commented Mar 27, 2024

[test]

@phracek
Copy link
Member

phracek commented Apr 2, 2024

[test-all]

@hrnciar
Copy link
Member Author

hrnciar commented Apr 3, 2024

[test-all]

@phracek
Copy link
Member

phracek commented Apr 3, 2024

RHEL8 - Python 2.7 failure:

[1m[INFO] Building the standalone-custom-pypi-index-test-app application image ...�[0m

STEP 1/10: FROM ubi8/python-27:2.7
STEP 2/10: LABEL "io.openshift.s2i.build.image"="ubi8/python-27:2.7"       "io.openshift.s2i.build.source-location"="file:///root/sclorg/s2i-python-container/2.7/test/standalone-custom-pypi-index-test-app"
--> c24fa516179e
STEP 3/10: USER root
--> a85aad6bcd55
STEP 4/10: COPY upload/src/ /tmp/src
--> 2a56e8ea3a8d
STEP 5/10: RUN chown -R 1001:0 /tmp/src
--> 8d8bf7393fc1
STEP 6/10: ENV PIP_INDEX_URL=https://test.pypi.org/simple/
--> 87f8e451f591
STEP 7/10: ENV DISABLE_SETUP_PY_PROCESSING=true
--> a37dfc85b43d
STEP 8/10: USER 1001
--> f5ff008efcd2
STEP 9/10: RUN /usr/libexec/s2i/assemble
---> Installing application source ...
---> Upgrading pip to latest version supported for Python 2.7 ...
DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support pip 21.0 will remove support for this functionality.
Looking in indexes: https://test.pypi.org/simple/
Requirement already up-to-date: pip in /opt/app-root/lib/python2.7/site-packages (20.3.4)
---> Creating pip.ini config file
---> Installing dependencies ...
DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support pip 21.0 will remove support for this functionality.
Looking in indexes: https://test.pypi.org/simple/
Collecting pello
  Downloading https://test-files.pythonhosted.org/packages/e6/51/fbdfb3630b042e3f2c1afe5a6e1a9ed5ba11c48640cb6248c91ed44a3b4e/Pello-1.0.3.tar.gz (5.9 kB)
  Installing build dependencies: started
  Installing build dependencies: finished with status 'error'
  ERROR: Command errored out with exit status 1:
   command: /opt/app-root/bin/python2 /opt/app-root/lib/python2.7/site-packages/pip install --ignore-installed --no-user --prefix /tmp/pip-build-env-t3SzWE/overlay --no-warn-script-location --no-binary :none: --only-binary :none: -i https://test.pypi.org/simple/ -- 'setuptools>=42' wheel
       cwd: None
  Complete output (4 lines):
  DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support pip 21.0 will remove support for this functionality.
  Looking in indexes: https://test.pypi.org/simple/
  ERROR: Could not find a version that satisfies the requirement setuptools>=42 (from versions: none)
  ERROR: No matching distribution found for setuptools>=42
  ----------------------------------------
ERROR: Command errored out with exit status 1: /opt/app-root/bin/python2 /opt/app-root/lib/python2.7/site-packages/pip install --ignore-installed --no-user --prefix /tmp/pip-build-env-t3SzWE/overlay --no-warn-script-location --no-binary :none: --only-binary :none: -i https://test.pypi.org/simple/ -- 'setuptools>=42' wheel Check the logs for full command output.
Error: building at STEP "RUN /usr/libexec/s2i/assemble": while running runtime: exit status 1
  ERROR: Failed to to build /tmp/tmp.ENahEOxKAc/Dockerfile.Com3

@hrnciar
Copy link
Member Author

hrnciar commented Apr 9, 2024

[test]

@frenzymadness
Copy link
Member

The PR looks good to me now. Thank you.

@gardar do you want to take a look and test it before we merge it and ship it?

@frenzymadness
Copy link
Member

[test]

1 similar comment
@frenzymadness
Copy link
Member

[test]

@gardar
Copy link

gardar commented Apr 16, 2024

@gardar do you want to take a look and test it before we merge it and ship it?

Haven't had a chance to test it, but it looks good to me, thanks!

@frenzymadness frenzymadness merged commit b839014 into sclorg:master Apr 16, 2024
19 checks passed
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.

Use PIP_INDEX_URL with pipenv
4 participants