Skip to content

Fix undefined variable and invalid escape sequence in play.py#1157

Merged
lightvector merged 1 commit intolightvector:masterfrom
changcheng967:fix-play-bugs
Feb 21, 2026
Merged

Fix undefined variable and invalid escape sequence in play.py#1157
lightvector merged 1 commit intolightvector:masterfrom
changcheng967:fix-play-bugs

Conversation

@changcheng967
Copy link
Copy Markdown
Contributor

play.py has two bugs:

Line 460: N is undefined — causes NameError when the GTP boardsize command
is called with an incompatible size. Replaced with features.pos_len.

Line 451: '\d+' is an invalid escape sequence. Python 3.12+ raises
SyntaxWarning for this, and future versions will make it a hard error.
Changed to r'\d+'.

@lightvector lightvector merged commit 9b90436 into lightvector:master Feb 21, 2026
@lightvector
Copy link
Copy Markdown
Owner

Thanks!

@changcheng967 changcheng967 deleted the fix-play-bugs branch March 8, 2026 20:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants