When updating the config, keep the previous file if the new one is malformed
Opened this issue · 0 comments
thibaultamartin commented
Hebbot crashes when the configuration file is not properly formatted, which can happen quite easily (e.g. when putting the value of the order
field between single quotes instead of nothing, or when omitting the usual_reporters
field).
It would make Hebbot a lot more solid if it kept a previous version of the config file and performed a rollback in case of crash: without it, there's a need for a technical administrator to manually update the config file instead of just running !update-config
after correcting the issue.
Alternatively, Hebbot could run the update_config_command
when it starts.