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

MultiprocTCPBase cannot determine socket address when computer is offline #28

Closed
twoodhouse opened this Issue Jul 24, 2018 · 2 comments

Comments

Projects
None yet
2 participants
@twoodhouse
Copy link

twoodhouse commented Jul 24, 2018

As I plan to do a significant amount of development work while not connected to the internet, I was disappointed to find that all of the Thespian examples using multiprocTCPBase (and multiprocUDPBase are not able to run unless my system is connected to the internet.
The example output below is from when internet is disabled. Connecting to internet fixes the issue.

I am on Debian Ubuntu 16.04.4

Please let me know if there is a solution to this which will allow me to viably develop while offline. (or if I am just missing something)

>>> import thespian.actors
>>> thespian.actors.ActorSystem("multiprocTCPBase")
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.5/dist-packages/thespian/actors.py", line 638, in __init__
    systemBase, capabilities, logDefs)
  File "/usr/local/lib/python3.5/dist-packages/thespian/actors.py", line 676, in _startupActorSys
    systemBase = sbc(self, logDefs=logDefs)
  File "/usr/local/lib/python3.5/dist-packages/thespian/system/multiprocTCPBase.py", line 27, in __init__
    super(ActorSystemBase, self).__init__(system, logDefs)
  File "/usr/local/lib/python3.5/dist-packages/thespian/system/multiprocCommon.py", line 84, in __init__
    self.mpcontext)
  File "/usr/local/lib/python3.5/dist-packages/thespian/system/transport/TCPTransport.py", line 271, in __init__
    templateAddr     = ActorAddress(TCPv4ActorAddress(None, 0, external = externalAddr))
  File "/usr/local/lib/python3.5/dist-packages/thespian/system/transport/IPBase.py", line 254, in __init__
    external)
  File "/usr/local/lib/python3.5/dist-packages/thespian/system/transport/IPBase.py", line 150, in __init__
    raise RuntimeError('Unable to determine valid external socket address.')
RuntimeError: Unable to determine valid external socket address.

@kquick

This comment has been minimized.

Copy link
Owner

kquick commented Jul 27, 2018

Thanks for the report. I've just returned from vacation but I'll try to look into this shortly. In the meantime, you can use the simpleSystemBase for async-style single process concurrency or the multiprocQueueBase for multi-process concurrency as as workaround.

@kquick kquick added the bug label Jul 27, 2018

@kquick

This comment has been minimized.

Copy link
Owner

kquick commented Aug 5, 2018

Fixed in release 3.9.4 (https://github.com/kquick/Thespian/releases/tag/thespian-3.9.4). Thanks for the report!

@kquick kquick closed this Aug 5, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.