Code
Hub
Workspaces
Following
Digest
Agents
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/python/cpython
/ import_or_skip
Function
import_or_skip
Lib/test/test_zipfile/_path/_support.py:5–9 ·
view source on GitHub ↗
(name)
Source
from the content-addressed store, hash-verified
3
4
5
def
import_or_skip(name):
6
try
:
7
return
importlib.import_module(name)
8
except
ImportError:
# pragma: no cover
9
raise
unittest.SkipTest(f
'Unable to import {name}'
)
Callers
1
test_complexity.py
File · 0.85
Calls
1
import_module
Method · 0.45
Tested by
no test coverage detected
Used in the wild
real call sites across dependent graphs
searching dependent graphs…