Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DEFECT] Input reader doesn't strip Out whitespace when reading array #1102

Closed
10 tasks done
heagysa opened this issue Nov 18, 2019 · 1 comment · Fixed by #1118
Closed
10 tasks done

[DEFECT] Input reader doesn't strip Out whitespace when reading array #1102

heagysa opened this issue Nov 18, 2019 · 1 comment · Fixed by #1118

Comments

@heagysa
Copy link

heagysa commented Nov 18, 2019


Defect Description

Describe the defect

I was utilizing an array of RELAP5 input card numbers for a sampler, so the same sampling was performed for multiple locations in my RELAP5

Spaces_In_Sampler_Array.zip

input and when i put a space in the input array it caused RAVEN to abort.

  <variable name="7290102:1, 7290103:1">
What did you see instead?

RAVEN aborted with a non-descriptive error message:
Traceback (most recent call last):
File "/home/cgosdin/RAVEN_FPS/RAVEN_FPS/framework/DataObjects/DataSet.py", line 201, in addRealization
rlz = dict((var,rlz[var]) for var in self.getVars()+self.indexes)
File "/home/cgosdin/RAVEN_FPS/RAVEN_FPS/framework/DataObjects/DataSet.py", line 201, in
rlz = dict((var,rlz[var]) for var in self.getVars()+self.indexes)
KeyError: 'ProbabilityWeight- 7290103:1'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/cgosdin/RAVEN_FPS/RAVEN_FPS/framework/Driver.py", line 285, in
raven()
File "/home/cgosdin/RAVEN_FPS/RAVEN_FPS/framework/Driver.py", line 238, in raven
simulation.run()
File "/home/cgosdin/RAVEN_FPS/RAVEN_FPS/framework/Simulation.py", line 780, in run
stepInstance.takeAstep(stepInputDict)
File "/home/cgosdin/RAVEN_FPS/RAVEN_FPS/framework/Steps.py", line 315, in takeAstep
self._localTakeAstepRun(inDictionary)
File "/home/cgosdin/RAVEN_FPS/RAVEN_FPS/framework/Steps.py", line 640, in _localTakeAstepRun
myLambda([finishedJob,outputs[outIndex]])
File "/home/cgosdin/RAVEN_FPS/RAVEN_FPS/framework/Steps.py", line 588, in
self._outputCollectionLambda.append( (lambda x: inDictionary['Model'].collectOutput(x[0],x[1]), outIndex) )
File "/home/cgosdin/RAVEN_FPS/RAVEN_FPS/framework/Models/Code.py", line 747, in collectOutput
output.addRealization(evaluation)
File "/home/cgosdin/RAVEN_FPS/RAVEN_FPS/framework/DataObjects/DataSet.py", line 204, in addRealization
self.raiseAnError(KeyError,'Provided realization does not have all requisite values for object "{}": "{}"'.format(self.name,e.args[0]))
File "/home/cgosdin/RAVEN_FPS/RAVEN_FPS/framework/MessageHandler.py", line 99, in raiseAnError
self.messageHandler.error(self,etype,msg,str(tag),verbosity,color)
File "/home/cgosdin/RAVEN_FPS/RAVEN_FPS/framework/MessageHandler.py", line 313, in error
raise etype(message)
KeyError: 'Provided realization does not have all requisite values for object "RELAPoutput": "ProbabilityWeight- 7290103:1"'
/home/cgosdin/RAVEN_FPS/RAVEN_FPS/raven_framework: line 56: 49370 Segmentation fault (core dumped) $PYTHON_COMMAND -O $RAVEN_DIR/framework/Driver.py "${ARGS[@]}"

Do you have a suggested fix for the development team?

Input reader should strip whitespace before reading.

Describe how to Reproduce
Steps to reproduce the behavior:

  1. Unzip file.
    2
    raven.log

. Rerun RAVEN.

Screenshots and Input Files
Please attach the input file(s) that generate this error. The simpler the input, the faster we can find the issue.

Platform (please complete the following information):

  • OS: LSB Version: n/a
    Distributor ID: SUSE
    Description: SUSE Linux Enterprise Server 12 SP4
    Release: 12.4
    Codename: n/a

  • Dependencies Installation: CONDA


For Change Control Board: Issue Review

This review should occur before any development is performed as a response to this issue.

  • 1. Is it tagged with a type: defect or task?
  • 2. Is it tagged with a priority: critical, normal or minor?
  • 3. If it will impact requirements or requirements tests, is it tagged with requirements?
  • 4. If it is a defect, can it cause wrong results for users? If so an email needs to be sent to the users.
  • 5. Is a rationale provided? (Such as explaining why the improvement is needed or why current code is wrong.)

For Change Control Board: Issue Closure

This review should occur when the issue is imminently going to be closed.

  • 1. If the issue is a defect, is the defect fixed?
  • 2. If the issue is a defect, is the defect tested for in the regression test system? (If not explain why not.)
  • 3. If the issue can impact users, has an email to the users group been written (the email should specify if the defect impacts stable or master)?
  • 4. If the issue is a defect, does it impact the latest release branch? If yes, is there any issue tagged with release (create if needed)?
  • 5. If the issue is being closed without a pull request, has an explanation of why it is being closed been provided?
@alfoa alfoa self-assigned this Dec 5, 2019
alfoa added a commit that referenced this issue Dec 5, 2019
@alfoa alfoa mentioned this issue Dec 5, 2019
9 tasks
@PaulTalbot-INL
Copy link
Collaborator

Impact to users is only a crash, so no notification required.

Approved to close via #1118

wangcj05 pushed a commit that referenced this issue Jan 8, 2020
* Closes #1102

* modified relap5 test to check for multiple variables to change in the same card

* Closes #1103

* added new inputdata type
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants