Skip to content

Fix nil point dereference in updateStatus method #638

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

Merged
merged 1 commit into from
May 2, 2025

Conversation

furkatgofurov7
Copy link
Contributor

@furkatgofurov7 furkatgofurov7 commented Apr 30, 2025

What this PR does / why we need it:
The panic in the logs indicates a nil pointer dereference in the updateStatus function of the RKE2ControlPlaneReconciler, so the changes improve the resilience of the controller by adding additional nil checks, improving error handling, and ensuring graceful handling of edge cases during cluster deletion and reconciliation.

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes: #620

Special notes for your reviewer:

Checklist:

  • squashed commits into logical changes
  • includes documentation
  • adds unit tests
  • adds or updates e2e tests

@furkatgofurov7 furkatgofurov7 added area/controller Indicates an issue or PR related to the controllers kind/bug Something isn't working kind/refactor Denotes a change that is a refactor labels Apr 30, 2025
@furkatgofurov7 furkatgofurov7 requested a review from a team as a code owner April 30, 2025 15:42
@furkatgofurov7 furkatgofurov7 moved this to PR to be reviewed in CAPI / Turtles Apr 30, 2025
@furkatgofurov7 furkatgofurov7 added this to the v0.15.0 milestone Apr 30, 2025
@furkatgofurov7 furkatgofurov7 enabled auto-merge May 2, 2025 07:33
@furkatgofurov7 furkatgofurov7 added this pull request to the merge queue May 2, 2025
@furkatgofurov7 furkatgofurov7 self-assigned this May 2, 2025
Merged via the queue into rancher:main with commit c75777e May 2, 2025
7 checks passed
@furkatgofurov7 furkatgofurov7 deleted the fix-panic-updateStatus branch May 2, 2025 09:21
@github-project-automation github-project-automation bot moved this from PR to be reviewed to Done in CAPI / Turtles May 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/controller Indicates an issue or PR related to the controllers kind/bug Something isn't working kind/refactor Denotes a change that is a refactor
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Panic on Cluster deletion
3 participants