From b624de9620090c3433e17e56d7cc6d3353f281da Mon Sep 17 00:00:00 2001 From: ryan Date: Sat, 29 Aug 2026 11:11:51 +0800 Subject: [PATCH] feat(cmd): log actual plugin migration version instead of up-to-date --- backend/cmd/app.go | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/backend/cmd/app.go b/backend/cmd/app.go index 099a0154..5d5321d6 100644 --- a/backend/cmd/app.go +++ b/backend/cmd/app.go @@ -285,10 +285,15 @@ func (e *gooseEngine) Migrate(ctx *core.Context, entries []core.MigrationEntry) return fmt.Errorf("migration %s: apply %w", entry.PluginID, err) } + version, vErr := provider.GetDBVersion(context.Background()) + if vErr != nil { + version = 0 + } + if len(results) > 0 { - log.Printf("[migrate] %s: applied %d migration(s)", entry.PluginID, len(results)) + log.Printf("[migrate] %s: applied %d migration(s) (v%d)", entry.PluginID, len(results), version) } else { - log.Printf("[migrate] %s: up to date", entry.PluginID) + log.Printf("[migrate] %s: v%d", entry.PluginID, version) } }