interactive-brokers-api icon indicating copy to clipboard operation
interactive-brokers-api copied to clipboard

Auth and such are using subprocesses that invoke `cmd` and `tasklist`, so windows only.

Open automata-studio opened this issue 3 years ago • 5 comments

Are there no options to use this library on mac / UNIX? Or do I have to change all the subprocess windows commands to UNIX equivalents?

e.g. FileNotFoundError: [Errno 2] No such file or directory: 'tasklist' when trying to see if there is an active running gateway...

Kind regards, Kristof

automata-studio avatar Jan 24 '22 11:01 automata-studio

If you want I extend this on another branch and open a PR for you....

automata-studio avatar Jan 24 '22 11:01 automata-studio

Also running into this issue, would love that pr

maxwhoppa avatar Jan 29 '22 19:01 maxwhoppa

Hi @areed1192 I just hit this issue, should this work with osx?

J$ python3 test.py 
Traceback (most recent call last):
  File "/Users/username/Documents/python/ibkr/interactive-brokers-api/test.py", line 29, in <module>
    auth_service.login()
  File "/Users/username/Documents/python/ibkr/interactive-brokers-api/ibc/utils/auth.py", line 47, in login
    is_running_response = self._is_already_running()
  File "/Users/username/Documents/python/ibkr/interactive-brokers-api/ibc/utils/auth.py", line 90, in _is_already_running
    content = subprocess.run(
  File "/usr/local/Cellar/[email protected]/3.9.10/Frameworks/Python.framework/Versions/3.9/lib/python3.9/subprocess.py", line 505, in run
    with Popen(*popenargs, **kwargs) as process:
  File "/usr/local/Cellar/[email protected]/3.9.10/Frameworks/Python.framework/Versions/3.9/lib/python3.9/subprocess.py", line 951, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/usr/local/Cellar/[email protected]/3.9.10/Frameworks/Python.framework/Versions/3.9/lib/python3.9/subprocess.py", line 1821, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'tasklist'

Cass0wary avatar Feb 19 '22 12:02 Cass0wary

Hey! I've got the same issue, anyone know how to change all the subprocess commands? Thanks!

TomsonReuters avatar Nov 13 '22 21:11 TomsonReuters

I didn't see any PR for posix support so, I created it myself. Do check it out. I understand it was way back in the past so, might not be relevant to you anymore. https://github.com/areed1192/interactive-brokers-api/pull/6

awebisam avatar Jul 12 '23 02:07 awebisam