Bug 18519 – freebsd 11 + phobos + curl, timing out

Status
RESOLVED
Resolution
FIXED
Severity
critical
Priority
P1
Component
phobos
Product
D
Version
D2
Platform
x86
OS
FreeBSD
Creation time
2018-02-24T22:53:16Z
Last change time
2019-01-04T06:39:57Z
Assigned to
No Owner
Creator
Brad Roberts

Comments

Comment #0 by braddr — 2018-02-24T22:53:16Z
Freebsd 11, 32 bit, doesn't come with 32 bit curl libraries, but does 64 bit. The phobos tests seem to not fast-fail, timing out: timelimit: sending warning signal 15 gmake[1]: *** [posix.mak:377: unittest/std/net/curl.run] Error 143 gmake[1]: Leaving directory '/media/ephemeral0/sandbox/at-client/pull-3048038-FreeBSD_32/phobos' gmake: *** [posix.mak:297: unittest-debug] Error 2 gmake: *** Waiting for unfinished jobs.... timelimit: sending warning signal 15 gmake[1]: *** [posix.mak:377: unittest/std/net/curl.run] Error 143 gmake[1]: Leaving directory '/media/ephemeral0/sandbox/at-client/pull-3048038-FreeBSD_32/phobos' gmake: *** [posix.mak:297: unittest-release] Error 2 Issues: 1) how to get 32 bit libs installed on freebsd 11 2) why are the tests timing out rather than fast failing 3) why isn't it a clear failure
Comment #1 by code — 2018-02-25T22:19:27Z
My guess would be that we throw an exception when failing to load libcurl (https://github.com/dlang/phobos/blob/6128ed629f6a180413b3965386004c39fb577d5a/std/net/curl.d#L4147), this get's escalated up to main which then tries to join outstanding threads. Could easily be the case that OwnerTerminated isn't send when the main thread terminates exceptionally, so the test-server thread might hang indefinitely https://github.com/dlang/phobos/blob/6128ed629f6a180413b3965386004c39fb577d5a/std/net/curl.d#L198. Just an educated guess, still needs to be properly investigated.
Comment #2 by greensunny12 — 2018-02-27T22:41:53Z
See also https://github.com/dlang/phobos/pull/6232 (a PR to temporarily disable the curl tests).
Comment #3 by r.sagitario — 2018-02-28T11:52:23Z
Windows is also affected if libcurl.dll is missing. See https://github.com/dlang/phobos/pull/6234
Comment #4 by github-bugzilla — 2018-03-11T13:13:50Z
Commits pushed to master at https://github.com/dlang/phobos https://github.com/dlang/phobos/commit/b8e5bca94b661c1d1ffb9ec6f7e37b9fa7a0d09d fix issue 18519 freebsd 11 + phobos + curl, timing out stop the TestServer waiting in accept() before thread_joinall https://github.com/dlang/phobos/commit/35e9807bbec392658ecdc8b4ed93d1f6c02f2845 Merge pull request #6234 from rainers/curl_freeze fix issue 18519 freebsd 11 + phobos + curl, timing out merged-on-behalf-of: Petar Kirov <[email protected]>
Comment #5 by greensunny12 — 2018-03-11T20:45:56Z
REOPENED as I just tested the PR with https://github.com/dlang/phobos/pull/6264 and the problem still seems to be existent.
Comment #6 by ibuclaw — 2019-01-02T22:31:25Z
This isn't restricted to FreeBSD 11. Any platform that doesn't have curl libraries available will hang in the same way. (Running the test runner on Linux64 with MODEL=32)
Comment #7 by github-bugzilla — 2019-01-04T06:39:56Z
Commits pushed to master at https://github.com/dlang/phobos https://github.com/dlang/phobos/commit/8d51519f3f11a5f9b538cd690521b61e9fbbf5df fix Issue 18519: missing curl + phobos = std.net.curl unittest timing out Disable the std.net.curl tests in the makefile, not the module. https://github.com/dlang/phobos/commit/8d14c379c248de2b3183ed169c4e01ea5fa57cd6 Merge pull request #6824 from ibuclaw/issue18519 fix Issue 18519: missing curl + phobos = std.net.curl unittest timing out merged-on-behalf-of: Nicholas Wilson <[email protected]>