MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / __ensure_cext

Function __ensure_cext

lib/sqlalchemy/testing/plugin/plugin_base.py:397–407  ·  view source on GitHub ↗
(opt, file_config)

Source from the content-addressed store, hash-verified

395
396@post
397def __ensure_cext(opt, file_config):
398 if os.environ.get("REQUIRE_SQLALCHEMY_CEXT", "0") == "1":
399 from sqlalchemy.util import has_compiled_ext
400
401 try:
402 has_compiled_ext(raise_=True)
403 except ImportError as err:
404 raise AssertionError(
405 "REQUIRE_SQLALCHEMY_CEXT is set but can't import the "
406 "cython extensions"
407 ) from err
408
409
410@post

Callers

nothing calls this directly

Calls 2

has_compiled_extFunction · 0.90
getMethod · 0.45

Tested by

no test coverage detected