Repository navigation
Publish the rest of Postcards' reference data - #2
Merged
Merged
Conversation
Cities, regions, airports, UNESCO sites, European stations (Trainline), countries and moments move from Postcards' build scripts into src/reference/, each its own dataset under v1/ with the licence of its sources: share-alike sources (ODbL, CC BY-SA) keep their licence, and sources.json gives the credit each one asks for. The output is the same as the files Postcards bundles today.
The checks that each city carries GeoNames' current region code and each region GeoNames' name move here from Postcards, with the script that vendors the codes (npm run city-admin1).
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: this repository published only Wikidata's places and stations. Postcards still built its cities, regions, airports, UNESCO sites, European stations, countries and moments itself, from scripts and vendored files in its own repository.
After: all of them are published here too, each as its own dataset under
v1/, listed incatalog.jsonwith its licence, sources and record count. The files are identical to the ones Postcards bundles today. The only difference is that the Trainline stations are read fresh (44,303 now, against 44,283 in Postcards' July copy).Each dataset keeps its sources' licence. A share-alike source makes the dataset share-alike: regions, airports, countries and European stations are ODbL, and UNESCO sites are CC BY-SA 3.0 IGO. Cities are CC BY 4.0. Places and stations stay CC0.
sources.jsonnow gives the credit each licence asks an app to show.How: one module per source in
src/reference/, ported from Postcards'build-reference.mjs,build-railways.mjs,build-heritage-full.mjs,build-languages.mjsandbuild-sovereignty.mjs. The vendored GeoNames and UNESCO files and the moments list move todata/reference/, along with the script that vendors the GeoNames codes (npm run city-admin1) and the checks that each city and region matches that GeoNames day.npm run buildbuilds them alongside the Wikidata datasets. If Trainline can't be reached, European stations are left out of that build rather than failing it, and--offlineskips them. Sources move tosrc/sources.ts, and the README and AGENTS.md now describe per-dataset licences.stations-europe/railways.jsoncities/top.json,cities/all.jsonregions/regions.jsonairports/airports.jsonheritage/unesco.jsoncountries/{names,article-names,continents,languages,sovereignty}.jsonmoments/moments.json