Skip to content

Conversation

@luos-fc
Copy link
Contributor

@luos-fc luos-fc commented May 23, 2023

This PR uses the helper util Kubernetes client over the default CoreV1Api client when deleting pods through the CLI. In the original implementation PR this change was agreed upon but never made: https://github.com/apache/airflow/pull/11802/files#r607034452

Closes #31476


^ Add meaningful description above

Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in newsfragments.

@boring-cyborg boring-cyborg bot added area:CLI provider:cncf-kubernetes Kubernetes (k8s) provider related issues labels May 23, 2023
Copy link
Member

@hussein-awala hussein-awala left a comment

Choose a reason for hiding this comment

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

It looks good, and I see that we already use get_kube_client to list the pods.
You just need to fix the static checks, please follow these steps to activate pre-commit hooks in order to fix the CI of this PR and avoid the future similar problems.

@hussein-awala hussein-awala added this to the Airflow 2.6.2 milestone May 24, 2023
@luos-fc
Copy link
Contributor Author

luos-fc commented May 24, 2023

Thank you! I did run the checks but the failure seemed unrelated to my PR as other open PRs had the same failure - see also #31500. Let me know if I've missed anything.

@hussein-awala hussein-awala merged commit adf0cae into apache:main May 24, 2023
@hussein-awala hussein-awala added the type:bug-fix Changelog: Bug Fixes label May 24, 2023
eladkal pushed a commit that referenced this pull request Jun 8, 2023
eladkal pushed a commit that referenced this pull request Jun 9, 2023
@kyle-inv-disco
Copy link

Thank you for this, Sir.

I thought I was mad for patching it myself locally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:CLI provider:cncf-kubernetes Kubernetes (k8s) provider related issues type:bug-fix Changelog: Bug Fixes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

cleanup-pod CLI command fails due to incorrect host

3 participants