4d54122d24
Build & Test (NowChessSystems) TeamCity build failed
Pre-assigning bot.id on a @GeneratedValue entity causes Hibernate 6 to treat it as detached, throwing PersistentObjectException on persist(). Fix: persist with null id (Hibernate assigns UUID immediately in-memory), then set token on the now-managed entity — dirty tracking commits the token at transaction flush. No second persist() call needed. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>