Add utf-8 encoding when reading cities15000 file
This commit is contained in:
parent
dc6bfb3403
commit
bb121512c3
|
@ -305,7 +305,7 @@ class GeometryHelper:
|
|||
distance = math.inf
|
||||
country = 'Unknown'
|
||||
city = 'Unknown'
|
||||
with open(_data_path, 'r') as f:
|
||||
with open(_data_path, 'r', encoding='utf-8') as f:
|
||||
for line_number, line in enumerate(f):
|
||||
fields = line.split('\t')
|
||||
file_city_name = fields[2]
|
||||
|
|
Loading…
Reference in New Issue
Block a user