Fix: Update OPFaultGameFinder to support Base Azul (game type 621) - #52
Fix: Update OPFaultGameFinder to support Base Azul (game type 621)#52adraffy wants to merge 3 commits into
OPFaultGameFinder to support Base Azul (game type 621)#52Conversation
OPFaultGameFinder to support game type 621OPFaultGameFinder to support Base Azul (game type 621)
| } | ||
| gameProxy = IDisputeGame(parent); | ||
| } | ||
| } else if (gameType == GAME_TYPE_SUCCINCT) { |
There was a problem hiding this comment.
For GAME_TYPE_SUCCINCT, if claimData() reverts or the return data cannot be decoded (undisclosed code change in update for example), this silently falls through to the generic fault-game checks, which would still likely fall through to the false return at the end of the block, BUT out of an abundance of caution/for clarity i think it'd be worth explicitly returning false within the catch block OR better explicitly having and else block for the default and then having the default return outside of the condition gate.
|
This keeps this generic with the game type check but I suspect that over time OP and Base will diverge further with their codebases so semantically clearer file names and separations might be necessary.| Full support for 621 i think is implicit, as ultimately the challenge state check is what is required regardless of the proving mechanism through which it is set. Added one actionable comment, but otherwise looks good. |
OPFaultGameFinderIDisputeGame.l2SequenceNumber()beforel2BlockNumber()_isUnchallenged()to react togameTypeIAggregateVerifierinterfaceOPFaultParamTupletypeUnfortunately, this parent game check is O(n^2) if any parent was successfully challenged: