From 5c969fcf23f5e8a1d2b3db01aa3d94ac4f90d7a2 Mon Sep 17 00:00:00 2001 From: "Antoine C." Date: Sun, 14 Sep 2025 18:21:44 +0100 Subject: [PATCH] fix: don't override unstable version with the current alpha --- src/preferences/upgrade.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/preferences/upgrade.cpp b/src/preferences/upgrade.cpp index 3406ef54b162..5b7724338a93 100644 --- a/src/preferences/upgrade.cpp +++ b/src/preferences/upgrade.cpp @@ -628,7 +628,8 @@ UserSettingsPointer Upgrade::versionUpgrade(const QString& settingsPath) { // If additional upgrades are added for later versions, they should go before // this block and cleanVersion should be bumped to the latest version. const QVersionNumber cleanVersion(2, 6, 0); - if (QVersionNumber::fromString(configVersion) >= cleanVersion) { + if (QVersionNumber::fromString(configVersion) >= cleanVersion && + configVersion != VersionStore::FUTURE_UNSTABLE) { // No special upgrade required, just update the value. configVersion = VersionStore::version(); config->set(ConfigKey("[Config]", "Version"), ConfigValue(VersionStore::version())); @@ -636,6 +637,9 @@ UserSettingsPointer Upgrade::versionUpgrade(const QString& settingsPath) { if (configVersion == VersionStore::version()) { qDebug() << "Configuration file is now at the current version" << VersionStore::version(); + } else if (configVersion == VersionStore::FUTURE_UNSTABLE) { + qDebug() << "Configuration file is now at the unstable version" + << VersionStore::FUTURE_UNSTABLE; } else { qWarning() << "Configuration file is at version" << configVersion << "instead of the current" << VersionStore::version();