{"record":{"id":"dbb452765c128541","repo":"microsoft/aspire","slug":"aspire-skills-bundle-supports-aspire-cli-versions-0-but-the","errorCode":null,"errorMessage":"Aspire skills bundle supports Aspire CLI versions '{0}', but the current CLI version is '{1}'.","messagePattern":"Aspire skills bundle supports Aspire CLI versions '(.+?)', but the current CLI version is '(.+?)'\\.","errorType":"exception","errorClass":"InvalidOperationException","httpStatus":null,"severity":"error","filePath":"src/Aspire.Cli/Agents/AspireSkills/AspireSkillsBundleProvider.cs","lineNumber":640,"sourceCode":"            File.Copy(sourceFile, targetFile, overwrite: true);\n        }\n    }\n\n    private static void ValidateCompatibility(SkillBundleSupports? supports, string currentCliVersion, string currentSdkVersion)\n    {\n        if (supports is null)\n        {\n            throw new InvalidOperationException(\"Aspire skills bundle manifest must specify supported Aspire versions.\");\n        }\n\n        if (string.IsNullOrWhiteSpace(supports.AspireCli))\n        {\n            throw new InvalidOperationException(\"Aspire skills bundle manifest must specify supports.aspireCli.\");\n        }\n\n        if (!IsVersionInRange(currentCliVersion, supports.AspireCli))\n        {\n            throw new InvalidOperationException(string.Format(\n                CultureInfo.InvariantCulture,\n                \"Aspire skills bundle supports Aspire CLI versions '{0}', but the current CLI version is '{1}'.\",\n                supports.AspireCli,\n                currentCliVersion));\n        }\n\n        if (!string.IsNullOrWhiteSpace(supports.AspireSdk) &&\n            !IsVersionInRange(currentSdkVersion, supports.AspireSdk))\n        {\n            throw new InvalidOperationException(string.Format(\n                CultureInfo.InvariantCulture,\n                \"Aspire skills bundle supports Aspire SDK versions '{0}', but the current SDK version is '{1}'.\",\n                supports.AspireSdk,\n                currentSdkVersion));\n        }\n    }\n\n    private static bool IsVersionInRange(string version, string range)","sourceCodeStart":622,"sourceCodeEnd":658,"githubUrl":"https://github.com/microsoft/aspire/blob/25830f84bd145686607ad00c057b3f84e2e51d43/src/Aspire.Cli/Agents/AspireSkills/AspireSkillsBundleProvider.cs#L622-L658","documentation":"The bundle's declared supports.aspireCli range was parsed successfully, but the running Aspire CLI version falls outside it. The provider throws this formatted InvalidOperationException naming the supported range and the actual CLI version, so installing an incompatible bundle is blocked up front.","triggerScenarios":"Installing a bundle whose supports.aspireCli range (e.g. '>=10.0.0 <11.0.0') does not contain the current CLI version; thrown from ValidateCompatibility via CreateBundle.","commonSituations":"Using a bundle published for a newer/older Aspire release than the installed CLI, running a pinned or preview CLI version, or after a downgrade of the CLI.","solutions":["Upgrade (or downgrade) the Aspire CLI so its version is within the bundle's declared supports.aspireCli range","Install a bundle version whose supports range includes your CLI version","If the range is wrong in the bundle, correct it and republish the bundle"],"exampleFix":"// before (skill-manifest.json)\n\"supports\": { \"aspireCli\": \">=10.0.0 <11.0.0\" }\n// after (when running CLI 9.4.x)\n\"supports\": { \"aspireCli\": \">=9.0.0 <11.0.0\" }","handlingStrategy":"validation","validationCode":"// compare your CLI version to the bundle's declared range before installing\nvar cliVersion = typeof(Program).Assembly.GetName().Version;\nConsole.WriteLine($\"Ensure {cliVersion} is within the bundle's supports.aspireCli range before install.\");","typeGuard":null,"tryCatchPattern":"try\n{\n    await installer.InstallFromGitHubAsync(release);\n}\ncatch (InvalidOperationException ex) when (ex.Message.Contains(\"supports Aspire CLI versions\"))\n{\n    // ex.Message includes the supported range and current version\n    logger.LogError(ex, \"CLI/bundle version mismatch — upgrade the CLI or pick a compatible bundle release.\");\n}","preventionTips":["Check `aspire --version` against the bundle release notes before installing","Keep the CLI updated to the latest stable release","Prefer bundles published for the Aspire release wave you are running"],"tags":["cli","skills-bundle","version-conflict","compatibility"],"backgroundTag":"value-out-of-range","analyzedSha":"25830f84bd145686607ad00c057b3f84e2e51d43","analyzedAt":"2026-09-16T11:10:06.193Z","contentChangedAt":"2026-09-16T11:10:06.193Z","schemaVersion":2},"datasetVersion":"2026-09-21T09:17:21.228Z"}