Closed micheles closed 11 months ago
This is serious: the lack of the complete site collection breaks the gmf_data exporter. Attached is a breaking example: job.zip
$ oq export gmf_data
Traceback (most recent call last):
File "/home/michele/openquake/bin/oq", line 33, in <module>
sys.exit(load_entry_point('openquake.engine', 'console_scripts', 'oq')())
File "/home/michele/oq-engine/openquake/commands/__main__.py", line 48, in oq
sap.run(commands, prog='oq')
File "/home/michele/oq-engine/openquake/baselib/sap.py", line 212, in run
return _run(parser(funcdict, **parserkw), argv)
File "/home/michele/oq-engine/openquake/baselib/sap.py", line 203, in _run
return func(**dic)
File "/home/michele/oq-engine/openquake/commands/export.py", line 38, in main
fnames = export_((datastore_key, fmt), dstore)
File "/home/michele/oq-engine/openquake/baselib/general.py", line 571, in __call__
return self[key](obj, *args, **kw)
File "/home/michele/oq-engine/openquake/calculators/export/hazard.py", line 426, in export_gmf_data_csv
df['csi'] = decode(sitecol.custom_site_id[df.sid])
IndexError: index 698 is out of bounds for axis 0 with size 686
Right now storing a filtered site collection cause an issue, because when reading it, it becomes complete :-(