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

Revert "add stream shutdown and support half-duplex operation" #41850

Closed
wants to merge 1 commit into from

Conversation

DilumAluthge
Copy link
Member

@DilumAluthge DilumAluthge commented Aug 9, 2021

Reverts #40783

This broke the tests on FreeBSD 12.

@ararslan

This comment has been minimized.

@DilumAluthge

This comment has been minimized.

@ararslan

This comment has been minimized.

@DilumAluthge

This comment has been minimized.

@DilumAluthge DilumAluthge force-pushed the revert-40783-jn/shutdown branch from ab8e9ba to 4eab352 Compare August 11, 2021 04:08
@DilumAluthge DilumAluthge force-pushed the revert-40783-jn/shutdown branch from 4eab352 to 78a6cac Compare August 19, 2021 18:25
@vtjnash
Copy link
Member

vtjnash commented Aug 19, 2021

IIRC, someone said on Slack the failure is a bug in the FreeBSD libunwind library, not this PR?

@DilumAluthge
Copy link
Member Author

If I understand correctly, those are two separate issues. The discussion on Slack was about the segfaults during the FreeBSD tests.

But separately from the segfaults, there are test failures in the Sockets tests on FreeBSD that are caused by this PR.

@ararslan Is that correct?

@ararslan
Copy link
Member

As far as I know, that is correct. In the Sockets tests, the pipe is not being closed when the tests are expecting it to, so !isopen(P) is false. The segfaults, which show up as that unhandled task error, seem to be due to some issues with DWARF emission and unwinding and are unrelated to this PR.

An alternative to reverting this is to do something like

diff --git a/stdlib/Sockets/test/runtests.jl b/stdlib/Sockets/test/runtests.jl
index 328ea929f4..0186677726 100644
--- a/stdlib/Sockets/test/runtests.jl
+++ b/stdlib/Sockets/test/runtests.jl
@@ -521,7 +521,12 @@ end
     @test readuntil(P, 'w') == "llo"
     Sys.iswindows() && wait(t)
     @test eof(P)
-    @test !isopen(P) # eof test should have closed this by now
+    # FIXME: eof test should have closed this by now, but it seems not to on FreeBSD
+    if Sys.isfreebsd()
+        @test_broken !isopen(P)
+    else
+        @test !isopen(P)
+    end
     close(P) # should be a no-op, just make sure
     @test !isopen(P)
     @test eof(P)

and open an issue for tracking that. I've not yet looked into it, as I've prioritized investigating the segfaults.

@vtjnash
Copy link
Member

vtjnash commented Aug 19, 2021

that seems okay too

@DilumAluthge
Copy link
Member Author

DilumAluthge commented Aug 19, 2021

Between the revert (this PR) and a @test_broken, which do you prefer?

@DilumAluthge
Copy link
Member Author

Closing in favor of #41983

@DilumAluthge DilumAluthge deleted the revert-40783-jn/shutdown branch August 24, 2021 05:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
io Involving the I/O subsystem: libuv, read, write, etc. sockets
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants