File tree Expand file tree Collapse file tree 2 files changed +7
-9
lines changed Expand file tree Collapse file tree 2 files changed +7
-9
lines changed Original file line number Diff line number Diff line change 19
19
***************************************************************************/
20
20
"""
21
21
22
- import sys
23
22
import gzip
23
+ import sys
24
24
from os import environ , listdir , mkdir
25
25
from os .path import join , exists , getsize
26
26
from sys import exit , stderr
31
31
import yaml
32
32
from dateutil import parser
33
33
from psycopg2 import connect , OperationalError , ProgrammingError
34
- from xmltodict import OrderedDict
35
-
36
34
37
35
class Enrich (object ):
38
36
mapping_type = {
@@ -174,7 +172,7 @@ def check_mapping_file_data(self):
174
172
"""
175
173
self .info ('Load Mapping file data.' )
176
174
document = open (self .mapping_file , 'r' )
177
- mapping_data = yaml .load (document )
175
+ mapping_data = yaml .safe_load (document )
178
176
try :
179
177
for table , value in mapping_data ['tables' ].items ():
180
178
try :
@@ -565,7 +563,7 @@ def enrich_database_from_diff_file(self):
565
563
modify_list = raw_content ['osmChange' ]['modify' ]
566
564
for list in modify_list :
567
565
for key , value in list .items ():
568
- if type (value ) != OrderedDict :
566
+ if type (value ) != dict :
569
567
for osm_data in value :
570
568
self .enrich_database_from_osm_data (
571
569
osm_data , key
Original file line number Diff line number Diff line change 1
- psycopg2-binary
2
- python-dateutil
3
- pyyaml
4
- xmltodict
1
+ psycopg2-binary == 2.9.4
2
+ python-dateutil == 2.8.2
3
+ PyYAML == 6.0
4
+ xmltodict == 0.13.0
You can’t perform that action at this time.
0 commit comments