Standardize Error Handling in Builtin Programs #1771
Labels
area-CraftOS
This affects CraftOS, or any other Lua portions of the mod.
enhancement
An extension of a feature or a new feature.
I am currently discussing with Xella the implementation of a feature to detect failed installations for PineStore download tracking. Specifically, if an installation fails, it should not log a download. However, we've encountered an issue with many built-in programs (such as
pastebin get
/run
) not returning an error state directly througherror()
, but instead usingprintError()
.This poses a challenge as there is no clear indication of installation failure when tracking the program's status. Consequently, since the program consistently returns an OK status, determining if the installation actually failed becomes problematic.
Thus, I would like to go over all builtin CC programs and change any
printError
's/io.stderr:write()
's into propererror()
s. I am, however, not entirely sure how this may affect things overall, so I would appreciate any insights, suggestions, or alternative solutions.I am not sure of a timeframe on this as well, as I'm running into finals, but I would like to look into this sometime in the next month.
The text was updated successfully, but these errors were encountered: