kodi-game / kodi-game-scripting

Scripting for Kodi Game add-ons
GNU General Public License v2.0
5 stars 9 forks source link

Fail hard and fast on addon.xml.in parsing error #99

Closed garbear closed 3 years ago

garbear commented 3 years ago

When a parsing error occurs, an error is printed and addon.xml.in loading is skipped, leading to blank fields in the output.

Instead, if an addon.xml.in has a parsing error, fail hard and fast to easily discover the error.

How has this been tested?

Tried to process gw at version https://github.com/kodi-game/game.libretro.gw/commit/3143af5eeacb5d31175c5395a0c7459afd871233. Build is successfully aborted:

xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 29, column 41

CI run: https://dev.azure.com/themagnificentmrb/kodi-game-scripting/_build/results?buildId=608&view=logs&j=3c6d0c73-cb56-5412-ce34-70e581ba56b9

garbear commented 3 years ago

I've reviewed 126 of our cores: https://dev.azure.com/themagnificentmrb/kodi-game-scripting/_build/results?buildId=608&view=logs&j=3c6d0c73-cb56-5412-ce34-70e581ba56b9. All look good