diff --git a/pkg/api.go b/pkg/api.go index 02dcaddac..2062c4f4f 100644 --- a/pkg/api.go +++ b/pkg/api.go @@ -243,7 +243,10 @@ func FromResult(result CheckResult) CheckStatus { func FromV1(canary v1.Canary, check external.Check, statuses ...CheckStatus) Check { canaryID, _ := uuid.Parse(canary.GetPersistedID()) + checkID, _ := uuid.Parse(canary.GetCheckID(check.GetName())) + c := Check{ + ID: checkID, Owner: canary.Spec.Owner, Severity: canary.Spec.Severity, // DisplayType: check.DisplayType, diff --git a/pkg/cache/postgres.go b/pkg/cache/postgres.go index f49bbbfba..ae4501aa8 100644 --- a/pkg/cache/postgres.go +++ b/pkg/cache/postgres.go @@ -54,7 +54,7 @@ func (c *postgresCache) AddCheckFromStatus(check pkg.Check, status pkg.CheckStat return uuid.Nil, nil } - if !check.Transformed { + if check.ID != uuid.Nil { return uuid.Nil, nil }