MCPcopy Create free account
hub / github.com/ceph/ceph / _run

Function _run

src/script/build-with-container.py:233–242  ·  view source on GitHub ↗
(cmd, *args, **kwargs)

Source from the content-addressed store, hash-verified

231
232
233def _run(cmd, *args, **kwargs):
234 ctx = kwargs.pop("ctx", None)
235 if ctx and ctx.dry_run:
236 log.info("(dry-run) Not Executing command: %s", _cmdstr(cmd))
237 # because we can not return a result (as we did nothing)
238 # raise a specific exception to be caught by higher layer
239 raise DidNotExecute(cmd)
240
241 log.info("Executing command: %s", _cmdstr(cmd))
242 return subprocess.run(cmd, *args, **kwargs)
243
244
245def _container_cmd(

Callers 15

_git_current_branchFunction · 0.70
_git_current_shaFunction · 0.70
build_containerFunction · 0.70
_check_cached_imageFunction · 0.70
get_containerFunction · 0.70
bc_configureFunction · 0.70
bc_buildFunction · 0.70
bc_build_testsFunction · 0.70
bc_run_testsFunction · 0.70
bc_make_source_rpmFunction · 0.70
_find_srpm_by_rpm_queryFunction · 0.70
bc_build_rpmFunction · 0.70

Calls 5

_cmdstrFunction · 0.85
DidNotExecuteClass · 0.85
popMethod · 0.45
infoMethod · 0.45
runMethod · 0.45

Tested by

no test coverage detected