Skip to content

issues="unsupported value type" picked="unsupported value type" #185

Open
@VaaFull

Description

@VaaFull

Hello team
I've got an issue with https://github.com/prometheus-community/jiralert/blob/master/pkg/notify/notify.go#L337
It seems like variables issues and issue returned some wrong data. If we check logs, query shows with no error, but for the last 2 variables I've got the issue - unsupported value type
"query", query, "issues", issues, "picked", issue

I took some logs to get better understanding. It is the same logs, but in different output

So the first one is default logs format tell us:

level=warn ts=2024-03-13T14:38:23.351923702Z caller=notify.go:337 msg="more than one issue matched, picking most recently resolved" query="project in('ITDPL') and labels=\"JIRALERT{153c989daecc938ce2e36d47......1cae62a0475ca415c238b824556e2192e1148}\" order by resolutiondate desc" issues="unsupported value type" picked="unsupported value type"

Next is DEBUG level

level=debug ts=2024-03-13T14:26:23.121607584Z caller=notify.go:323 msg=search query="project in('ITDPL') and labels=\"JIRALERT{153c989daecc938ce98fc1025b.......16c1cae62a0475ca415c238b824556e2192e1148}\" order by resolutiondate desc" options="&{StartAt:0 MaxResults:2 Expand: Fields:[summary status resolution resolutiondate description comment] ValidateQuery:}"
level=warn ts=2024-03-13T14:26:23.386894917Z caller=notify.go:337 msg="more than one issue matched, picking most recently resolved" query="project in('ITDPL') and labels=\"JIRALERT{153c989daecc938.........6c1cae62a0475ca415c238b824556e2192e1148}\" order by resolutiondate desc" issues="unsupported value type" picked="unsupported value type"

Next DEBUG JSON

{"caller":"notify.go:337","issues":[{"expand":"operations,versionedRepresentations,editmeta,changelog,renderedFields","id":"3741735","self":"https://gtsaaa.aaa.com/rest/api/2/issue/3741735","key":"ITDPL-54439","fields":{"status":{"description":"The issue is open and ready for the assignee to start work on it.","iconUrl":"https://gtsaaa.aaa.com/images/icons/statuses/open.png","id":"1","name":"Open","self":"https://gtsaaa.aaa.com/rest/api/2/status/1","statusCategory":{"colorName":"default","id":2,"key":"new","name":"To Do","self":"https://gtsaaa.aaa.com/rest/api/2/statuscategory/2"}},"summary":"[FIRING:1] TEST-PVC,aaa,postgres-main"}},{"expand":"operations,versionedRepresentations,editmeta,changelog,renderedFields","id":"3741684","self":"https://gtsaaa.aaa.com/rest/api/2/issue/3741684","key":"ITDPL-54436","fields":{"resolutiondate":"2024-03-11T10:17:08.000-0400","status":{"description":"A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.","iconUrl":"https://gtsaaa.aaa.com/images/icons/statuses/resolved.png","id":"5","name":"Resolved","self":"https://gtsaaa.aaa.com/rest/api/2/status/5","statusCategory":{"colorName":"success","id":3,"key":"done","name":"Done","self":"https://gtsaaa.aaa.com/rest/api/2/statuscategory/3"}},"summary":"[FIRING:1] TEST-PVC,aaa,postgres-main"}}],"level":"warn","msg":"more than one issue matched, picking most recently resolved","picked":{"expand":"operations,versionedRepresentations,editmeta,changelog,renderedFields","id":"3741735","self":"https://gtsaaa.aaa.com/rest/api/2/issue/3741735","key":"ITDPL-54439","fields":{"status":{"description":"The issue is open and ready for the assignee to start work on it.","iconUrl":"https://gtsaaa.aaa.com/images/icons/statuses/open.png","id":"1","name":"Open","self":"https://gtsaaa.aaa.com/rest/api/2/status/1","statusCategory":{"colorName":"default","id":2,"key":"new","name":"To Do","self":"https://gtsaaa.aaa.com/rest/api/2/statuscategory/2"}},"summary":"[FIRING:1] TEST-PVC,aaa,postgres-main"}},"query":"project in('ITDPL') and labels=\"JIRALERT{153c989daecc938ce98.........ca415c238b824556e2192e1148}\" order by resolutiondate desc","ts":"2024-03-13T13:26:23.214364566Z"}
{"caller":"notify.go:340","issue":{"expand":"operations,versionedRepresentations,editmeta,changelog,renderedFields","id":"3741735","self":"https://gtsaaa.aaa.com/rest/api/2/issue/3741735","key":"ITDPL-54439","fields":{"status":{"description":"The issue is open and ready for the assignee to start work on it.","iconUrl":"https://gtsaaa.aaa.com/images/icons/statuses/open.png","id":"1","name":"Open","self":"https://gtsaaa.aaa.com/rest/api/2/status/1","statusCategory":{"colorName":"default","id":2,"key":"new","name":"To Do","self":"https://gtsaaa.aaa.com/rest/api/2/statuscategory/2"}},"summary":"[FIRING:1] TEST-PVC,aaa,postgres-main"}},"level":"debug","msg":"found","query":"project in('ITDPL') and labels=\"JIRALERT{153c989daecc938ce98........38b824556e2192e1148}\" order by resolutiondate desc","ts":"2024-03-13T13:26:23.214785765Z"}```

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions