Let us walk on the 3-isogeny graph
|
Functions | |
bool | _should_use_osx_framework_prefix () |
str | _infer_prefix () |
str | _infer_user () |
str | _infer_home () |
Scheme | get_scheme (str dist_name, bool user=False, typing.Optional[str] home=None, typing.Optional[str] root=None, bool isolated=False, typing.Optional[str] prefix=None) |
str | get_bin_prefix () |
str | get_purelib () |
str | get_platlib () |
Variables | |
logger = logging.getLogger(__name__) | |
_AVAILABLE_SCHEMES = set(sysconfig.get_scheme_names()) | |
_PREFERRED_SCHEME_API = getattr(sysconfig, "get_preferred_scheme", None) | |
list | _HOME_KEYS |
|
protected |
Try to find a home for the current platform.
Definition at line 101 of file _sysconfig.py.
References pip._internal.locations._sysconfig._PREFERRED_SCHEME_API.
Referenced by pip._internal.locations._sysconfig.get_scheme().
|
protected |
Try to find a prefix scheme for the current platform. This tries: * A special ``osx_framework_library`` for Python distributed by Apple's Command Line Tools, when not running in a virtual environment. * Implementation + OS, used by PyPy on Windows (``pypy_nt``). * Implementation without OS, used by PyPy on POSIX (``pypy``). * OS + "prefix", used by CPython on POSIX (``posix_prefix``). * Just the OS name, used by CPython on Windows (``nt``). If none of the above works, fall back to ``posix_prefix``.
Definition at line 55 of file _sysconfig.py.
References pip._internal.locations._sysconfig._PREFERRED_SCHEME_API, pip._internal.locations._sysconfig._should_use_osx_framework_prefix(), and i.
Referenced by pip._internal.locations._sysconfig.get_scheme().
|
protected |
Try to find a user scheme for the current platform.
Definition at line 86 of file _sysconfig.py.
References pip._internal.locations._sysconfig._PREFERRED_SCHEME_API.
Referenced by pip._internal.locations._sysconfig.get_scheme().
|
protected |
Check for Apple's ``osx_framework_library`` scheme. Python distributed by Apple's Command Line Tools has this special scheme that's used when: * This is a framework build. * We are installing into the system prefix. This does not account for ``pip install --prefix`` (also means we're not installing to the system prefix), which should use ``posix_prefix``, but logic here means ``_infer_prefix()`` outputs ``osx_framework_library``. But since ``prefix`` is not available for ``sysconfig.get_default_scheme()``, which is the stdlib replacement for ``_infer_prefix()``, presumably Apple wouldn't be able to magically switch between ``osx_framework_library`` and ``posix_prefix``. ``_infer_prefix()`` returning ``osx_framework_library`` means its behavior is consistent whether we use the stdlib implementation or our own, and we deal with this special case in ``get_scheme()`` instead.
Definition at line 29 of file _sysconfig.py.
Referenced by pip._internal.locations._sysconfig._infer_prefix().
str get_bin_prefix | ( | ) |
Definition at line 201 of file _sysconfig.py.
References i.
str get_platlib | ( | ) |
str get_purelib | ( | ) |
Definition at line 208 of file _sysconfig.py.
References i.
Scheme get_scheme | ( | str | dist_name, |
bool | user = False , |
||
typing.Optional[str] | home = None , |
||
typing.Optional[str] | root = None , |
||
bool | isolated = False , |
||
typing.Optional[str] | prefix = None |
||
) |
Get the "scheme" corresponding to the input parameters. :param dist_name: the name of the package to retrieve the scheme for, used in the headers scheme path :param user: indicates to use the "user" scheme :param home: indicates to use the "home" scheme :param root: root under which other directories are re-based :param isolated: ignored, but kept for distutils compatibility (where this controls whether the user-site pydistutils.cfg is honored) :param prefix: indicates to use the "prefix" scheme and provides the base directory for the same
Definition at line 124 of file _sysconfig.py.
References pip._internal.locations._sysconfig._infer_home(), pip._internal.locations._sysconfig._infer_prefix(), pip._internal.locations._sysconfig._infer_user(), and i.
|
protected |
Definition at line 24 of file _sysconfig.py.
|
protected |
Definition at line 112 of file _sysconfig.py.
Definition at line 26 of file _sysconfig.py.
Referenced by pip._internal.locations._sysconfig._infer_home(), pip._internal.locations._sysconfig._infer_prefix(), and pip._internal.locations._sysconfig._infer_user().
logger = logging.getLogger(__name__) |
Definition at line 13 of file _sysconfig.py.