-
-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue with the scotland.json file #27
Comments
I just checked and the Scotland file does work with functions that pull from data that it includes despite it being formatted differently (I guess the formatting doesn't matter and just makes it look different - the structure is apparently the same). The solution, then, appears to be to add the missing keys with empty values to the json file so that it does not cause KeyErrors when functions search for data from keys that do not exist and then to fill in those empty keys with info from Wikipedia. Thanks! |
I'm sorry to keep adding comments, but I found that the json files for a few more countries (I noticed both the virgin islands and wales) do not have population keys (as well as are missing lots of other info keys) either and wanted to point it out for whoever ends up fixing this problem (I'll make a pull request with the fixes if I have the time, but I probably won't for a while) |
Addresses issue porimol#27
First of all, thank you for making such a useful and user friendly library available for free! This has already saved me hours of work and has made my code a lot less hack-y in its implementation of population databases. With that said, I noticed that the scotland.json file seems to be much more out-of-date when compared to other json files in the data folder (including those that were not updated in the latest (May 2020) commit). It is not only in a seemingly different format, but does not contain most of the data that I assume it should (for example, population). This has made it incompatible with some of this library's functions. This isn't a big deal, and I was able to fix it by rewriting the file in my install and including the information that I needed (primarily population data), I just wanted to let you know in-case you encounter a similar issue. I would be happy to share my rewritten file once I make sure it is compatible with functions that I have not had to use it with. Please let me know if I have made some mistake or am misunderstanding the issue and thanks again for this otherwise great library!
Current Scotland File:
Compatible File:
The text was updated successfully, but these errors were encountered: