Skip to content

fix: Fix Sensor Validation for admission webhook #3640

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ko-be
Copy link

@ko-be ko-be commented Jun 19, 2025

We have been running into an issue when deleting sensors, when the eventbus has already been deleted. When we try to remove the finalizer from a sensor we're attempting to force delete, the admission webhook denies the request with:

error: sensors.argoproj.io "flex-managed-sensor" could not be patched: admission webhook "webhook.argo-events.argoproj.io" denied the request: failed to get EventBus eventBusName=default; err=eventbus.argoproj.io "default" not found

This PR should fix this bug.

While creating additional test cases to catch this bug, also noticed that the current code panics when eventBusClient is nil, so added a guard against that as well.


Checklist:

@ko-be ko-be requested a review from whynowy as a code owner June 19, 2025 21:54
@ko-be ko-be marked this pull request as draft June 19, 2025 21:57
@ko-be ko-be force-pushed the fix-sensor-validation branch 2 times, most recently from 921d3e1 to 1dd1023 Compare June 24, 2025 00:23
@ko-be ko-be marked this pull request as ready for review June 24, 2025 22:55
@ko-be ko-be force-pushed the fix-sensor-validation branch from 1dd1023 to f2771d1 Compare June 24, 2025 22:56
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.

2 participants