Add restart for package not found errors #1199
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
check_installed()
signals error conditions of classrlib_error_package_not_found
. The error includespkg
andversion
fields. They are vectorised and may include several packages.The error is signalled with a
rlib_restart_package_not_found
restart on the stack to allow handlers to install the required packages. To do so, add a calling handler forrlib_error_package_not_found
, install the required packages, and invoke the restart without arguments. This restarts the check from scratch.The condition is not signalled in non-interactive sessions, in the restarting case, or if the
rlib_restart_package_not_found
user option is set toFALSE
.For now the ctor and signal functions for the package-not-found errors are not exported because the error class and signalling protocol are rather intertwined.