Skip to content

Conversation

@AutomationDev85
Copy link
Contributor

Overview

We are encountering an issue where, when stopping a pod that is in the pending state, the operator attempts to access the container statuses. However, since no containers exist while the pod is pending, container_statuses is None. This leads to a crash when the code tries to iterate over the statuses in a for loop. To prevent this, a more robust approach to reading pod.container_statuses is needed.

Details of change:

  • Add more robust reading of container_statuses

@AutomationDev85 AutomationDev85 force-pushed the bugfix/kubernetespodoperator-handle-missing-container_status-during-cleanup branch from c92a618 to 754462c Compare September 8, 2025 12:34
@jscheffl jscheffl added the type:bug-fix Changelog: Bug Fixes label Sep 8, 2025
Copy link
Contributor

@jscheffl jscheffl left a comment

Choose a reason for hiding this comment

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

Thanks for the fix. Sounds reasonable.

Next time can you please also post a stack trace of the error with the description? Might be good for understanding.

@jscheffl jscheffl merged commit 4f7a870 into apache:main Sep 8, 2025
86 checks passed
RoyLee1224 pushed a commit to RoyLee1224/airflow that referenced this pull request Sep 8, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Sep 30, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 1, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 2, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 3, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 4, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 5, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 5, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 7, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 8, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 9, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 10, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 11, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 12, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 14, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 15, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 17, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
abdulrahman305 bot pushed a commit to abdulrahman305/airflow that referenced this pull request Oct 19, 2025
Co-authored-by: AutomationDev85 <AutomationDev85>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:providers 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.

2 participants