GeoNames Home | Postal Codes | Download / Webservice | About 

GeoNames Forum
  [Search] Search   [Recent Topics] Recent Topics   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
Issues with children API with hierarchy=dependency  XML
Forum Index -> General
Author Message
paulw77



Joined: 14/10/2020 22:09:29
Messages: 6
Offline

Perhaps I am misunderstanding but it appears to me there are some issues with the child dependency API.

This will be long since I see several issues, most of which should be easy to resolve.

childrenJSON?geonameId=<GeoNameID of Parent>&hierarchy=dependency&username=<username>

Dependents seem to be missing for several countries. I found seven "Countries" that I believe should be listed as dependents that are not. None of them are listed as PCLI

Under the US:
UM - (PCLD) U.S. Minor Outlying Islands - US Territory (585496
VI - (PCLD) U.S. Virgin Islands - US Territory (4796775)
PW - (PCLF) Palau (1559582)

UM and VI are both an unincorporated territory of the United States.

I can understand an argument against listing Palau, since it's been granted independence, but it is also under a Compact of Free Association since
1 October 1994. If you exclude Palau you would also need to exclude the Marshall Islands and Micronesia since they have similar status but are listed as US dependents.

Under China we probably should have
HK - (PCLS) Hong Kong (1819730)
MO - (PCLS) Macao (1821275)

Both are special administrative zones under China and since they have their own ISO 3166-1 codes should be listed as dependents.

The final two I can understand not wanting to deal with:
PS - (PCLS) Palestine (6254930)
EH - (TERR) Western Sahara (2461445)

Both would be controversial.

The only country that could be listed as Palestine's parent would be Israel, and doing so would be a political MESS! Perhaps it should be listed as independent, as Taiwan is from China despite China's claims.

Western Sahara is another mess. It has no recognized government of it's own, is claimed by Morocco, and also by the self-proclaimed Sahrawi Arab Democratic Republic. The UN does not recognize either claim.

Another issue I have with the data returned by this API is that Antarctica is listed as dependent of several countries that have research base claims located there. Yes... I know the Antarctic treaty does not recognize those claims, however they still exist.

Would it not be better to assign a place name location code to each base and then list that location as a dependent? Of course then the problem becomes is Antarctica listed as the parent or the country making the claim? Also I believe at least one base is shared between two countries.

One final issue:

When calling this API for a country that has no ISO 3166-1 dependents it instead returns a list of ADM1 level entries.

Perhaps a flag could exist in the parent item indicating that there are, or are not dependent states, then one could decide to only call the API for countries that have dependents.

For now I'm fixing the US territory and China Special Admin zones in my code, but dislike fixing data in code. Status could change in the future and I don't like changing code because of status changes that could be taken care of by correcting the data.

For now I'm ignoring the Palestine and Western Sahara issue because... politics suck, and I don't want to start another war!

I'm getting around the Admin1 issue by ignoring any item with ADMx as it's feature code.
paulw77



Joined: 14/10/2020 22:09:29
Messages: 6
Offline

It appears the system at least knows about UM and VI

https://www.geonames.org/countries/US/united-states.html

Results in the following list:

dependencies : American Samoa, Micronesia, Guam, Marshall Islands, Northern Mariana Islands, Puerto Rico, U.S. Minor Outlying Islands, U.S. Virgin Islands

It still doesn't have Palau, but...

So why does the hierarchy=dependency Child API not return them?

Same is true for China

https://www.geonames.org/countries/CN/china.html

Shows both Hong Kong, and Macao, but the API does not return them.

Is there another method I should be using to determine dependent states?
 
Forum Index -> General
Go to:   
Powered by JForum 2.1.5 © JForum Team