8c0fbc8ffa
Postgres rejects FOR UPDATE on the nullable side of a LEFT JOIN, which made LeaseNextQueuedDesktopTask fail under contention. Replace the join with a NOT EXISTS subquery, scope the row lock to the dt alias, and add a regression test plus warn-level logging on lease query failures so similar issues are easier to diagnose.