Problem exporting aggregate loss curves

Bug #1169886 reported by matley
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenQuake Engine
Fix Released
Critical
matley

Bug Description

Let <hc> the ID of an hazard calculation. If you run an event based risk calculation by using such id you will get a number of aggregate loss curves. When you try to export one of it you will get the following error:

vsilva@hope:/usr/local/stow/openquake/oq-engine$ ./bin/openquake --er 118 /tmp/
Traceback (most recent call last):
  File "./bin/openquake", line 614, in <module>
    main()
  File "./bin/openquake", line 590, in main
    export_risk(output_id, expanduser(target_dir))
  File "./bin/openquake", line 404, in export_risk
    export(risk_export.export, risk_output_id, target_dir)
  File "./bin/openquake", line 417, in export
    files = fn(output_id, target_dir)
  File "/usr/local/stow/openquake/oq-engine/openquake/engine/export/risk.py", line 53, in export
    return [fn(output, os.path.expanduser(target_dir))]
  File "/usr/local/stow/openquake/oq-engine/openquake/engine/export/core.py", line 49, in wrapped
    return fn(output, target_dir)
  File "/usr/local/stow/openquake/oq-engine/openquake/engine/export/risk.py", line 88, in export_agg_loss_curve_xml
    args = _export_common(output)
  File "/usr/local/stow/openquake/oq-engine/openquake/engine/export/risk.py", line 61, in _export_common
    metadata = output.hazard_metadata
  File "/usr/local/stow/openquake/oq-engine/openquake/engine/db/models.py", line 1622, in hazard_metadata
    ' "%s"' % self.output_type
RuntimeError: Error getting hazard metadata: Unexpected output_type "agg_loss_curve"

Revision history for this message
matley (matley) wrote :
matley (matley)
Changed in oq-engine:
status: New → Fix Committed
Changed in oq-engine:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.