Let us walk on the 3-isogeny graph
Loading...
Searching...
No Matches
pip._internal.utils.temp_dir Namespace Reference

Data Structures

class  _Default
 
class  AdjacentTempDirectory
 
class  TempDirectory
 
class  TempDirectoryTypeRegistry
 

Functions

Generator[None, None, Noneglobal_tempdir_manager ()
 
Generator[TempDirectoryTypeRegistry, None, Nonetempdir_registry ()
 

Variables

 logger = logging.getLogger(__name__)
 
 _T = TypeVar("_T", bound="TempDirectory")
 
 tempdir_kinds
 
Optional _tempdir_manager = None
 
 _default = _Default()
 

Function Documentation

◆ global_tempdir_manager()

Generator[None, None, None] global_tempdir_manager ( )

Definition at line 29 of file temp_dir.py.

29def global_tempdir_manager() -> Generator[None, None, None]:
30 global _tempdir_manager
31 with ExitStack() as stack:
32 old_tempdir_manager, _tempdir_manager = _tempdir_manager, stack
33 try:
34 yield
35 finally:
36 _tempdir_manager = old_tempdir_manager
37
38

◆ tempdir_registry()

Generator[TempDirectoryTypeRegistry, None, None] tempdir_registry ( )
Provides a scoped global tempdir registry that can be used to dictate
whether directories should be deleted.

Definition at line 62 of file temp_dir.py.

62def tempdir_registry() -> Generator[TempDirectoryTypeRegistry, None, None]:
63 """Provides a scoped global tempdir registry that can be used to dictate
64 whether directories should be deleted.
65 """
66 global _tempdir_registry
67 old_tempdir_registry = _tempdir_registry
68 _tempdir_registry = TempDirectoryTypeRegistry()
69 try:
70 yield _tempdir_registry
71 finally:
72 _tempdir_registry = old_tempdir_registry
73
74

Variable Documentation

◆ _default

_default = _Default()
protected

Definition at line 79 of file temp_dir.py.

◆ _T

_T = TypeVar("_T", bound="TempDirectory")
protected

Definition at line 13 of file temp_dir.py.

◆ _tempdir_manager

Optional _tempdir_manager = None
protected

Definition at line 25 of file temp_dir.py.

◆ logger

logger = logging.getLogger(__name__)

Definition at line 11 of file temp_dir.py.

◆ tempdir_kinds

tempdir_kinds
Initial value:
1= enum(
2 BUILD_ENV="build-env",
3 EPHEM_WHEEL_CACHE="ephem-wheel-cache",
4 REQ_BUILD="req-build",
5)

Definition at line 18 of file temp_dir.py.