diff --git a/pyproject.toml b/pyproject.toml index beb27f4..957d230 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -2,7 +2,7 @@ name = "stimela" version = "2.0.1" description = "Framework for system agnostic pipelines for (not just) radio interferometry" -authors = ["Sphesihle Makhathini ", "Oleg Smirnov and RATT "] +authors = ["Oleg Smirnov and RATT ", "Sphesihle Makhathini "] readme = "README.rst" license = "GNU GPL v2" include = [{ path = "tests" }] diff --git a/stimela/commands/doc.py b/stimela/commands/doc.py index 363c346..e62dfde 100644 --- a/stimela/commands/doc.py +++ b/stimela/commands/doc.py @@ -14,7 +14,7 @@ from scabha.cargo import ParameterCategory from stimela.kitchen.recipe import Recipe from stimela.kitchen.cab import Cab -from stimela.exceptions import RecipeValidationError +from stimela.exceptions import RecipeValidationError, CabValidationError from stimela.task_stats import destroy_progress_bar from .run import load_recipe_files, resolve_recipe_file @@ -122,8 +122,14 @@ def load_recipe(name: str, section: Dict): recipe.rich_help(tree, max_category=max_category) for name in cabs_to_document: - cab = Cab(**stimela.CONFIG.cabs[name]) - cab.finalize(config=stimela.CONFIG) + try: + cab = Cab(**stimela.CONFIG.cabs[name]) + cab.finalize(config=stimela.CONFIG) + except Exception as exc: + if not isinstance(exc, CabValidationError): + exc = CabValidationError(f"error loading cab '{name}'", exc) + log_exception(exc) + sys.exit(2) tree = top_tree.add(f"Cab: [bold]{name}[/bold]") cab.rich_help(tree, max_category=max_category)