After 1.7.3, could not download registries (getaddrinfo() thread failed to start)

Upgraded to Julia 1.7.3.
Thanks to all involved for the new release.

Afterwards

julia> using Pkg
julia> Pkg.update()
    Updating registry at `C:\Users\Audrius-St\.julia\registries\General.toml`
┌ Warning: could not download https://pkg.julialang.org/registries
│   exception = getaddrinfo() thread failed to start while requesting https://pkg.julialang.org/registries

No idea if this is related to the new release, but have not encountered this error message previously.

julia> using Downloads

julia> request(“https://pkg.julialang.org/registries”)
ERROR: getaddrinfo() thread failed to start while requesting https://pkg.julialang.org/registries
Stacktrace:
[1] (::Downloads.var"#9#18"{Base.DevNull, Base.DevNull, Nothing, Vector{Pair{String, String}}, Float64, Nothing, Bool, Nothing, Bool, String, Bool, Bool})(easy::Downloads.Curl.Easy)
@ Downloads C:\Users\Audrius-St\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Downloads\src\Downloads.jl:387
[2] with_handle(f::Downloads.var"#9#18"{Base.DevNull, Base.DevNull, Nothing, Vector{Pair{String, String}}, Float64, Nothing, Bool, Nothing, Bool, String, Bool, Bool}, handle::Downloads.Curl.Easy)
@ Downloads.Curl C:\Users\Audrius-St\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Downloads\src\Curl\Curl.jl:88
[3] #8
@ C:\Users\Audrius-St\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Downloads\src\Downloads.jl:328 [inlined]
[4] arg_write(f::Downloads.var"#8#17"{Base.DevNull, Nothing, Vector{Pair{String, String}}, Float64, Nothing, Bool, Nothing, Bool, String, Bool, Bool}, arg::Base.DevNull)
@ ArgTools C:\Users\Audrius-St\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\ArgTools\src\ArgTools.jl:112
[5] #7
@ C:\Users\Audrius-St\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Downloads\src\Downloads.jl:327 [inlined]
[6] arg_read
@ C:\Users\Audrius-St\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\ArgTools\src\ArgTools.jl:61 [inlined]
[7] request(url::String; input::Nothing, output::Nothing, method::Nothing, headers::Vector{Pair{String, String}}, timeout::Float64, progress::Nothing, verbose::Bool, debug::Nothing, throw::Bool, downloader::Nothing)
@ Downloads C:\Users\Audrius-St\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Downloads\src\Downloads.jl:326
[8] request(url::String)
@ Downloads C:\Users\Audrius-St\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Downloads\src\Downloads.jl:306
[9] top-level scope
@ REPL[4]:1

There was a bump to the Downloads standard library version that was intended to fix certain threading problems. It is possible some regression sneaked in. Could you please open an issue with as many details as possible.

1 Like

That looks like an issue with libuv, which internally uses a dedicated thread for DNS lookups in order to avoid blocking since getaddrinfo is one of the few C APIs that has no non-blocking alternative. Looks like libuv is unable to start that thread for some reason. That inability could be related to the Downloads bump, but it’s hard to see how.

As this issue persists, have opened an issue as requested.

1 Like