diff --git a/tractor/_ipc.py b/tractor/_ipc.py index d6afc33..efe388e 100644 --- a/tractor/_ipc.py +++ b/tractor/_ipc.py @@ -1,6 +1,7 @@ """ Inter-process comms abstractions """ +import platform import typing from typing import Any, Tuple, Optional from functools import partial @@ -13,6 +14,9 @@ from .log import get_logger from ._exceptions import TransportClosed log = get_logger(__name__) + +_is_windows = platform.system() == 'Windows' + # :eyeroll: try: import msgpack_numpy @@ -73,8 +77,9 @@ class MsgpackTCPStream: # nix '[Errno 104]' in msg or - # windows - '[WinError 10054]' in msg + # on windows it seems there are a variety of errors + # to handle.. + _is_windows ): raise TransportClosed( f'{self} was broken with {msg}'