From bcf89faf1bf519a9e130b4f1d632a009d0e2e584 Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Dec 01 2023 14:42:02 +0000 Subject: [PATCH 1/2] The threshold_reach field is either null or a boolean, not a string Signed-off-by: Pierre-Yves Chibon --- diff --git a/pagure_messages/base.py b/pagure_messages/base.py index 03466b9..004c0b4 100644 --- a/pagure_messages/base.py +++ b/pagure_messages/base.py @@ -317,7 +317,7 @@ PULL_REQUEST = { "closed_by": {"oneOf": [{"type": "null"}, USER]}, "initial_comment": {"oneOf": [{"type": "null"}, {"type": "string"}]}, "cached_merge_status": {"type": "string"}, - "threshold_reached": {"oneOf": [{"type": "null"}, {"type": "string"}]}, + "threshold_reached": {"oneOf": [{"type": "null"}, {"type": "boolean"}]}, "tags": {"type": "array", "items": {"type": "string"}}, }, "required": [ From b5ef851539e6a54fb24a40e49daddd9de6835583 Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Dec 01 2023 14:42:02 +0000 Subject: [PATCH 2/2] Do not enforce a certain structure on the custom_fields This has the same issues as the custom_keys. Signed-off-by: Pierre-Yves Chibon --- diff --git a/pagure_messages/base.py b/pagure_messages/base.py index 004c0b4..9e35d1a 100644 --- a/pagure_messages/base.py +++ b/pagure_messages/base.py @@ -143,8 +143,8 @@ BASE_PROJECT = { "tags": {"type": "array", "items": {"type": "string"}}, # "priorities": {"type": "object"}, # "custom_keys": { - # "type": "array", - # "items": {"type": "array", "items": {"type": "string"}}, + # "type": "array", + # "items": {"type": "array", "items": {"type": "string"}}, # }, "close_status": {"type": "array", "items": {"type": "string"}}, "milestones": {"type": "object", "properties": {"type": MILESTONES}}, @@ -259,10 +259,10 @@ ISSUE = { {"type": "string"}, ] }, - "custom_fields": { - "type": "array", - "items": {"type": "array", "items": {"type": "string"}}, - }, + # "custom_fields": { + # "type": "array", + # "items": {"type": "array", "items": {"type": "string"}}, + # }, "closed_by": {"oneOf": [{"type": "null"}, USER]}, "related_prs": { "oneOf": [{"type": "null"}, {"type": "array", "items": RELATED_PR}] @@ -286,7 +286,7 @@ ISSUE = { "assignee", # "priorities", "milestone", - "custom_fields", + # "custom_fields", "closed_by", "related_prs", ],