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

Apply go1.17 patches introduced in the release/3.10.1 branch #441

Closed
wants to merge 3 commits into from

Conversation

bassosimone
Copy link
Contributor

@bassosimone bassosimone commented Aug 18, 2021

Checklist

Location of the issue tracker: https://github.com/ooni/probe

Description

This PR contains patches ported from the release/3.10.1 branch. We're working on ooni/probe#1738.

@bassosimone bassosimone requested a review from hellais as a code owner August 18, 2021 10:27
@bassosimone bassosimone changed the title Forwardports Apply go1.17 patches introduced in the release/3.10.1 branch Aug 18, 2021
@bassosimone
Copy link
Contributor Author

The build is badly broken (see https://github.com/ooni/probe-cli/runs/3360050922?check_suite_focus=true).

Need to understand why.

@bassosimone
Copy link
Contributor Author

So, my understanding of the CI build issue is that this is a Linux only problem that I don't see on macOS.

@bassosimone
Copy link
Contributor Author

Yes, I can see the same issue when building and running on Linux.

@bassosimone
Copy link
Contributor Author

This is the whole crash stacktrace:

panic: interface conversion: quicdialer.saverUDPConn is not net.Conn: missing method Read

goroutine 1 [running]:
golang.org/x/net/ipv4.NewPacketConn({0x7f7f77e074f8, 0xc0000b43d8})
        $HOME/go/pkg/mod/golang.org/x/net@v0.0.0-20210813160813-60bc85c4be6d/ipv4/endpoint.go:103 +0x39
github.com/lucas-clemente/quic-go.newConn({0xfa98d0, 0xc0000b43d8})
        $HOME/go/pkg/mod/github.com/lucas-clemente/quic-go@v0.23.0/conn_oob.go:124 +0x44b
github.com/lucas-clemente/quic-go.wrapConn({0x7f7f77e074f8, 0xc0000b43d8})
        $HOME/go/pkg/mod/github.com/lucas-clemente/quic-go@v0.23.0/conn.go:37 +0xb8
github.com/lucas-clemente/quic-go.newPacketHandlerMap({0x7f7f77e074f8, 0xc0000b43d8}, 0x4, {0x0, 0x0, 0x0}, {0x0, 0x0}, {0xf9faf0, 0xc00035e570})
        $HOME/go/pkg/mod/github.com/lucas-clemente/quic-go@v0.23.0/packet_handler_map.go:128 +0xdf
github.com/lucas-clemente/quic-go.(*connMultiplexer).AddConn(0xc00035e600, {0x7f7f77e074f8, 0xc0000b43d8}, 0x4, {0x0, 0xa, 0x0}, {0x0, 0x0})
        $HOME/go/pkg/mod/github.com/lucas-clemente/quic-go@v0.23.0/multiplexer.go:71 +0x4e9
github.com/lucas-clemente/quic-go.dialContext({0xf958b0, 0xc0000aa000}, {0x7f7f77e074f8, 0xc0000b43d8}, {0xf882a0, 0xc00035e510}, {0xc00045c468, 0x13}, 0xc000386900, 0xc0000e7550, ...)
        $HOME/go/pkg/mod/github.com/lucas-clemente/quic-go@v0.23.0/client.go:196 +0x279
github.com/lucas-clemente/quic-go.DialEarlyContext(...)
        $HOME/go/pkg/mod/github.com/lucas-clemente/quic-go@v0.23.0/client.go:163
github.com/ooni/probe-cli/v3/internal/netxlite.(*QUICDialerQUICGo).dialEarlyContext(0xc0000b43d8, {0xf958b0, 0xc0000aa000}, {0x7f7f77e074f8, 0xc0000b43d8}, {0xf882a0, 0xc00035e510}, {0xc00045c468, 0xd80}, 0xc000386900, ...)
        $HOME/src/github.com/ooni/probe-cli/internal/netxlite/quic.go:98 +0xc7
github.com/ooni/probe-cli/v3/internal/netxlite.(*QUICDialerQUICGo).DialContext(0xc0000b4330, {0xf958b0, 0xc0000aa000}, {0xe124c0, 0xc00047ae00}, {0xc00045c468, 0x13}, 0x0, 0x0)
        $HOME/src/github.com/ooni/probe-cli/internal/netxlite/quic.go:83 +0x234
github.com/ooni/probe-cli/v3/internal/errorsx.(*ErrorWrapperQUICDialer).DialContext(0x0, {0xf958b0, 0xc0000aa000}, {0xe2829b, 0x13}, {0xc00045c468, 0x0}, 0x0, 0x0)
        $HOME/src/github.com/ooni/probe-cli/internal/errorsx/quic.go:88 +0x53
github.com/ooni/probe-cli/v3/internal/engine/netx/quicdialer.HandshakeSaver.DialContext({0xc0002c7b40, {0xf7d2c0, 0xc0005449f0}}, {0xf958b0, 0xc0000aa000}, {0xe2829b, 0x3}, {0xc00045c468, 0x13}, 0xc000386780, ...)
        $HOME/src/github.com/ooni/probe-cli/internal/engine/netx/quicdialer/saver.go:34 +0x21e
github.com/ooni/probe-cli/v3/internal/netxlite.(*QUICDialerResolver).DialContext(0xc0002c7c20, {0xf958b0, 0xc0000aa000}, {0xe2829b, 0x3}, {0xc00045c420, 0x7ffd320b02bf}, 0xc000526368, 0x44fbef)
        $HOME/src/github.com/ooni/probe-cli/internal/netxlite/quic.go:174 +0x2df
github.com/ooni/probe-cli/v3/internal/netxlite.(*http3Dialer).dial(...)
        $HOME/src/github.com/ooni/probe-cli/internal/netxlite/http3.go:22
github.com/lucas-clemente/quic-go/http3.(*client).dial(0xc000346500)
        $HOME/go/pkg/mod/github.com/lucas-clemente/quic-go@v0.23.0/http3/client.go:108 +0x47
github.com/lucas-clemente/quic-go/http3.(*client).RoundTrip.func1()
        $HOME/go/pkg/mod/github.com/lucas-clemente/quic-go@v0.23.0/http3/client.go:215 +0x25
sync.(*Once).doSlow(0xe28e5a, 0x5)
        $HOME/sdk/go1.17/src/sync/once.go:68 +0xd2
sync.(*Once).Do(...)
        $HOME/sdk/go1.17/src/sync/once.go:59
github.com/lucas-clemente/quic-go/http3.(*client).RoundTrip(0xc000346500, 0xc00021e300)
        $HOME/go/pkg/mod/github.com/lucas-clemente/quic-go@v0.23.0/http3/client.go:214 +0xce
github.com/lucas-clemente/quic-go/http3.(*RoundTripper).RoundTripOpt(0x0, 0xc00021e300, {0x0, 0x0})
        $HOME/go/pkg/mod/github.com/lucas-clemente/quic-go@v0.23.0/http3/roundtrip.go:118 +0x353
github.com/lucas-clemente/quic-go/http3.(*RoundTripper).RoundTrip(...)
        $HOME/go/pkg/mod/github.com/lucas-clemente/quic-go@v0.23.0/http3/roundtrip.go:123
github.com/ooni/probe-cli/v3/internal/netxlite.(*http3Transport).RoundTrip(0xc0005266c0, 0xf69622)
        $HOME/src/github.com/ooni/probe-cli/internal/netxlite/http3.go:35 +0x25
github.com/ooni/probe-cli/v3/internal/netxlite.(*HTTPTransportLogger).logTrip(0xc0002c7c40, 0xc00021e300)
        $HOME/src/github.com/ooni/probe-cli/internal/netxlite/http.go:50 +0x1ff
github.com/ooni/probe-cli/v3/internal/netxlite.(*HTTPTransportLogger).RoundTrip(0x0, 0xc00021e300)
        $HOME/src/github.com/ooni/probe-cli/internal/netxlite/http.go:38 +0x105
github.com/ooni/probe-cli/v3/internal/engine/netx/httptransport.SaverMetadataHTTPTransport.RoundTrip({{0xf86e78, 0xc0002c7c40}, 0xc0002c7b40, {0xe2889e, 0x4}}, 0xc00021e300)
        $HOME/src/github.com/ooni/probe-cli/internal/engine/netx/httptransport/saver.go:62 +0x196
github.com/ooni/probe-cli/v3/internal/engine/netx/httptransport.SaverBodyHTTPTransport.RoundTrip({{0xf88cc8, 0xc000115e00}, 0xc0002c7b40, 0xde8c40}, 0xc00021e300)
        $HOME/src/github.com/ooni/probe-cli/internal/engine/netx/httptransport/saver.go:125 +0x3e3
github.com/ooni/probe-cli/v3/internal/engine/netx/httptransport.SaverPerformanceHTTPTransport.RoundTrip({{0xf88ca0, 0xc0002c7c60}, 0xc0002c7b40}, 0xc00021e200)
        $HOME/src/github.com/ooni/probe-cli/internal/engine/netx/httptransport/saver.go:41 +0x406
github.com/ooni/probe-cli/v3/internal/engine/netx/httptransport.SaverTransactionHTTPTransport.RoundTrip({{0xf88cf0, 0xc0000b4360}, 0xc0002c7b40}, 0xa)
        $HOME/src/github.com/ooni/probe-cli/internal/engine/netx/httptransport/saver.go:88 +0x126

@bassosimone
Copy link
Contributor Author

Superseded by #448.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant