BigOokie / skywire-wing-commander

Wing Commander is a Telegram bot written in GO designed to help the Skyfleet community manage their Skyminers
MIT License
13 stars 5 forks source link

Enhance config file validation and management #22

Open BigOokie opened 6 years ago

BigOokie commented 6 years ago

Describe the bug Currently the app is not very resilient to incorrect data within the config.toml configuration file.

To Reproduce Steps to reproduce the behavior:

  1. Edit the .wingocmmander/config.toml file.
  2. Alter any string type parameter (i.e. apikiey, admin) to not be enclosed in " " (double quotes)
  3. Save the changes
  4. Run Wing Commander (.wcbot)
  5. The error will be reported.

Expected behavior Fine for an error to still be reported, but preferably it will be one that allows the user to self-help. The error message should provide sufficient detail that the user knows what the problem is and has the ability to fix it without requiring assistance.

While this may not be possible in all cases - its what we should be targeting.

Screenshots NA

Additional context Low priority. Fix when we can

BigOokie commented 6 years ago

Partial fixes added to v0.2.0-beta.3. This is still WIP.