de00612965
When a tariff has a stale external_squad_uuid that no longer exists in the Remnawave panel, PATCH/POST /api/users fails with A039 (P2003 FK constraint violation). This caused subscriptions to not sync with the panel even though balance was already charged. Now both update_user() and create_user() catch A039 errors and automatically retry without externalSquadUuid, logging a warning about the stale UUID. The subscription sync succeeds without the external squad assignment rather than failing entirely.