Open
Description
With conditions_v2
, if I set value
of event_frequency
to zero, it fails:
│ Error: Client error
│
│ with sentry_issue_alert.app_staging,
│ on alerts.tf line 13, in resource "sentry_issue_alert" "app_staging":
│ 13: resource "sentry_issue_alert" "app_staging" {
│
│ Unable to update, got status 400: {"conditions":["Ensure all required fields are filled in."]}
Here's a sample resource. It works if "value" is 1, fails if it's 0
or even "0"
.
resource "sentry_issue_alert" "app_staging" {
organization = sentry_organization.org.id
project = sentry_project.app.id
owner = "team:${local.app_team_id}"
name = "alerts-app-staging"
environment = "staging"
action_match = "any"
filter_match = "all"
frequency = 1440
conditions_v2 = [
{ first_seen_event = {} },
{
event_frequency = {
value = 0 # must be nonzero
comparison_type = "count"
interval = "1h"
},
},
]
actions_v2 = [
{
slack_notify_service = {
...
}
]
}
If I set the value to zero in the UI and it is set to, say, one in terraform, it properly shows drift:
~ event_frequency = {
~ name = "The issue is seen more than 0 times in 1h" -> (known after apply)
~ value = 0 -> 1
# (2 unchanged attributes hidden)
}
Using jianyuan/sentry version 0.14.3
, terraform v1.9.5
.
Metadata
Metadata
Assignees
Labels
No labels