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 pre commit CI actions #2066

Merged
merged 6 commits into from
Oct 9, 2024
Merged

Fix pre commit CI actions #2066

merged 6 commits into from
Oct 9, 2024

Conversation

kurlov
Copy link
Member

@kurlov kurlov commented Oct 9, 2024

Description

Pre-commit CI fails because we use python version which complains when you install system wide package via pip and pre-commit action is doing exactly that under the hood. We need to specify python setup so non default python from ubuntu is used. The error comes from the PEP-668

You can see CI failure in the empty line to trigger pre commit CI commit

Run pre-commit/[email protected]
Run python -m pip install pre-commit
error: externally-managed-environment

× This environment is externally managed
╰─> To install Python packages system-wide, try apt install
    python3-xyz, where xyz is the package you are trying to
    install.
    
    If you wish to install a non-Debian-packaged Python package,
    create a virtual environment using python3 -m venv path/to/venv.
    Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make
    sure you have python3-full installed.
    
    If you wish to install a non-Debian packaged Python application,
    it may be easiest to use pipx install xyz, which will manage a
    virtual environment for you. Make sure you have pipx installed.
    
    See /usr/share/doc/python3.12/README.venv for more information.

note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages.
hint: See PEP 66[8](https://github.com/stackrox/acs-fleet-manager/actions/runs/11253773736/job/31289757694?pr=2066#step:5:10) for the detailed specification.

Checklist (Definition of Done)

  • Unit and integration tests added
  • Added test description under Test manual
  • Documentation added if necessary (i.e. changes to dev setup, test execution, ...)
  • CI and all relevant tests are passing
  • Add the ticket number to the PR title if available, i.e. ROX-12345: ...
  • Discussed security and business related topics privately. Will move any security and business related topics that arise to private communication channel.
  • Add secret to app-interface Vault or Secrets Manager if necessary
  • RDS changes were e2e tested manually
  • Check AWS limits are reasonable for changes provisioning new resources
  • (If applicable) Changes to the dp-terraform Helm values have been reflected in the addon on integration environment

Test manual

TODO: Add manual testing efforts

N/A

Copy link
Contributor

openshift-ci bot commented Oct 9, 2024

@kurlov: Overrode contexts on behalf of kurlov: ci/prow/e2e

In response to this:

/override ci/prow/e2e

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Copy link
Contributor

openshift-ci bot commented Oct 9, 2024

@kurlov: Overrode contexts on behalf of kurlov: ci/prow/e2e

In response to this:

/override ci/prow/e2e

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Copy link
Contributor

openshift-ci bot commented Oct 9, 2024

@kurlov: Overrode contexts on behalf of kurlov: ci/prow/e2e

In response to this:

/override ci/prow/e2e

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Copy link
Contributor

openshift-ci bot commented Oct 9, 2024

@kurlov: Overrode contexts on behalf of kurlov: ci/prow/e2e

In response to this:

/override ci/prow/e2e

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@kurlov kurlov changed the title Akurlov/fix pre commit gh actions Fix pre commit CI actions Oct 9, 2024
@kurlov
Copy link
Member Author

kurlov commented Oct 9, 2024

/override ci/prow/e2e

Copy link
Contributor

openshift-ci bot commented Oct 9, 2024

@kurlov: Overrode contexts on behalf of kurlov: ci/prow/e2e

In response to this:

/override ci/prow/e2e

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@kurlov kurlov requested review from a team and ludydoo and removed request for a team October 9, 2024 11:24
Copy link
Contributor

openshift-ci bot commented Oct 9, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ebensh, kurlov

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kurlov
Copy link
Member Author

kurlov commented Oct 9, 2024

/override ci/prow/e2e

Copy link
Contributor

openshift-ci bot commented Oct 9, 2024

@kurlov: Overrode contexts on behalf of kurlov: ci/prow/e2e

In response to this:

/override ci/prow/e2e

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@kurlov kurlov merged commit f3b7fcc into main Oct 9, 2024
12 checks passed
@kurlov kurlov deleted the akurlov/fix-pre-commit-gh-actions branch October 9, 2024 12:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants