1
0
mirror of https://github.com/EDCD/EDMarketConnector.git synced 2025-04-14 00:07:14 +03:00

Handle non-ASCII station names

This commit is contained in:
Jonathan Harris 2019-09-14 20:02:54 +01:00
parent 09de1adc91
commit 7fe08f61b3
3 changed files with 1 additions and 1 deletions

View File

@ -107,7 +107,7 @@ if __name__ == "__main__":
# station_id by (system_id, station_name)
stations = json.loads(download('stations.json').content) # let json do the utf-8 decode
station_ids = {
(x['system_id'], str(x['name'])) : x['id']
(x['system_id'], x['name'].encode('utf-8')) : x['id'] # Pilgrim's Ruin in HR 3005 id 70972 has U+2019 quote
for x in stations if x['max_landing_pad_size']
}

Binary file not shown.

BIN
systems.p

Binary file not shown.