refactor: migrate apitool from netx to netxlite (#496)
I discovered which transport were used by apitool and made sure he gets the same transports now. While there, I discovered an issue with ooni/oohttp that has been fixed with https://github.com/ooni/oohttp/commit/cba9b1ce5ecf7a20217ad8571ad7a85e490c4789. Part of https://github.com/ooni/probe/issues/1591
This commit is contained in:
@@ -18,14 +18,14 @@ import (
|
||||
"github.com/apex/log"
|
||||
"github.com/ooni/probe-cli/v3/internal/atomicx"
|
||||
"github.com/ooni/probe-cli/v3/internal/engine/httpx"
|
||||
"github.com/ooni/probe-cli/v3/internal/engine/netx"
|
||||
"github.com/ooni/probe-cli/v3/internal/engine/probeservices"
|
||||
"github.com/ooni/probe-cli/v3/internal/kvstore"
|
||||
"github.com/ooni/probe-cli/v3/internal/netxlite"
|
||||
"github.com/ooni/probe-cli/v3/internal/version"
|
||||
)
|
||||
|
||||
func newclient() probeservices.Client {
|
||||
txp := netx.NewHTTPTransport(netx.Config{Logger: log.Log})
|
||||
txp := netxlite.NewHTTPTransportStdlib(log.Log)
|
||||
ua := fmt.Sprintf("apitool/%s ooniprobe-engine/%s", version.Version, version.Version)
|
||||
return probeservices.Client{
|
||||
Client: httpx.Client{
|
||||
|
||||
Reference in New Issue
Block a user