alexnoob / BasketBall-GM-Rosters

JSON Rosters for Basketball GM
132 stars 135 forks source link

Key inconsistancy #2

Closed smykes closed 8 years ago

smykes commented 8 years ago

There is a small problem in your JSON file. Frank Ntilikina name key does not match the rest. Instead of having a name key he has a firstName and lastName key

{"tid":-4,
    "firstName":"Frank","lastName":"Ntilikina",

should be

{"tid":-4,
    "name":"Frank Ntilikina"

Don't ask how I found this out. Not sure if it would cause a crash, but I found it so I thought I would pass it along.

alexnoob commented 8 years ago

Hi! Don't worry, I'm well aware of this "problem" as I tried it on purpose. The firstName/lastName feature was introduced recently in Basketball GM (correcting some bugs in the draft scouting page with first names and last names in 2 parts).

I encountered a bug with the roster a few weeks ago, and wanted to try if it wasn't related to this new feature. That's why I tried with Frank Ntilikina. Otherwise everything works as intended, either with "name" or "firstName/lastName". On the very long term I might switch everyone to firstName/lastName but as currently nothing is broken, I don't really need to fix it :-)

smykes commented 8 years ago

This is how I figured it out... https://github.com/smykes/basketball-gm-player-browser

alexnoob commented 8 years ago

Wow, quite impressive! It could be extremely useful for me in order to improve the Legacy and the 2016-17 NBA roster. Feel free to tell me when you think you're done, or if you ever need me to change some things in the rosters!

smykes commented 8 years ago

How are you generating your rosters? It would be great if each player and team had unique identifiers. If you would have to do that manually, I can write a quick script to do it and put a pull request in.