chore: upgrade to github.com/upper/db/v4 (#705)
* Upgrade to github.com/upper/db/v4 * fix(oonitest): repair imports after merge Oops, okay, it seems the merge did not preserve all the import changes, so let's ensure we use the right imports here! * cleanup(go.mod): don't refer to upper.io/db/v3 These lines didn't disappear previously because the merge commit failed to remove all references to upper.io/db/v3. Co-authored-by: stergem <sgemelas@protonmail.com> Co-authored-by: Simone Basso <bassosimone@gmail.com>
This commit is contained in:
@@ -19,7 +19,7 @@ import (
|
||||
"github.com/ooni/probe-cli/v3/internal/kvstore"
|
||||
"github.com/ooni/probe-cli/v3/internal/model"
|
||||
"github.com/pkg/errors"
|
||||
"upper.io/db.v3/lib/sqlbuilder"
|
||||
"github.com/upper/db/v4"
|
||||
)
|
||||
|
||||
// DefaultSoftwareName is the default software name.
|
||||
@@ -28,7 +28,7 @@ const DefaultSoftwareName = "ooniprobe-cli"
|
||||
// ProbeCLI is the OONI Probe CLI context.
|
||||
type ProbeCLI interface {
|
||||
Config() *config.Config
|
||||
DB() sqlbuilder.Database
|
||||
DB() db.Session
|
||||
IsBatch() bool
|
||||
Home() string
|
||||
TempDir() string
|
||||
@@ -48,7 +48,7 @@ type ProbeEngine interface {
|
||||
// Probe contains the ooniprobe CLI context.
|
||||
type Probe struct {
|
||||
config *config.Config
|
||||
db sqlbuilder.Database
|
||||
db db.Session
|
||||
isBatch bool
|
||||
|
||||
home string
|
||||
@@ -80,7 +80,7 @@ func (p *Probe) Config() *config.Config {
|
||||
}
|
||||
|
||||
// DB returns the database we're using
|
||||
func (p *Probe) DB() sqlbuilder.Database {
|
||||
func (p *Probe) DB() db.Session {
|
||||
return p.db
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user