stubber.update_module_list

generate the list of modules that should be attempted to stub for this : - combine the modules from the different texts files - split the lines into individual module names - combine them in one set - remove the ones than cannot be stubbed - remove test modules, ending in _test - write updates to:

  • board/modulelist.txt

  • board/createsubs.py

  • TODO: remove the frozen modules from this list

  • TODO: bump patch number if there are actual changes

Module Contents

Functions

read_modules(path: pathlib.Path = None) → Set

read text files with modules per firmware.

wrapped(modules: Union[Set, List]) → str

wrap code line at spaces

main()

helper script

stubber.update_module_list.read_modules(path: pathlib.Path = None) Set

read text files with modules per firmware. each contains the output of help(“modules”) - lines starting with # are comments. - split the other lines at whitespace seperator, - and add each module to a set

Parameters

path (pathlib.Path) –

Return type

Set

stubber.update_module_list.wrapped(modules: Union[Set, List]) str

wrap code line at spaces

Parameters

modules (Union[Set, List]) –

Return type

str

stubber.update_module_list.main()

helper script generate a few lines of code with all modules to be stubbed by createstubs