get-config-dir: errors from get-config-dir-$method not propagated
Maximilian Stein <[email protected]> Wed, 21 Feb 2024 11:29:31 +0100
| Newsgroups | gmane.linux.debian.fai |
|---|---|
| Message-ID | <[email protected]> |
Hi there, I noticed that errors from get-config-dir-$method are not propagated in get-config-dir [1]. This means that while a call to task_error, e.g. in get-config-dir-git, causes an error log and save log call, the installation does not stop afterwards but continues: FAI_CONFIG_SRC is set to git+ssh://example.com/srv/git/fai/install.git#blub Updating git copy in /var/lib/fai/config Von ssh://example.com/srv/git/fai/install 7256e1cd5..6ea9c2559 config -> origin/config error: Pfadspezifikation 'origin/blub' stimmt mit keinen git-bekannten Dateien überein. Error in task confdir. Code: 882 Traceback: task_error _git_checkout main Calling hook: savelog.DEFAULT savelog.DEFAULT OK. Source hook: savelog.LAST.sh ERRORS found in log files. See /var/log/fai/dummy/confupdate-20240221_105633/error.log savelog.LAST.sh OK. Save log files via ssh to [email protected]:log//dummy/confupdate-20240221_105633 FATAL ERROR. Installation stopped. Source hook: setup.DEFAULT.sh hostname: dummy setup.DEFAULT.sh OK. Calling task_setup FAI_FLAGS: Calling task_defclass fai-class: Defining classes. I have not tested but could imagine that the behavior is similar when calling task_error from a hook. Best, Maximilian [1]: https://github.com/faiproject/fai/blob/master/lib/get-config-dir#L44C9-L44C31