Ticket #5701 (closed: fixed)

Opened 8 years ago

Last modified 5 years ago

Python execution of QueryMDWorkspace

Reported by: Owen Arnold Owned by: Martyn Gigg
Priority: major Milestone: Release 2.2
Component: Mantid Keywords:
Cc: reuterma@… Blocked By:
Blocking: #5484 Tester: Owen Arnold

Description

KeyError generated in the python output after running this simple code snippet. The output workspace is actually created correctly. The equivalent works if run in the MantidPlot gui.

CreateMDHistoWorkspace(SignalInput='1,2,3,4,5',ErrorInput='1,1,1,1,1',Dimensionality='1',Extents='-1,1',NumberOfBins='5',Names='A',Units='U',OutputWorkspace='demo')

QueryMDWorkspace(InputWorkspace='demo',OutputWorkspace='query',MaximumRows='500',Normalisation='volume')

Change History

comment:1 Changed 8 years ago by Martyn Gigg

  • Status changed from new to accepted

comment:2 Changed 8 years ago by Martyn Gigg

The problem is that QueryMDWorkspace has an optional output workspace but Python isn't checking that it is optional and falls over when it doesn't exist. Easy to fix.

comment:3 Changed 8 years ago by Martyn Gigg

Fix returns for simple Python functions for optional ws. Refs #5701

Also add two extra tests for optional workspace properties.

Changeset: c3f80d6272dba4c65b9a67a817d3af90be364864

comment:4 Changed 8 years ago by Martyn Gigg

  • Status changed from accepted to verify
  • Resolution set to fixed

comment:5 Changed 8 years ago by Owen Arnold

  • Status changed from verify to verifying
  • Tester set to Owen Arnold

comment:6 Changed 8 years ago by Owen Arnold

  • Status changed from verifying to closed

This works now.

comment:7 Changed 8 years ago by Martyn Gigg

Fix returns for simple Python functions for optional ws. Refs #5701

Also add two extra tests for optional workspace properties.

Changeset: c3f80d6272dba4c65b9a67a817d3af90be364864

comment:8 Changed 8 years ago by Martyn Gigg

Fix returns for simple Python functions for optional ws. Refs #5701

Also add two extra tests for optional workspace properties.

Changeset: c3f80d6272dba4c65b9a67a817d3af90be364864

comment:9 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 6547

Note: See TracTickets for help on using tickets.