@@ -17,6 +17,7 @@ import {
1717 PythonEnvironments ,
1818 resolveEnvironmentManagerCapability ,
1919 resolvePackageManagerCapability ,
20+ supportedCapability ,
2021} from '@vscode/python-environments' ;
2122
2223type Equal < Left , Right > =
@@ -52,29 +53,29 @@ if (isPackageVersionLookupNotSupportedError(maybeError)) {
5253
5354// Legacy providers must now advertise every capability key explicitly; there are no defaults.
5455const fullPackageCapabilities : Capabilities < PackageManagerCapability > = {
55- 'packages.list' : async ( ) => ( { supported : true } ) ,
56- 'packages.list.skipCache' : async ( ) => ( { supported : true } ) ,
57- 'packages.refresh' : async ( ) => ( { supported : true } ) ,
58- 'packages.manage' : async ( ) => ( { supported : true } ) ,
59- 'packages.manage.install' : async ( ) => ( { supported : true } ) ,
60- 'packages.manage.uninstall' : async ( ) => ( { supported : true } ) ,
61- 'packages.manage.upgrade' : async ( ) => ( { supported : true } ) ,
62- 'packages.manage.headless' : async ( ) => ( { supported : true } ) ,
63- 'packages.manage.showSkipOption' : async ( ) => ( { supported : true } ) ,
64- 'packages.direct' : async ( ) => ( { supported : true } ) ,
65- 'packages.availableVersions' : async ( ) => ( { supported : true } ) ,
56+ 'packages.list' : supportedCapability ,
57+ 'packages.list.skipCache' : supportedCapability ,
58+ 'packages.refresh' : supportedCapability ,
59+ 'packages.manage' : supportedCapability ,
60+ 'packages.manage.install' : supportedCapability ,
61+ 'packages.manage.uninstall' : supportedCapability ,
62+ 'packages.manage.upgrade' : supportedCapability ,
63+ 'packages.manage.headless' : supportedCapability ,
64+ 'packages.manage.showSkipOption' : supportedCapability ,
65+ 'packages.direct' : supportedCapability ,
66+ 'packages.availableVersions' : supportedCapability ,
6667} ;
6768const fullEnvironmentCapabilities : Capabilities < EnvironmentManagerCapability > = {
68- 'environments.list' : async ( ) => ( { supported : true } ) ,
69- 'environments.refresh' : async ( ) => ( { supported : true } ) ,
70- 'environments.resolve' : async ( ) => ( { supported : true } ) ,
71- 'environments.getSelected' : async ( ) => ( { supported : true } ) ,
72- 'environments.setSelected' : async ( ) => ( { supported : true } ) ,
73- 'environments.create' : async ( ) => ( { supported : true } ) ,
74- 'environments.create.quick' : async ( ) => ( { supported : true } ) ,
75- 'environments.create.additionalPackages' : async ( ) => ( { supported : true } ) ,
76- 'environments.remove' : async ( ) => ( { supported : true } ) ,
77- 'environments.remove.headless' : async ( ) => ( { supported : true } ) ,
69+ 'environments.list' : supportedCapability ,
70+ 'environments.refresh' : supportedCapability ,
71+ 'environments.resolve' : supportedCapability ,
72+ 'environments.getSelected' : supportedCapability ,
73+ 'environments.setSelected' : supportedCapability ,
74+ 'environments.create' : supportedCapability ,
75+ 'environments.create.quick' : supportedCapability ,
76+ 'environments.create.additionalPackages' : supportedCapability ,
77+ 'environments.remove' : supportedCapability ,
78+ 'environments.remove.headless' : supportedCapability ,
7879} ;
7980
8081const legacyPackageManager : PackageManager = {
0 commit comments