[python] deprecate old python packaging classes in favor of PythonPackageManager

GitOrigin-RevId: 8c2bc03c04d95839192b612c2a9053cfdbc3ee00
This commit is contained in:
Aleksei Kniazev
2023-12-04 12:28:16 +01:00
committed by intellij-monorepo-bot
parent 0d67de8403
commit 49f0e39af3
4 changed files with 19 additions and 2 deletions

View File

@@ -14,7 +14,10 @@ import org.jetbrains.annotations.Nullable;
import java.util.List;
import java.util.Set;
/**
* @deprecated use {@link com.jetbrains.python.packaging.management.PythonPackageManager}
*/
@Deprecated(forRemoval = true)
public abstract class PyPackageManager implements Disposable {
public static final Key<Boolean> RUNNING_PACKAGING_TASKS = Key.create("PyPackageRequirementsInspection.RunningPackagingTasks");

View File

@@ -8,7 +8,12 @@ import com.intellij.openapi.projectRoots.Sdk;
import com.intellij.webcore.packaging.PackageManagementService;
import org.jetbrains.annotations.NotNull;
/**
* @deprecated replaced by {@link com.jetbrains.python.packaging.common.PackageManagerHolder }.
* To get an instance of PythonPackageManager consider using
* {@link com.jetbrains.python.packaging.management.PythonPackageManager.Companion#forSdk(Project, Sdk)}
*/
@Deprecated(forRemoval = true)
public abstract class PyPackageManagers implements Disposable {
@NotNull
public static PyPackageManagers getInstance() {

View File

@@ -10,7 +10,10 @@ import java.util.List;
/**
* @author Mikhail Golubev
* @deprecated use {@link com.jetbrains.python.packaging.pip.PypiPackageCache} to search for PyPI packages
* or {@link com.jetbrains.python.packaging.management.PythonRepositoryManager#allPackages()} to search for all available packages.
*/
@Deprecated(forRemoval = true)
public class PyPIPackageCache extends PyAbstractPackageCache {
private static final String CACHE_FILE_NAME = "pypi-cache.json";

View File

@@ -37,6 +37,12 @@ import java.util.regex.Matcher;
import java.util.regex.Pattern;
/**
* @deprecated for search in for packages and managing repositories use
* {@link com.jetbrains.python.packaging.management.PythonRepositoryManager}
* obtained through {@link com.jetbrains.python.packaging.management.PythonPackageManager}
*/
@Deprecated(forRemoval = true)
public class PyPackageManagementService extends PackageManagementServiceEx {
@NotNull private static final Pattern PATTERN_ERROR_LINE = Pattern.compile(".*error:.*", Pattern.CASE_INSENSITIVE);
@NonNls protected static final String TEXT_PREFIX = buildHtmlStylePrefix();