Closed mmascher closed 2 years ago
It surns out that in python2 you could use urllib to open a local file (/var/lib/gwms-factory/work-dir/monitor/rrd_Log_Completed.xml in this case), but with python3 you need to inser file:// to avoid this error:
/var/lib/gwms-factory/work-dir/monitor/rrd_Log_Completed.xml
file://
ValueError: unknown url type: '/var/lib/gwms-factory/work-dir/monitor/rrd_Log_Completed.xml'
Also, you cannot use .sort() on the result of a dict.keys() since this is a view and not an iterator now. I was getting:
.sort()
dict.keys()
AttributeError: 'dict_keys' object has no attribute 'sort'
It surns out that in python2 you could use urllib to open a local file (
/var/lib/gwms-factory/work-dir/monitor/rrd_Log_Completed.xml
in this case), but with python3 you need to inserfile://
to avoid this error:ValueError: unknown url type: '/var/lib/gwms-factory/work-dir/monitor/rrd_Log_Completed.xml'
Also, you cannot use
.sort()
on the result of adict.keys()
since this is a view and not an iterator now. I was getting:AttributeError: 'dict_keys' object has no attribute 'sort'