mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
PY-88108 Make PythonPackageManager listing and dependency methods Experimental API
Promote five methods from @ApiStatus.Internal to @ApiStatus.Experimental: - listInstalledPackages() - listInstalledPackagesSnapshot() - listOutdatedPackages() - listOutdatedPackagesSnapshot() - extractDependenciesCached() Update pycharm_api.txt allowlist accordingly. IJ-MR-194281 GitOrigin-RevId: 61c645dddd790316255318245eeee53e917132b6
This commit is contained in:
committed by
intellij-monorepo-bot
parent
0e82e7f7f2
commit
f71ecb1a84
@@ -187,25 +187,25 @@ abstract class PythonPackageManager(val project: Project, val sdk: Sdk) : Dispos
|
||||
}
|
||||
|
||||
|
||||
@ApiStatus.Internal
|
||||
@ApiStatus.Experimental
|
||||
suspend fun listInstalledPackages(): List<PythonPackage> {
|
||||
waitForInit()
|
||||
return listInstalledPackagesSnapshot()
|
||||
}
|
||||
|
||||
@ApiStatus.Internal
|
||||
@ApiStatus.Experimental
|
||||
fun listInstalledPackagesSnapshot(): List<PythonPackage> {
|
||||
return installedPackages
|
||||
}
|
||||
|
||||
@ApiStatus.Internal
|
||||
@ApiStatus.Experimental
|
||||
suspend fun listOutdatedPackages(): Map<String, PythonOutdatedPackage> {
|
||||
waitForInit()
|
||||
return listOutdatedPackagesSnapshot()
|
||||
}
|
||||
|
||||
|
||||
@ApiStatus.Internal
|
||||
@ApiStatus.Experimental
|
||||
fun listOutdatedPackagesSnapshot(): Map<String, PythonOutdatedPackage> {
|
||||
return outdatedPackages
|
||||
}
|
||||
@@ -283,7 +283,7 @@ abstract class PythonPackageManager(val project: Project, val sdk: Sdk) : Dispos
|
||||
* PyResult.Failure if extraction is supported but failed (e.g., parsing error),
|
||||
* PyResult.Success with the list of dependencies if extraction succeeded.
|
||||
*/
|
||||
@ApiStatus.Internal
|
||||
@ApiStatus.Experimental
|
||||
suspend fun extractDependenciesCached(): PyResult<List<PythonPackage>>? {
|
||||
val dependencyFile = getDependencyFile() ?: return null
|
||||
return createCachedDependencies(dependencyFile).await()
|
||||
|
||||
Reference in New Issue
Block a user