hasura / hasura/graphql-engine
Unable to delete event trigger if metadata inconsistent
- Dominant language
- TypeScript
- Stars
- 32.1k
- Forks
- 3k
- PR merge metrics
- PR metrics pending
Description
### Version Information
Server Version: 2.12.0
### Environment
OSS
### What is the current behaviour?
When an event trigger is inconsistent, it cannot be deleted.
### What is the expected behavior?
Users should be able to remove event triggers even if inconsistent.
### How to reproduce the issue?
1. Create an event trigger that references an environment variable for the URL
2. Remove the environment variable and restart the instance, metadata is now inconsistent
3. Navigate to the event trigger and attempt to delete it.
4. Deletion fails
Note that users can drop the inconsistent metadata, but that runs into #9120
This issue was the problem in #9119
### Workaround
The event trigger can be deleted correctly if metadata is consistent.
In the example above, adding the env var again before deleting the event trigger should work.
Contributor guide
Research direction
No source file or test is named. Start by reproducing the failure with an event trigger whose URL references a removed environment variable, then trace the event-trigger deletion entry point and its metadata validation. Done means the inconsistent trigger can be deleted without restoring the environment variable, with coverage for this reproduction.
Written by the indexing model from the issue text.
Assessment
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100