nomadcode/services
toki 1a99b3d04b fix(scheduler): skip task finalizer when Ref.ID is empty for missing-create jobs
On the missing-create path, SyncCreation creates a new Plane work item and
returns SyncActionProjected before any workflow task has been registered for
the new work item UUID. Calling CompleteTaskByExternalRef with an empty Ref.ID
caused pgx.ErrNoRows → River retry → reconcile returning not_ready, leaving
only develop_matched recorded.

Fix 1 (roadmap_sync_jobs.go): guard CompleteTaskByExternalRef with args.Ref.ID != ""
so missing-create jobs complete cleanly without retrying.

Fix 2 (workflow/service.go): CompleteTaskByExternalRef now returns (zero, false, nil)
when GetTaskByExternalRef returns pgx.ErrNoRows, so reconcile jobs that have no
registered workflow task also complete cleanly rather than triggering retry loops.

Also adds PLANE_PROJECT_ID to docker-compose.yml environment so the missing-create
bridge receives non-empty tenant/project inputs at runtime.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-21 13:45:48 +09:00
..
core fix(scheduler): skip task finalizer when Ref.ID is empty for missing-create jobs 2026-06-21 13:45:48 +09:00