• Mahmoud Aglan's avatar
    fix(matchmaking): test accounts and real players never meet in a public queue · f5207cc4
    Mahmoud Aglan authored
    The play tests run against production, and a test account waiting in the
    public chess queue was seated across a real player (karimelshafei22), who
    then played an account that vanished with the test's teardown. Nothing in
    any queue knew a test account from a person.
    
    profiles.is_test (migrations/2026-10-27-test-accounts.sql, applied) marks
    an account the tests made. It is a column, not a name: usernames and
    display names are the player's own choice, so a name marker could drop a
    real player into the test pool. The profiles guard keeps the column out of
    a player's token, both ways. The migration also marks the 23 ZZZ-* test
    accounts earlier runs left behind.
    
    includes/match-pool.php keeps every search to the searcher's pool: the
    queue call and the status pickup of an earlier queuer in chess, ludo,
    domino and backgammon, and domino's public tables of three and four.
    Unknown means no: a profile that cannot be read is seated with nobody. The
    bot fill only ever holds the player's own row, after that search, so it
    needs no change. Real players among themselves pair exactly as before.
    Co-Authored-By: 's avatarClaude Opus 5.5 <noreply@anthropic.com>
    f5207cc4
ghost.php 15 KB