Skip to content

Conversation

sujaya-sys
Copy link
Collaborator

@sujaya-sys sujaya-sys commented Aug 21, 2025

Overview

Attempt to fix #59

Note: I've been experimenting with claude code to solve this issue - if the implementation seems non-sensical or would take a long time to correct, please let me know so I can close the PR and add the issue back to our backlog. Thank you!

Summary of changes: Improved deletion logic to treat "not found" errors as successful deletion rather than blocking finalizer removal.

  • Before: ANY deletion error blocks finalizer removal
  • After: Only real infrastructure errors (network, auth) block finalizer removal

Change Summary

  • 3 controllers updated: ApiCheck, Group, AlertChannel
  • Added: isNotFoundError() utility function to detect 404/not found errors
  • Added: unit tests
  • Improved: ID validation (skip deletion attempts for empty IDs)

Copy link
Member

@sorccu sorccu left a comment

Choose a reason for hiding this comment

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

Code looks alright to me and I don't think this should cause any issues, but again, not very familiar with the operator.

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.

Bug: non-existant group in Api-Check blocks deletion
2 participants