Repository navigation
Keep UNESCO sites' points through the refresh - #5
Merged
Merged
Conversation
UNESCO's export now gives each site's points as a GeoJSON MultiPoint and its countries as a list, which the build didn't read, so the first refresh left every site at 0, 0. The refresh now saves both in the shape the build reads, taking the part nearest the middle of a site of several, and keeps the saved copy when a new shape would lose the points. The saved copy is rewritten in that shape.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Before: since the first source refresh (25 October), every UNESCO site in the build sits at 0, 0, which apps read as "no coordinates". UNESCO's export now gives a site's points as a GeoJSON MultiPoint and its countries as a list, and the build only read the old
{ lat, lon }shape.After: 1,270 of the 1,272 sites have a point again. The other two, the Routes of Santiago de Compostela in France and the First World War funerary sites, have no point in UNESCO's data.
How:
{ lat, lon }and "FR,ES". A site of several parts takes the part nearest their middle, so its point is always one of its own parts.For single-place sites, the points moved by less than a few kilometres compared with the old copy. Sites of several parts can now point at a different part than before.