Skip to content

Problem on migrating from 4.1.0 to 5.0.0 #1273

@clmntpllr

Description

@clmntpllr

After installing the 5.0.0 rpm package (Rhel 8.10), I launched the command pgwatch config upgrade
and got the error :

2026-03-04 09:32:04.095 [ERROR] [callstack:goroutine 1 [running]:
runtime/debug.Stack()
        /opt/hostedtoolcache/go/1.26.0/x64/src/runtime/debug/stack.go:26 +0x5e
main.main.func1()
        /home/runner/work/pgwatch/pgwatch/cmd/pgwatch/main.go:50 +0xc5
panic({0xed6520?, 0x2f92cf4a6d20?})
        /opt/hostedtoolcache/go/1.26.0/x64/src/runtime/panic.go:860 +0x13a
github.com/cybertec-postgresql/pgwatch/v5/internal/cmdopts.(*ConfigUpgradeCommand).Execute.func1({0x2f92cf05805b, 0x3f}, 0x2f92cf2c1b20)
        /home/runner/work/pgwatch/pgwatch/internal/cmdopts/cmdconfig.go:110 +0x159
github.com/cybertec-postgresql/pgwatch/v5/internal/cmdopts.(*ConfigUpgradeCommand).Execute(0x1bc7070?, {0xeadc80?, 0x7f96a4b2da01?, 0x7f96eb7e04e8?})
        /home/runner/work/pgwatch/pgwatch/internal/cmdopts/cmdconfig.go:114 +0xad
github.com/jessevdk/go-flags.(*Parser).ParseArgs(0x2f92cf3bc070, {0x2f92cf050550, 0x2, 0x2})
        /home/runner/go/pkg/mod/github.com/jessevdk/go-flags@v1.6.1/parser.go:339 +0xacc
github.com/jessevdk/go-flags.(*Parser).Parse(...)
        /home/runner/go/pkg/mod/github.com/jessevdk/go-flags@v1.6.1/parser.go:195
github.com/cybertec-postgresql/pgwatch/v5/internal/cmdopts.New({0x12106e0, 0x2f92cf014040})
        /home/runner/work/pgwatch/pgwatch/internal/cmdopts/cmdoptions.go:76 +0xd9
main.main()
        /home/runner/work/pgwatch/pgwatch/cmd/pgwatch/main.go:59 +0xd7
] interface conversion: *sources.dbSourcesReaderWriter is not db.Migrator: missing method Migrate

The pgwatch.log ask me to lauch that command : {"level":"error","msg":"sink database schema is outdated, please run migrations using ``pgwatch config upgrade`` command","time":"2026-03-04T09:31:03+01:00"}

Thanks for your help !
Regards
Clément

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingsourcesWhat sources and in what way to monitor

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions