Skip to content

python debugger hangs #3342

@hros

Description

@hros

Environment data

  • VS Code version: 1.29.0
  • Extension version (available under the Extensions sidebar): 2018.10.1 (09 Nov 2018)
  • OS and version: Ubuntu 16.04 x64 latest updates
  • Python version (& distribution if applicable, e.g. Anaconda): Anaconda 4.5.11, python 3.6.6
  • Type of virtual environment used (N/A | venv | virtualenv | conda | ...): conda
  • Relevant/affected Python packages and their versions: python-chess 0.23.9

Actual behavior

integrated debugger hangs when single-stepping over chess-engine commands from python-chess which communicate with the stockfish chess engine.
Note: continuing over the code, to a breakpoint later in the code, works as expected

Expected behavior

debugger should single step over the commands successfully.
debugging with pdb from the command line (python -m pdb fname.py) works as expected

Steps to reproduce:

  1. pip install python-chess
  2. sudo apt install stockfish
  3. try debugging the following code, single stepping over the 'SF.*' commands
import chess.uci
from chess import Board

SF = chess.uci.popen_engine('/usr/games/stockfish')
sample_fen = 'rnb1k2r/pp2pp2/3p3p/2pP2p1/2P1B3/2q3B1/P4PPP/R2Q1KNR b kq - 0 12'

SF.uci()
SF.isready()

board = Board()
board.set_fen(sample_fen)

SF.ucinewgame()
SF.position(board)

res = SF.go(nodes=50_000)

print(res)

Metadata

Metadata

Assignees

Labels

area-debuggingbugIssue identified by VS Code Team member as probable bug

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions