-
Notifications
You must be signed in to change notification settings - Fork 14
Description
Apparently us linux heads totally forgot (specifically in #375)
that windows doesn't have (obvious) support for unix-domain-sockets,
though TIL apparently there is/has-been support ?? (for a long
time)
To start we likely just want to fix the immediate crash-on-import
Bp
So for that we should prolly do all of,
- make sure we aren't always importing the
.ipc._udsmodule
by guarding the currentip._typessub-import
with a platform check so that by default we're only loading it for supported OSes.. - maybe
log.warning()-explain when we're unable to use that backend
and/or require further special dependencies/sys-config to do so (see below) ?? - write a test which checks if we're running on windows that can at least run in CI
- presuming we get it running again per Disable win tests in CI #327 and any
@no_windowsskip-mark
usage throughout.
- presuming we get it running again per Disable win tests in CI #327 and any
On the topic of UDS support in the windows kernel, this blog post claims support was added "Beginning in Insider Build 17063"..
That build page further states,
Unix style sockets (AF_UNIX) are available on Windows AF_UNIX is an
address family which has enabled inter-process communication on
Unix for countless years. The windows equivalent is named pipes,
which offers similar facilities. Based on user feedback, we heard
that you’d like an easier path when porting tools relying on
AF_UNIX to Windows. As a result, two Win32 processes can now use
the AF_UNIX address family over Winsock API to communicate with
each other. Read this blog for more details.
and the blog post claims and/or links these further resources:
- only TCP-like "reliable" use is supported per,
Currently, the support only exists for the stream (SOCK_STREAM)
socket type, which is a connection-oriented protocol for one-to-one
communication. Support for the datagram (SOCK_DGRAM) can be
considered in future depending on the adoption, feedback and
scenarios.- we [are already using this
type] afaik, so we-should-be-gud?
- we [are already using this
cpythonhas for a long while talked support, but it's been super
slow moving..- longstanding feat-req: Enable AF_UNIX support in Windows python/cpython#77589
- 2024 summary comment is Enable AF_UNIX support in Windows python/cpython#77589 (comment)
- latest necro-bump from 2025 is Enable AF_UNIX support in Windows python/cpython#77589 (comment)
- recent WIP patch => gh-77589: Add unix domain socket for Windows python/cpython#137420
- latest request for review: gh-77589: Add unix domain socket for Windows python/cpython#137420 (comment)
- longstanding feat-req: Enable AF_UNIX support in Windows python/cpython#77589
- the specific section/steps (from that post) on how-to write an
AF_UNIXapp - the winsock API docs
- some winsock GH exs (but it doesn't seem to have any examples for
AF_UNIXin
particular ??)