Skip to content
This repository has been archived by the owner on Aug 2, 2023. It is now read-only.

listen(0) in create_server() does not allow client to connect to linux server #793

Closed
joelhock opened this issue Sep 10, 2018 · 0 comments · Fixed by #806
Closed

listen(0) in create_server() does not allow client to connect to linux server #793

joelhock opened this issue Sep 10, 2018 · 0 comments · Fixed by #806
Assignees
Labels

Comments

@joelhock
Copy link

Environment data

  • PTVSD version: 4.1.1
  • OS and version: linux kernel 4.14.46
  • Python version (& distribution if applicable, e.g. Anaconda): 2.7.13, 3.5.3
  • Using VS Code or Visual Studio: N/A

Actual behavior

server on linux never accepts connection, i.e. client, _ = sock.accept() in connect() in socket.py never returns. This is due to the listen(0) call in create_server(). This was changed from listen(1) in 322f694. Although listen(0) does work correctly on mac, it does not on linux.

Expected behavior

the incoming connection to be accepted

Steps to reproduce:

run:

ptvsd.enable_attach(address=('0.0.0.0', 9876), redirect_output=True)
ptvsd.wait_for_attach()

then from the command line, see that telnet localhost 9876 hangs instead of connecting. some background history is at https://bugs.python.org/issue8498

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants