From 405e9eec49810699b40a7201f5c08d57d8e19272 Mon Sep 17 00:00:00 2001 From: John McPherson Date: Tue, 2 Jul 2024 14:57:47 -0700 Subject: [PATCH] Remove experimental from index v2 --- doc/Settings.md | 17 ----------------- schemas/JSON/settings/settings.schema.0.2.json | 5 ----- .../ExperimentalFeature.cpp | 4 ---- .../Public/winget/ExperimentalFeature.h | 1 - .../Public/winget/UserSettings.h | 2 -- src/AppInstallerCommonCore/UserSettings.cpp | 1 - .../PreIndexedPackageSourceFactory.cpp | 12 ++---------- 7 files changed, 2 insertions(+), 40 deletions(-) diff --git a/doc/Settings.md b/doc/Settings.md index 5c24f4feff..e79bb04b18 100644 --- a/doc/Settings.md +++ b/doc/Settings.md @@ -333,20 +333,3 @@ You can enable the feature as shown below. "configureExport": true }, ``` - -### indexV2 - -This feature enables the `winget` source to retrieve the V2 index, which is significantly smaller. -Regardless of the state of this feature, if the index on the machine contains a V2 index, it will be used. -If there is a bug with the V2 index stopping the `winget` CLI from working, disable the feature in your settings file and run this command: -``` -> winget uninstall -s msstore Microsoft.Winget.Source_8wekyb3d8bbwe -``` - -You can enable the feature as shown below. - -```json - "experimentalFeatures": { - "indexV2": true - }, -``` diff --git a/schemas/JSON/settings/settings.schema.0.2.json b/schemas/JSON/settings/settings.schema.0.2.json index ca65700d61..86b8c8842e 100644 --- a/schemas/JSON/settings/settings.schema.0.2.json +++ b/schemas/JSON/settings/settings.schema.0.2.json @@ -280,11 +280,6 @@ "description": "Enable support for the configure export command", "type": "boolean", "default": false - }, - "indexV2": { - "description": "Enable retrieving the V2 index for the winget source", - "type": "boolean", - "default": false } } } diff --git a/src/AppInstallerCommonCore/ExperimentalFeature.cpp b/src/AppInstallerCommonCore/ExperimentalFeature.cpp index 7222dcbbc2..733ff9ccd5 100644 --- a/src/AppInstallerCommonCore/ExperimentalFeature.cpp +++ b/src/AppInstallerCommonCore/ExperimentalFeature.cpp @@ -46,8 +46,6 @@ namespace AppInstaller::Settings return userSettings.Get(); case ExperimentalFeature::Feature::ConfigureSelfElevation: return userSettings.Get(); - case ExperimentalFeature::Feature::IndexV2: - return userSettings.Get(); case ExperimentalFeature::Feature::ConfigureExport: return userSettings.Get(); default: @@ -85,8 +83,6 @@ namespace AppInstaller::Settings return ExperimentalFeature{ "Configuration Schema 0.3", "configuration03", "https://aka.ms/winget-settings", Feature::Configuration03 }; case Feature::ConfigureSelfElevation: return ExperimentalFeature{ "Configure Self Elevation", "configureSelfElevate", "https://aka.ms/winget-settings", Feature::ConfigureSelfElevation }; - case Feature::IndexV2: - return ExperimentalFeature{ "Index V2", "indexV2", "https://aka.ms/winget-settings", Feature::IndexV2 }; case Feature::ConfigureExport: return ExperimentalFeature{ "Configure Export", "configureExport", "https://aka.ms/winget-settings", Feature::ConfigureExport }; default: diff --git a/src/AppInstallerCommonCore/Public/winget/ExperimentalFeature.h b/src/AppInstallerCommonCore/Public/winget/ExperimentalFeature.h index 86fb1d9af2..733f1aa453 100644 --- a/src/AppInstallerCommonCore/Public/winget/ExperimentalFeature.h +++ b/src/AppInstallerCommonCore/Public/winget/ExperimentalFeature.h @@ -27,7 +27,6 @@ namespace AppInstaller::Settings Configuration03 = 0x4, ConfigureSelfElevation = 0x8, ConfigureExport = 0x10, - IndexV2 = 0x20, Max, // This MUST always be after all experimental features // Features listed after Max will not be shown with the features command diff --git a/src/AppInstallerCommonCore/Public/winget/UserSettings.h b/src/AppInstallerCommonCore/Public/winget/UserSettings.h index 4203011c1f..0abf1ac1c0 100644 --- a/src/AppInstallerCommonCore/Public/winget/UserSettings.h +++ b/src/AppInstallerCommonCore/Public/winget/UserSettings.h @@ -74,7 +74,6 @@ namespace AppInstaller::Settings EFResume, EFConfiguration03, EFConfigureSelfElevation, - EFIndexV2, EFConfigureExport, // Telemetry TelemetryDisable, @@ -157,7 +156,6 @@ namespace AppInstaller::Settings SETTINGMAPPING_SPECIALIZATION(Setting::EFResume, bool, bool, false, ".experimentalFeatures.resume"sv); SETTINGMAPPING_SPECIALIZATION(Setting::EFConfiguration03, bool, bool, false, ".experimentalFeatures.configuration03"sv); SETTINGMAPPING_SPECIALIZATION(Setting::EFConfigureSelfElevation, bool, bool, false, ".experimentalFeatures.configureSelfElevate"sv); - SETTINGMAPPING_SPECIALIZATION(Setting::EFIndexV2, bool, bool, true, ".experimentalFeatures.indexV2"sv); SETTINGMAPPING_SPECIALIZATION(Setting::EFConfigureExport, bool, bool, false, ".experimentalFeatures.configureExport"sv); // Telemetry SETTINGMAPPING_SPECIALIZATION(Setting::TelemetryDisable, bool, bool, false, ".telemetry.disable"sv); diff --git a/src/AppInstallerCommonCore/UserSettings.cpp b/src/AppInstallerCommonCore/UserSettings.cpp index 9654db02bb..ea2ef2271a 100644 --- a/src/AppInstallerCommonCore/UserSettings.cpp +++ b/src/AppInstallerCommonCore/UserSettings.cpp @@ -262,7 +262,6 @@ namespace AppInstaller::Settings WINGET_VALIDATE_PASS_THROUGH(EFResume) WINGET_VALIDATE_PASS_THROUGH(EFConfiguration03) WINGET_VALIDATE_PASS_THROUGH(EFConfigureSelfElevation) - WINGET_VALIDATE_PASS_THROUGH(EFIndexV2) WINGET_VALIDATE_PASS_THROUGH(EFConfigureExport) WINGET_VALIDATE_PASS_THROUGH(AnonymizePathForDisplay) WINGET_VALIDATE_PASS_THROUGH(TelemetryDisable) diff --git a/src/AppInstallerRepositoryCore/Microsoft/PreIndexedPackageSourceFactory.cpp b/src/AppInstallerRepositoryCore/Microsoft/PreIndexedPackageSourceFactory.cpp index 2ae114094c..b688d7b25a 100644 --- a/src/AppInstallerRepositoryCore/Microsoft/PreIndexedPackageSourceFactory.cpp +++ b/src/AppInstallerRepositoryCore/Microsoft/PreIndexedPackageSourceFactory.cpp @@ -47,20 +47,12 @@ namespace AppInstaller::Repository::Microsoft std::vector result; - if (Settings::ExperimentalFeature::IsEnabled(Settings::ExperimentalFeature::Feature::IndexV2)) - { - result.emplace_back(GetPackageLocation(details.Arg, s_PreIndexedPackageSourceFactory_V2_PackageFileName)); - } - + result.emplace_back(GetPackageLocation(details.Arg, s_PreIndexedPackageSourceFactory_V2_PackageFileName)); result.emplace_back(GetPackageLocation(details.Arg, s_PreIndexedPackageSourceFactory_PackageFileName)); if (!details.AlternateArg.empty()) { - if (Settings::ExperimentalFeature::IsEnabled(Settings::ExperimentalFeature::Feature::IndexV2)) - { - result.emplace_back(GetPackageLocation(details.AlternateArg, s_PreIndexedPackageSourceFactory_V2_PackageFileName)); - } - + result.emplace_back(GetPackageLocation(details.AlternateArg, s_PreIndexedPackageSourceFactory_V2_PackageFileName)); result.emplace_back(GetPackageLocation(details.AlternateArg, s_PreIndexedPackageSourceFactory_PackageFileName)); }