CapsuleFarmerEvolved icon indicating copy to clipboard operation
CapsuleFarmerEvolved copied to clipboard

[Enchantment]: Handle invalid config files

Open alepouna opened this issue 2 years ago • 4 comments

What is your idea?

There are cases were users will enter a bad/corrupt yaml file. Instead of just throwing the python error, lets give them a pretty message and a link to the config tool

What should happen?

As described above

My request is not a question

  • [X] I acknowledge that this issue is not a question or a bug request.

alepouna avatar Feb 10 '23 11:02 alepouna

hey i was thinking, if something like this: https://pypi.org/project/yamllint/ could be implemented? so it can show more specific yaml errors

dimitrisz123 avatar Feb 11 '23 13:02 dimitrisz123

I assume since this is a linter the user has to run it and check the linting results, no?

alepouna avatar Feb 11 '23 15:02 alepouna

i though it could be added in the main program to show exactly what is wrong with the yaml. i posted it as an idea just in case

dimitrisz123 avatar Feb 11 '23 16:02 dimitrisz123

If it can be executed before the config is being read, and can spit out the problems in the user face, I am all for it. But if the user has to manually run it or the program still crashes while trying to load the yaml file (because of errors) it will be mostly useless. Advanced users etc, can figure out that the yaml is problematic, if you know what I mean.

alepouna avatar Feb 11 '23 16:02 alepouna