Ticket #9018 (closed: fixed)

Opened 7 years ago

Last modified 5 years ago

validateInputs caller should error if non-existent parameter is specified

Reported by: Peter Peterson Owned by: Peter Peterson
Priority: major Milestone: Release 3.2
Component: Framework Keywords:
Cc: Blocked By:
Blocking: Tester: Wenduo Zhou

Description

While working on #8979 I discovered that the user gets a pop-up saying that some parameters are invalid, but that none of them are marked when validateInputs returns a non-existent parameter name. It should log a warning and just run the algorithm.

Change History

comment:1 Changed 7 years ago by Peter Peterson

  • Status changed from new to assigned

comment:2 Changed 7 years ago by Peter Peterson

Re #9018. Adding IPropertyManager::hasProperty to make work easier.

Changeset: 5a936d357d5c2281aaf366f2dc2419279201275a

comment:3 Changed 7 years ago by Peter Peterson

Re #9018. Warn about bad names from validateInputs rather than error.

Changeset: a290e83d62eeb63871cbcdc2a19c5f1a1a7f429e

comment:4 Changed 7 years ago by Peter Peterson

Re #9018. Don't display pop-up if validateInputs gives bad param name.

Changeset: 3bb251464792b5414b401916b787c863f1452ecd

comment:5 Changed 7 years ago by Peter Peterson

Merge branch 'bugfix/9018_validate_inputs' into develop

Conflicts:

Code/Mantid/Framework/API/src/Algorithm.cpp

Re #9018

Changeset: bf71103bb8676de036a5eb79dda21c6a9efbd031

comment:6 Changed 7 years ago by Peter Peterson

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

This is on bugfix/9018_validate_inputs

To test: Basically this is the same as #8979. In an algorithm's "validateInputs" have one of the returned parameter names be something that doesn't exist. Otherwise this should have no effect.

comment:7 Changed 7 years ago by Martyn Gigg

  • Status changed from verify to reopened
  • Resolution fixed deleted

The new IPropertyManager::hasProperty method seems to be duplicating the existing IPropertyManager::existsProperty method. I think the hasProperty name is better but I think we shouldn't have both.

comment:8 Changed 7 years ago by Peter Peterson

  • Status changed from reopened to inprogress

comment:9 Changed 7 years ago by Peter Peterson

Re #9018. Renaming existsProperty to hasProperty.

Changeset: fc73ab5fccf12298269d803e7c83bd3a4bba7411

comment:10 Changed 7 years ago by Peter Peterson

Merge branch 'bugfix/9018_validate_inputs' into develop

Conflicts:

Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/PropertyManager.cpp

Re #9018

Changeset: 1945a396d2564ca55b82279ee377ade4703e80ea

comment:11 Changed 7 years ago by Peter Peterson

Re #9018. Missed a bunch of references.

Changeset: 5b31912e5f6f1e54cdc264e57a4a376809b524d0

comment:12 Changed 7 years ago by Peter Peterson

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

comment:13 Changed 7 years ago by Peter Peterson

  • Status changed from verify to reopened
  • Resolution fixed deleted

There is a problem in the system tests.

comment:14 Changed 7 years ago by Russell Taylor

All the commits to this ticket have been pulled out of the develop branch for the time being as they were breaking all the ORNL SANS system tests.

Probably, no matter which method name is slightly better it's most sensible to just stick with the existing existsProperty one.

comment:15 Changed 7 years ago by Peter Peterson

  • Status changed from reopened to inprogress

Re #9018. Adding IPropertyManager::hasProperty to make work easier.

Changeset: 8763d086b9688054dfd4baba2fcc6b2e48ce6915

comment:16 Changed 7 years ago by Peter Peterson

Re #9018. Warn about bad names from validateInputs rather than error.

Changeset: 2b2554954bed5e24620584a71e0aa34e9af30808

comment:17 Changed 7 years ago by Peter Peterson

Re #9018. Don't display pop-up if validateInputs gives bad param name.

Changeset: 960aa1b14ea50a6ef627af6a83c646926aaedf60

comment:18 Changed 7 years ago by Peter Peterson

Re #9018. Changed all the names to existsProperty.

Changeset: 27f6653eb53b8cd350d6d31e8d51f4afc53b1b7d

comment:19 Changed 7 years ago by Peter Peterson

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

Same tester information as comment:6.

comment:20 Changed 7 years ago by Wenduo Zhou

  • Status changed from verify to verifying
  • Tester set to Wenduo Zhou

comment:21 Changed 7 years ago by Wenduo Zhou

  • Status changed from verifying to closed

Merge remote-tracking branch 'origin/bugfix/9018_validate_inputs'

Full changeset: 2e7138a40580fc650c591b031be6b3eaf9972e00

comment:22 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 9861

Note: See TracTickets for help on using tickets.