Ticket #5420 (closed: fixed)

Opened 8 years ago

Last modified 5 years ago

Resetting instrument geometry shouldn't delete the rest of the instrument

Reported by: Peter Peterson Owned by: Wenduo Zhou
Priority: minor Milestone: Release 2.3
Component: Mantid Keywords:
Cc: Blocked By:
Blocking: Tester: Russell Taylor

Description

EditInstrumentGeometry should error out if not enough information is provided rather than quietly deleting the instrument.

Change History

comment:1 Changed 8 years ago by Nick Draper

  • Milestone changed from Release 2.2 to Release 2.3

comment:2 Changed 8 years ago by Wenduo Zhou

Make algorithm quit under incomplete information. Refs #5420.

Changeset: 81cf8eead16afc52a076a8e38b19efec4b6b4988

comment:3 Changed 8 years ago by Wenduo Zhou

  • Status changed from new to accepted

comment:4 Changed 8 years ago by Wenduo Zhou

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

comment:5 Changed 8 years ago by Russell Taylor

  • Status changed from verify to verifying
  • Tester set to Russell Taylor

comment:6 Changed 8 years ago by Russell Taylor

  • Status changed from verifying to closed

Input error checking looks stronger now.

Several comments:

  • Unit tests for the failure cases would be a good idea.
  • A negative PrimaryFlightPath looks to have a special meaning in the code, but this is not documented anywhere
  • Most of the delete spec2indexmap statements (which are missing in several necessary places) could be avoided by localising the initial creation close to the one place where it's actually used and deleting right afterwards.
  • vector::push_back (see lines 195-200) is inefficient and should be avoided if you know the size of the vector at the point of declaration (which you do).

comment:7 Changed 8 years ago by Wenduo Zhou

Make algorithm quit under incomplete information. Refs #5420.

Changeset: 81cf8eead16afc52a076a8e38b19efec4b6b4988

comment:8 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 6266

Note: See TracTickets for help on using tickets.