Skip to content

Commit

Permalink
Merge pull request #944 from ianfab/fix_relative_wdl
Browse files Browse the repository at this point in the history
Make relative WDL consider model and ply
  • Loading branch information
niklasf committed Dec 18, 2022
2 parents 5201d08 + beb68d3 commit ecc6328
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion chess/engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -469,7 +469,7 @@ def is_mate(self) -> bool:

def wdl(self, *, model: _WdlModel = "sf", ply: int = 30) -> PovWdl:
"""See :func:`~chess.engine.Score.wdl()`."""
return PovWdl(self.relative.wdl(), self.turn)
return PovWdl(self.relative.wdl(model=model, ply=ply), self.turn)

def __repr__(self) -> str:
return "PovScore({!r}, {})".format(self.relative, "WHITE" if self.turn else "BLACK")
Expand Down

0 comments on commit ecc6328

Please sign in to comment.