mirror of
https://github.com/EDCD/EDMarketConnector.git
synced 2025-04-14 00:07:14 +03:00
Update stations database from eddb.
This commit is contained in:
parent
d14608ae40
commit
e50cd2b808
4
eddb.py
4
eddb.py
@ -35,14 +35,14 @@ class EDDB:
|
||||
return '.'
|
||||
|
||||
|
||||
# build system & station database from files systems.json and stations_lite.json from http://eddb.io/api
|
||||
# build system & station database from files systems.json and stations.json from http://eddb.io/api
|
||||
if __name__ == "__main__":
|
||||
import json
|
||||
|
||||
# system_name by system_id
|
||||
systems = dict([(x['id'], str(x['name'])) for x in json.loads(open('systems.json').read())])
|
||||
|
||||
stations = json.loads(open('stations_lite.json').read())
|
||||
stations = json.loads(open('stations.json').read())
|
||||
|
||||
# check that all populated systems have known coordinates
|
||||
coords = dict([(x['id'], x['x'] or x['y'] or x['z']) for x in json.loads(open('systems.json').read())])
|
||||
|
BIN
stations.p
BIN
stations.p
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user