module pycode.call_setup_hook

Short summary

module pyquickhelper.pycode.call_setup_hook

Helper for the setup.

source on GitHub

Functions

function

truncated documentation

call_setup_hook

Calls function _setup_hook() for a specific module, it is called in a separate process.

call_setup_hook_cmd

Prepares the command line to call function _setup_hook() for a specific module.

Documentation

Helper for the setup.

source on GitHub

pyquickhelper.pycode.call_setup_hook.call_setup_hook(folder, module_name, fLOG=<function noLOG>, must_be=False, function_name='_setup_hook', use_print=False, force_call=False, additional_paths=None, **args)[source]

Calls function _setup_hook for a specific module, it is called in a separate process.

Parameters
  • folder – folder which contains the setup

  • module_name – module name

  • fLOG – logging function

  • must_be – raises an exception if _setup_hook is not found

  • function_name – function to call by default

  • use_print – use print to display information

  • force_call – use subprocess.call instead of run_cmd

  • additional_paths – additional_paths to add to sys.path before call the function

  • args – additional parameter (dictionary)

Returns

stdout, stderr

The function expects to find file __init__.py in <folder>/src/<module_name>.

source on GitHub

pyquickhelper.pycode.call_setup_hook.call_setup_hook_cmd(folder, module_name, function_name='_setup_hook', additional_paths=None, interpreter_path=None, check=True, **args)[source]

Prepares the command line to call function _setup_hook for a specific module.

Parameters
  • folder – folder which contains the setup

  • module_name – module name

  • function_name – function to call by default

  • additional_paths – additional_paths to add to sys.path before call the function

  • args – additional parameter (dictionary)

  • interpreter_path – to use a different interpreter than the current one

  • check – check existence of filename

Returns

stdout, stderr

The function expects to find file __init__.py in <folder>/src/<module_name>.

New in version 1.9: Parameter check was added.

source on GitHub