Coverage for /pythoncovmergedfiles/medio/medio/usr/local/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/__init__.py: 56%

Shortcuts on this page

r m x   toggle line displays

j k   next/prev highlighted chunk

0   (zero) top of page

1   (one) first highlighted chunk

9 statements  

1"""This is a subpackage because the directory is on sys.path for _in_process.py 

2 

3The subpackage should stay as empty as possible to avoid shadowing modules that 

4the backend might import. 

5""" 

6 

7import importlib.resources as resources 

8 

9try: 

10 resources.files 

11except AttributeError: 

12 # Python 3.8 compatibility 

13 def _in_proc_script_path(): 

14 return resources.path(__package__, "_in_process.py") 

15 

16else: 

17 

18 def _in_proc_script_path(): 

19 return resources.as_file( 

20 resources.files(__package__).joinpath("_in_process.py") 

21 )