Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Thread hangs indefinitely on exit before disconnect #1

Open
brian-from-quantrocket opened this issue Jul 22, 2017 · 0 comments
Open
Labels

Comments

@brian-from-quantrocket
Copy link
Member

If you connect to TWS then exit the process before calling conn.disconnect(), the process hangs indefinitely on a thread trying to acquire a lock:

root@f177d5faed17:/# python -c "from ibpythonic import ibConnection; conn = ibConnection(port=4001, clientId=100);conn.connect() and print('connection successful')"
connection successful
^CException ignored in: <module 'threading' from '/opt/conda/lib/python3.6/threading.py'>
Traceback (most recent call last):
  File "/opt/conda/lib/python3.6/threading.py", line 1290, in _shutdown
    t.join()
  File "/opt/conda/lib/python3.6/threading.py", line 1056, in join
    self._wait_for_tstate_lock()
  File "/opt/conda/lib/python3.6/threading.py", line 1072, in _wait_for_tstate_lock
    elif lock.acquire(block, timeout):
KeyboardInterrupt
@brian-from-quantrocket brian-from-quantrocket changed the title Thread hands indefinitely on exit before disconnect Thread hangs indefinitely on exit before disconnect Aug 3, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant