From d45f2326b6e9233fd5f508bd5c311e91b6232617 Mon Sep 17 00:00:00 2001 From: dtoro Date: Wed, 8 Jul 2026 21:21:44 +0200 Subject: [PATCH] fix: CreateCheck uses type "check" not "check_def" MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit FK violation — entity_types table has name "check" but phase3.go:320 was inserting type "check_def" causing: entities_type_fkey (SQLSTATE 23503) --- internal/httpapi/phase3.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/httpapi/phase3.go b/internal/httpapi/phase3.go index 90c792f..4bc03ca 100644 --- a/internal/httpapi/phase3.go +++ b/internal/httpapi/phase3.go @@ -317,7 +317,7 @@ func (s *Server) CreateCheck(ctx context.Context, req gen.CreateCheckRequestObje entity, err := q.InsertEntity(ctx, sqlcgen.InsertEntityParams{ ID: id, Slug: slug, - Type: "check_def", + Type: "check", Name: slug, Attributes: []byte("{}"), })