structfs.runner_cli

structfs.runner_cli#

Command-line interface to run a module.

Module Contents#

Functions#

_error

main

Program entry point.

_load_module

Load a module - supports both module names and file paths.

Data#

_log

API#

structfs.runner_cli._log

‘getLogger(…)’

structfs.runner_cli._error(ofile: io.FileIO, msg: str, code: int = -1) int
structfs.runner_cli.main()

Program entry point.

structfs.runner_cli._load_module(module_or_path: str)

Load a module - supports both module names and file paths.

Args: module_or_path: Can be either: - Module name: “idaes.models.flash_flowsheet” - File path: “/Users/user/Downloads/my_flowsheet.py” Returns: module: The loaded Python module object.

Note: For file paths, this function sets up a pseudo-package structure to support relative imports (e.g., ‘from ..sibling import something’).