FA-82560 / Chess move legality / Member archive
En passant square on the wrong side accepted · case 05
With white to move, an ep square on rank 3 is accepted.
Case contract
Input: a FEN string. Return {"pieces": {square: piece}, "turn", "castling", "ep", "halfmove", "fullmove"} or "invalid". Placement lists rank 8 first; digits skip empty squares; each rank must total 8; exactly one king per side. Turn is w or b; castling is "-" or letters from KQkq (returned as "" when "-"); ep is "-" (null) or a square on rank 6 when white is to move, rank 3 when black is; halfmove is a non-negative integer and fullmove at least 1.
Why this case matters
Every position-based legality check starts from a parsed FEN; a misparse silently changes which moves are legal.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| ep wrong side | {"castling": "", "ep": "d3", "fullmove": 9, "halfmove": 0, "pieces": {"d5": "p", "e1": "K", "e5": "P", "e8": "k"}, "turn": "w"} | "invalid" | Failed |
MEMBER ARCHIVE
The complete case is available to members.
This record includes three runnable implementations, regression fixtures, execution results, and source hashes.
Member access is invitation-based. Sign in with your invited account to inspect the sources.
Sign in to the archive ↗