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] Key Error for unrelated problem when using ./run_tests #1489

Closed
10 tasks done
dylanjm opened this issue Mar 25, 2021 · 4 comments · Fixed by #1495
Closed
10 tasks done

[DEFECT] Key Error for unrelated problem when using ./run_tests #1489

dylanjm opened this issue Mar 25, 2021 · 4 comments · Fixed by #1495
Assignees
Labels
defect priority_minor RAVENv2.1 All tasks and defects that will go in RAVEN v2.1

Comments

@dylanjm
Copy link
Collaborator

dylanjm commented Mar 25, 2021


Defect Description

Describe the defect

If one doesn't have the "ExamplePlugin" plugin installed, then when using ./run_tests --re <pattern> you will receive an error at end showing something like:

Traceback (most recent call last):
  File "/Users/mcdodj/Documents/projects/raven/scripts/plugin_handler.py", line 207, in <module>
    raise KeyError('Plugin "{}" not installed!'.format(requested))
KeyError: 'Plugin "ExamplePlugin" not installed!'
What did you expect to see happen?

Given that I'm not testing a plugin, I probably shouldn't see errors regarding plugins. It gives way to confusion to see errors past the point of the program actually succeeding.

What did you see instead?

I saw errors concerning plugins when I wasn't testing plugins.

Do you have a suggested fix for the development team?

I'm assuming plugin_handler.py is run every time ./run_tests is run. Perhaps adding an --all flag will include plugin tests and thus run the plugin_handler.py script as well.

Describe how to Reproduce
Steps to reproduce the behavior:

  1. Try running ./run_tests --re Wavelet

Platform (please complete the following information):

  • OS: macOS 10.15.7
  • 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?
@PaulTalbot-INL
Copy link
Collaborator

The intention right now is the ExamplePlugin (which is part of the repo) always gets run even if no other plugins are installed. There are separate tests that run for the full suite of plugins, but the Example plugin is used to test RAVEN's plugin mechanics separate from external plugins.

This does assume that at some point it also is installed as a plugin, which we do on all the test machines, but do not do by default as part of the build process; I agree there could be some improvement here.

@alfoa
Copy link
Collaborator

alfoa commented Apr 1, 2021

The example plugin must be installed by the build_raven script. We can add it.
Good catch.
@dylanjm can you address it?

@dylanjm
Copy link
Collaborator Author

dylanjm commented Apr 1, 2021

@alfoa Sure thing.

dylanjm added a commit to dylanjm/raven that referenced this issue Apr 1, 2021
dylanjm added a commit to dylanjm/raven that referenced this issue Apr 6, 2021
@alfoa
Copy link
Collaborator

alfoa commented Apr 9, 2021

Closure checklist passed...

PR approved via #1495

No email is needed since this is a crash of the installation but not wrong results can be produced

alfoa pushed a commit that referenced this issue Apr 9, 2021
* Always install ExamplePlugin on build_raven

Refs #1489

* Move location of ExamplePlugin install

* Move ExamplePlugin install to establish_conda_env
@alfoa alfoa added the RAVENv2.1 All tasks and defects that will go in RAVEN v2.1 label Apr 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
defect priority_minor RAVENv2.1 All tasks and defects that will go in RAVEN v2.1
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants