Paradaux

PAR-104

0

explorer_group_member PK omits source — manual+luckperms can't coexist

DoneLowUnassignedEconomy ExplorerBug

Found during the release audit (economy-schema V10 + the reconciliation cron).

explorer_group_member PK is (group_id, player_uuid_bin) with no source, so a (group, player) pair can exist at most once. If an admin manually adds player P to a group (source='manual') and P also carries the group's LuckPerms node, the cron's INSERT IGNORE ... 'luckperms' is silently no-op'd by the PK collision. Consequences:

  • P never appears in listLuckpermsMemberUuids (filtered to source='luckperms'), so the cron's diff never converges for P — it re-attempts the (ignored) insert every run forever (harmless thrash).
  • The design assumes a player can belong via two sources simultaneously, which the PK forbids; manual membership masks luckperms membership.

The "never clobber manual" invariant still holds (INSERT IGNORE won't overwrite, DELETE filters on source). Capability resolution unions groups so P still gets the group's caps via the manual row — functionally fine, just non-converging churn.

Fix: make the PK/UNIQUE include source in a new economy-schema migration ((group_id, player_uuid_bin, source)), and update the explorer read query if it assumes one row per (group, player). Or, if two-source membership isn't wanted, document that manual masks luckperms by design and have the cron skip players already present via another source.

Comments

No comments yet.

Activity

  • ParadauxIO changed status to Status → Done
  • tesks changed status to Status → Pending Release
  • tesks created the issue