NikolayXHD / Mtgdb

Mtgdb.Gui - desktop app to search MTG cards and build decks
https://www.slightlymagic.net/forum/viewtopic.php?f=62&t=19299
Other
63 stars 10 forks source link

UI fails to display cards after a cardlist update #42

Closed eriknelson closed 5 years ago

eriknelson commented 5 years ago

issue description, importance statement

Version: v4.0.1.1

I launched the application (which displayed the cards fine) and went into the update menu, updated the card list from mtgjson.com and restarted the application. Nothing appears in the card window. I checked the logs and found this log:

2019-02-26 16:02:50.3482    11  Error   Mtgdb.Ui.Loader "System.ArgumentException: An item with the same key has already been added.
   at Microsoft.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at Microsoft.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccess(Task task)
   at Mtgdb.Ui.Loader.<>c__DisplayClass4_0.<<wrap>b__0>d.MoveNext()"    "System.ArgumentException: An item with the same key has already been added.
   at Microsoft.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at Microsoft.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccess(Task task)
   at Mtgdb.Ui.Loader.<>c__DisplayClass4_0.<<wrap>b__0>d.MoveNext()"

I deleted the bundle that's extracted from the release zip and unzipped again (to return to the default state) and it correctly launched with the cards in view, so I think that confirms something in the updated card list is breaking the UI.

Expected Result: Able to update with the latest card json and have the UI continue to work.

NikolayXHD commented 5 years ago

Fixed in 4.0.1.2