fix(issue-sink): stringify triggering_event_id before JSON encode

IssueCoreRestSink.emit() passed task_spec.triggering_event_id straight
into the httpx json= payload. When the field is a UUID object (rather
than a string), httpx's JSON encoder raised
"TypeError: Object of type UUID is not JSON serializable", failing the
emission. Guard with str(), preserving None for optional event ids.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-06-19 00:15:03 +02:00
parent 200ec0c97a
commit f05c56e202

View File

@@ -66,7 +66,11 @@ class IssueCoreRestSink(IssueSink):
"due_in_days": task_spec.due_in_days,
"source_type": task_spec.source_type,
"source_id": task_spec.source_id,
"triggering_event_id": task_spec.triggering_event_id,
"triggering_event_id": (
str(task_spec.triggering_event_id)
if task_spec.triggering_event_id is not None
else None
),
"activity_definition_id": task_spec.activity_definition_id,
}
resp = httpx.post(