Skip to content

Commit

Permalink
update to use aaronland/go-sqlite/v2
Browse files Browse the repository at this point in the history
  • Loading branch information
sfomuseumbot committed Dec 1, 2022
1 parent 0dc2951 commit 02c89dc
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 11 deletions.
6 changes: 3 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
module github.com/whosonfirst/go-whosonfirst-sqlite-spr
module github.com/whosonfirst/go-whosonfirst-sqlite-spr/v2

go 1.18

require (
github.com/aaronland/go-pagination v0.2.0
github.com/aaronland/go-pagination-sql v0.2.0
github.com/aaronland/go-sqlite v0.2.2
github.com/aaronland/go-sqlite/v2 v2.2.0
github.com/sfomuseum/go-edtf v1.1.1
github.com/whosonfirst/go-whosonfirst-flags v0.4.4
github.com/whosonfirst/go-whosonfirst-spr/v2 v2.3.3
github.com/whosonfirst/go-whosonfirst-uri v1.2.0
)

require (
github.com/aaronland/go-roster v1.0.0 // indirect
github.com/jtacoma/uritemplates v1.0.0 // indirect
github.com/mattn/go-sqlite3 v1.14.16 // indirect
github.com/paulmach/orb v0.7.1 // indirect
github.com/tidwall/gjson v1.14.1 // indirect
github.com/tidwall/match v1.1.1 // indirect
Expand Down
8 changes: 4 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@ github.com/aaronland/go-pagination v0.2.0 h1:ZZ8mNu5oEK5wanAjbYAaE3w5eyQKzFOWu/g
github.com/aaronland/go-pagination v0.2.0/go.mod h1:zrYVkUTBoe6yJ23l6OyTyfSpTyg6s/cNxZxNztXNQpQ=
github.com/aaronland/go-pagination-sql v0.2.0 h1:WVesObJVvwawIgkl6Twot9DXia09qiZQJQ/7ik64kSU=
github.com/aaronland/go-pagination-sql v0.2.0/go.mod h1:Thovmz045/sxI0actKFyGLzIKmlCK4R9Qi4gS742PbY=
github.com/aaronland/go-sqlite v0.2.2 h1:lWLgp4ZpVQkVWUI+F3f3/MNKKOkaTr6iLHGBGg7sm8s=
github.com/aaronland/go-sqlite v0.2.2/go.mod h1:GPFZKO98fn7onei3ypYioxxni/0Hbvq+6Z8YaaL1cQY=
github.com/aaronland/go-roster v1.0.0 h1:FRDGrTqsYySKjWnAhbBGXyeGlI/o5/t9FZYCbUmyQtI=
github.com/aaronland/go-roster v1.0.0/go.mod h1:KIsYZgrJlAsyb9LsXSCvlqvbcCBVjCSqcQiZx42i9ro=
github.com/aaronland/go-sqlite/v2 v2.2.0 h1:Efase4L+f5LgWYEHiA/dUwEuNzJgJdjOVElHMvGEZRw=
github.com/aaronland/go-sqlite/v2 v2.2.0/go.mod h1:CI0V49+b2LZvf27tSFPJ9jw6F594gHxrtVt+OdMT3TU=
github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q=
github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk=
github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
Expand All @@ -13,8 +15,6 @@ github.com/jtacoma/uritemplates v1.0.0 h1:xwx5sBF7pPAb0Uj8lDC1Q/aBPpOFyQza7OC705
github.com/jtacoma/uritemplates v1.0.0/go.mod h1:IhIICdE9OcvgUnGwTtJxgBQ+VrTrti5PcbLVSJianO8=
github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8=
github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
github.com/mattn/go-sqlite3 v1.14.16 h1:yOQRA0RpS5PFz/oikGwBEqvAWhWg5ufRz4ETLjwpU1Y=
github.com/mattn/go-sqlite3 v1.14.16/go.mod h1:2eHXhiwb8IkHr+BDWZGa96P6+rkvnG63S2DGjv9HUNg=
github.com/paulmach/orb v0.7.1 h1:Zha++Z5OX/l168sqHK3k4z18LDvr+YAO/VjK0ReQ9rU=
github.com/paulmach/orb v0.7.1/go.mod h1:FWRlTgl88VI1RBx/MkrwWDRhQ96ctqMCh8boXhmqB/A=
github.com/paulmach/protoscan v0.2.1/go.mod h1:SpcSwydNLrxUGSDvXvO0P7g7AuhJ7lcKfDlhJCDw2gY=
Expand Down
7 changes: 3 additions & 4 deletions spr.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ import (
"context"
"database/sql"
"fmt"
"github.com/aaronland/go-sqlite"
sqlite_database "github.com/aaronland/go-sqlite/database"
"github.com/aaronland/go-sqlite/v2"
"github.com/sfomuseum/go-edtf"
"github.com/sfomuseum/go-edtf/parser"
"github.com/whosonfirst/go-whosonfirst-flags"
Expand Down Expand Up @@ -175,9 +174,9 @@ func (spr *SQLiteStandardPlacesResult) LastModified() int64 {
return spr.WOFLastModified
}

func RetrieveSPR(ctx context.Context, spr_db *sqlite_database.SQLiteDatabase, spr_table sqlite.Table, id int64, alt_label string) (wof_spr.StandardPlacesResult, error) {
func RetrieveSPR(ctx context.Context, spr_db sqlite.Database, spr_table sqlite.Table, id int64, alt_label string) (wof_spr.StandardPlacesResult, error) {

conn, err := spr_db.Conn()
conn, err := spr_db.Conn(ctx)

if err != nil {
return nil, err
Expand Down

0 comments on commit 02c89dc

Please sign in to comment.