From 45cda9844ca8b5ffe48c61aeaeca6d0c23c06029 Mon Sep 17 00:00:00 2001 From: Nate Maninger Date: Sun, 1 Sep 2024 10:00:09 -0700 Subject: [PATCH 1/2] sqlite: add migration to drop registry columns from v2 --- persist/sqlite/migrations.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/persist/sqlite/migrations.go b/persist/sqlite/migrations.go index 31cac350..88b06a47 100644 --- a/persist/sqlite/migrations.go +++ b/persist/sqlite/migrations.go @@ -10,6 +10,13 @@ import ( "go.uber.org/zap" ) +func migrateVersion30(tx *txn, _ *zap.Logger) error { + _, err := tx.Exec(` +ALTER TABLE contracts_v2 DROP COLUMN registry_read; +ALTER TABLE contracts_v2 DROP COLUMN registry_write;`) + return err +} + // migrateVersion29 resets the chain state to trigger a full rescan of the // wallet to calculate the new immature balance metric. func migrateVersion29(tx *txn, _ *zap.Logger) error { @@ -915,4 +922,5 @@ var migrations = []func(tx *txn, log *zap.Logger) error{ migrateVersion27, migrateVersion28, migrateVersion29, + migrateVersion30, } From c5335f77487bc8074414236575490878abd808a3 Mon Sep 17 00:00:00 2001 From: Nate Maninger Date: Sun, 1 Sep 2024 15:23:27 -0700 Subject: [PATCH 2/2] deps: update core and coreutils --- go.mod | 4 ++-- go.sum | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/go.mod b/go.mod index 6710c99c..8465e707 100644 --- a/go.mod +++ b/go.mod @@ -8,8 +8,8 @@ require ( github.com/hashicorp/golang-lru/v2 v2.0.7 github.com/mattn/go-sqlite3 v1.14.22 github.com/shopspring/decimal v1.4.0 - go.sia.tech/core v0.4.5-0.20240831170056-a91ba45f50d6 - go.sia.tech/coreutils v0.3.1-0.20240831170413-70443a42b7b2 + go.sia.tech/core v0.4.5 + go.sia.tech/coreutils v0.3.1 go.sia.tech/jape v0.12.1 go.sia.tech/web/hostd v0.46.0 go.uber.org/goleak v1.3.0 diff --git a/go.sum b/go.sum index ddf26d4a..72b4b9c4 100644 --- a/go.sum +++ b/go.sum @@ -42,10 +42,10 @@ github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsT github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= go.etcd.io/bbolt v1.3.11 h1:yGEzV1wPz2yVCLsD8ZAiGHhHVlczyC9d1rP43/VCRJ0= go.etcd.io/bbolt v1.3.11/go.mod h1:dksAq7YMXoljX0xu6VF5DMZGbhYYoLUalEiSySYAS4I= -go.sia.tech/core v0.4.5-0.20240831170056-a91ba45f50d6 h1:ad4dKiZnjumnAZvpy9x+yK+djIQIJYXjmazH5jxcweE= -go.sia.tech/core v0.4.5-0.20240831170056-a91ba45f50d6/go.mod h1:Zuq0Tn2aIXJyO0bjGu8cMeVWe+vwQnUfZhG1LCmjD5c= -go.sia.tech/coreutils v0.3.1-0.20240831170413-70443a42b7b2 h1:ibPgvT9ICWvKKqj7Avk6jpz1BgxyiFsKEJEPM+powzA= -go.sia.tech/coreutils v0.3.1-0.20240831170413-70443a42b7b2/go.mod h1:yI2eAuWhkjpSfDsgsczCkeruBkoc1guAI226ZzGqqZk= +go.sia.tech/core v0.4.5 h1:w2D3Mx29UmK1aFd9R7uHFo5JUSTqu3+92NHoRFv3CaU= +go.sia.tech/core v0.4.5/go.mod h1:Zuq0Tn2aIXJyO0bjGu8cMeVWe+vwQnUfZhG1LCmjD5c= +go.sia.tech/coreutils v0.3.1 h1:FLIBM4ryLFvwkZVv8Yyn3KZsUdqX6pX8moS3xfQX5M0= +go.sia.tech/coreutils v0.3.1/go.mod h1:qOBvtTS14Q2lSbY+S3u39AntpttL5kuIv7P8NktKYw0= go.sia.tech/jape v0.12.1 h1:xr+o9V8FO8ScRqbSaqYf9bjj1UJ2eipZuNcI1nYousU= go.sia.tech/jape v0.12.1/go.mod h1:wU+h6Wh5olDjkPXjF0tbZ1GDgoZ6VTi4naFw91yyWC4= go.sia.tech/mux v1.2.0 h1:ofa1Us9mdymBbGMY2XH/lSpY8itFsKIo/Aq8zwe+GHU=