Skip to content

Commit

Permalink
Update to use juju/utils/v3
Browse files Browse the repository at this point in the history
  • Loading branch information
wallyworld committed Jan 31, 2022
1 parent 4d65952 commit 183cbcf
Show file tree
Hide file tree
Showing 541 changed files with 657 additions and 690 deletions.
4 changes: 2 additions & 2 deletions agent/agent.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ import (
"github.com/juju/errors"
"github.com/juju/loggo"
"github.com/juju/names/v4"
"github.com/juju/utils/v2"
"github.com/juju/utils/v2/shell"
"github.com/juju/utils/v3"
"github.com/juju/utils/v3/shell"
"github.com/juju/version/v2"

"github.com/juju/juju/api"
Expand Down
2 changes: 1 addition & 1 deletion agent/agentbootstrap/bootstrap.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (
"github.com/juju/mgo/v2"
"github.com/juju/names/v4"
"github.com/juju/os/v2/series"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"

"github.com/juju/juju/agent"
apiagent "github.com/juju/juju/api/agent"
Expand Down
2 changes: 1 addition & 1 deletion agent/agentbootstrap/bootstrap_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
"github.com/juju/names/v4"
gitjujutesting "github.com/juju/testing"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/agent"
Expand Down
2 changes: 1 addition & 1 deletion agent/format-2.0_whitebox_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
"path/filepath"

jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
"github.com/juju/version/v2"
gc "gopkg.in/check.v1"

Expand Down
2 changes: 1 addition & 1 deletion agent/identity.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"os"

"github.com/juju/errors"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
)

var ErrNoStateServingInfo = errors.New("StateServingInfo missing")
Expand Down
2 changes: 1 addition & 1 deletion agent/tools/symlinks.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"path/filepath"

"github.com/juju/errors"
"github.com/juju/utils/v2/symlink"
"github.com/juju/utils/v3/symlink"

"github.com/juju/juju/juju/names"
)
Expand Down
4 changes: 2 additions & 2 deletions agent/tools/symlinks_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ import (
"time"

jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v2/symlink"
"github.com/juju/utils/v3"
"github.com/juju/utils/v3/symlink"
gc "gopkg.in/check.v1"

"github.com/juju/juju/agent/tools"
Expand Down
2 changes: 1 addition & 1 deletion agent/tools/toolsdir.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (
"strings"

"github.com/juju/errors"
"github.com/juju/utils/v2/symlink"
"github.com/juju/utils/v3/symlink"
"github.com/juju/version/v2"

coretools "github.com/juju/juju/tools"
Expand Down
2 changes: 1 addition & 1 deletion api/agent/unit_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (

"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/api"
Expand Down
10 changes: 6 additions & 4 deletions api/apiclient.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ import (
jujuhttp "github.com/juju/http/v2"
"github.com/juju/loggo"
"github.com/juju/names/v4"
"github.com/juju/utils/v2"
"github.com/juju/utils/v2/parallel"
"github.com/juju/utils/v3"
"github.com/juju/utils/v3/parallel"
"github.com/juju/version/v2"
"gopkg.in/macaroon.v2"
"gopkg.in/retry.v1"
Expand Down Expand Up @@ -242,8 +242,10 @@ func Open(info *Info, opts DialOpts) (Connection, error) {
// for everything, but it's easier just to leave it in place.
bakeryClient.Client.Transport = &hostSwitchingTransport{
primaryHost: dialResult.addr,
primary: utils.NewHttpTLSTransport(dialResult.tlsConfig),
fallback: http.DefaultTransport,
primary: jujuhttp.NewHTTPTLSTransport(jujuhttp.TransportConfig{
TLSConfig: dialResult.tlsConfig,
}),
fallback: http.DefaultTransport,
}

// Prefer the SNI hostname or controller name for the cookie URL
Expand Down
2 changes: 1 addition & 1 deletion api/certpool.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"path/filepath"

"github.com/juju/errors"
"github.com/juju/utils/v2/cert"
"github.com/juju/utils/v3/cert"

"github.com/juju/juju/core/paths"
)
Expand Down
2 changes: 1 addition & 1 deletion api/controller/controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (
"github.com/juju/names/v4"
jujutesting "github.com/juju/testing"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"
"gopkg.in/macaroon.v2"

Expand Down
2 changes: 1 addition & 1 deletion api/firewaller/firewaller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ package firewaller_test
import (
"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/api"
Expand Down
2 changes: 1 addition & 1 deletion api/keymanager/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
package keymanager

import (
"github.com/juju/utils/v2/ssh"
"github.com/juju/utils/v3/ssh"

"github.com/juju/juju/api/base"
"github.com/juju/juju/apiserver/params"
Expand Down
4 changes: 2 additions & 2 deletions api/keymanager/client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (

"github.com/juju/errors"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2/ssh"
sshtesting "github.com/juju/utils/v2/ssh/testing"
"github.com/juju/utils/v3/ssh"
sshtesting "github.com/juju/utils/v3/ssh/testing"
gc "gopkg.in/check.v1"

"github.com/juju/juju/api/keymanager"
Expand Down
2 changes: 1 addition & 1 deletion api/machineactions/machineactions_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"github.com/juju/names/v4"
jujutesting "github.com/juju/testing"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

apitesting "github.com/juju/juju/api/base/testing"
Expand Down
2 changes: 1 addition & 1 deletion api/metricsadder/client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (

"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/api/metricsadder"
Expand Down
2 changes: 1 addition & 1 deletion api/migrationmaster/client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
"github.com/juju/names/v4"
jujutesting "github.com/juju/testing"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
"github.com/juju/version/v2"
gc "gopkg.in/check.v1"
"gopkg.in/httprequest.v1"
Expand Down
4 changes: 2 additions & 2 deletions api/provisioner/provisioner_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ import (
"github.com/juju/errors"
"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v2/arch"
"github.com/juju/utils/v3"
"github.com/juju/utils/v3/arch"
gc "gopkg.in/check.v1"

"github.com/juju/juju/api"
Expand Down
2 changes: 1 addition & 1 deletion api/resources/client/client_upload_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (
apicharm "github.com/juju/juju/api/common/charm"
"github.com/juju/testing"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/api/resources/client"
Expand Down
2 changes: 1 addition & 1 deletion api/state.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (
"github.com/juju/errors"
"github.com/juju/featureflag"
"github.com/juju/names/v4"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
"github.com/juju/version/v2"
"gopkg.in/macaroon.v2"

Expand Down
2 changes: 1 addition & 1 deletion api/state_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"github.com/juju/errors"
"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"
"gopkg.in/macaroon.v2"

Expand Down
2 changes: 1 addition & 1 deletion api/uniter/unit_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (
"github.com/juju/names/v4"
"github.com/juju/testing"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

basetesting "github.com/juju/juju/api/base/testing"
Expand Down
2 changes: 1 addition & 1 deletion api/upgrader/unitupgrader_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ package upgrader_test
import (
"github.com/juju/errors"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
"github.com/juju/version/v2"
gc "gopkg.in/check.v1"

Expand Down
2 changes: 1 addition & 1 deletion api/watcher/watcher_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (
"github.com/go-macaroon-bakery/macaroon-bakery/v3/bakery/checkers"
"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
"github.com/juju/worker/v3"
"github.com/juju/worker/v3/workertest"
gc "gopkg.in/check.v1"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/admin_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import (
"github.com/juju/loggo"
"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/api"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/apiserver_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import (
"github.com/juju/loggo"
"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
"github.com/juju/worker/v3/dependency"
"github.com/juju/worker/v3/workertest"
gc "gopkg.in/check.v1"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/authentication/agent_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"context"

jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/apiserver/authentication"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/authentication/user_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
"github.com/juju/names/v4"
"github.com/juju/testing"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"
"gopkg.in/macaroon.v2"

Expand Down
2 changes: 1 addition & 1 deletion apiserver/backup_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (

"github.com/juju/errors"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/apiserver"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/charms.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import (

"github.com/juju/charm/v8"
"github.com/juju/errors"
ziputil "github.com/juju/utils/v2/zip"
ziputil "github.com/juju/utils/v3/zip"

"github.com/juju/juju/apiserver/common"
apiservererrors "github.com/juju/juju/apiserver/errors"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/charms_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (

"github.com/juju/charm/v8"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/apiserver/common"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/common/action_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"github.com/juju/errors"
"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/apiserver/common"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/common/cloudspec/cloudspec_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"github.com/juju/names/v4"
"github.com/juju/testing"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/apiserver/common"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/common/common_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (

"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/apiserver/common"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/common/controllerconfig_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"github.com/juju/errors"
"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/apiserver/common"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/common/crossmodel/auth_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (
"github.com/juju/errors"
"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"
"gopkg.in/macaroon.v2"

Expand Down
2 changes: 1 addition & 1 deletion apiserver/common/leadership_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"github.com/juju/errors"
"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"
gc "gopkg.in/check.v1"

"github.com/juju/juju/apiserver/common"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/common/tools_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"github.com/juju/errors"
"github.com/juju/names/v4"
jc "github.com/juju/testing/checkers"
"github.com/juju/utils/v2/arch"
"github.com/juju/utils/v3/arch"
"github.com/juju/version/v2"
gc "gopkg.in/check.v1"

Expand Down
2 changes: 1 addition & 1 deletion apiserver/facades/agent/caasapplication/application.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
"github.com/juju/loggo"
"github.com/juju/names/v4"
"github.com/juju/retry"
"github.com/juju/utils/v2"
"github.com/juju/utils/v3"

"github.com/juju/juju/agent"
apiservererrors "github.com/juju/juju/apiserver/errors"
Expand Down
2 changes: 1 addition & 1 deletion apiserver/facades/agent/keyupdater/authorisedkeys.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ package keyupdater
import (
"github.com/juju/errors"
"github.com/juju/names/v4"
"github.com/juju/utils/v2/ssh"
"github.com/juju/utils/v3/ssh"

"github.com/juju/juju/apiserver/common"
apiservererrors "github.com/juju/juju/apiserver/errors"
Expand Down
Loading

0 comments on commit 183cbcf

Please sign in to comment.