Open Jasper2213 opened 2 months ago
Tagging subscribers to this area: @dotnet/ncl See info in area-owners.md if you want to be subscribed.
The type in question is NamedPipeClientStream. Moving to System.IO area.
Tagging subscribers to this area: @dotnet/area-system-io See info in area-owners.md if you want to be subscribed.
Tagging subscribers to this area: @dotnet/ncl See info in area-owners.md if you want to be subscribed.
Tagging subscribers to this area: @dotnet/area-system-io See info in area-owners.md if you want to be subscribed.
I commented on wrong issue. It can still be Socket
problem as the Named Pipes use unix domain socket under the cover.
Your code is different between 7 and 8 versions @Jasper2213. At least in the provided example the 7.0 project use ConnectAsync
and the InitPipeClient
is marked as async
so it will never block and hang on thread pool.
In 8.0 you use synchronous connect and that will block everything until connected until connected. In my quick test I did not have server running yet but the application hangs in weird state while 7.0 looks responsive .... even if the socket is not actually connected.,
When I make the 7.0 and 8.0 version same I see same behavior e.g. I do not see regression.
I updated the code in the .NET 8 project to match that of the .NET 7 project (can't believe I missed that). This indeed doesn't fix the problem.
Description
I'm trying to use named pipes in .NET MAUI, but when testing on MacOS, the client can't connect to the server, it just hangs on connect.
When running the project with .NET 7, the client connects to the server on both Windows and MacOS.
Reproduction Steps
Expected behavior
Client connects to Server and Server can send a message to Client
Actual behavior
Client can't connect to Server, instead hangs at
_pipeClient.ConnectAsync()
Regression?
Worked on .NET 7, doesn't work on .NET 8.
Known Workarounds
No response
Configuration
No response
Other information
No response