canonical / checkbox

Checkbox
https://checkbox.readthedocs.io
GNU General Public License v3.0
30 stars 47 forks source link

Traceback when unable to resume after CTRL-C #1270

Open bladernr opened 3 months ago

bladernr commented 3 months ago

Bug Description

I came back to a test that was sitting at the review screen (where you can pick failed / skipped tests to re-run) and hit F to finish. I realized I needed to do something else, so I hit CTRL-C and restarted using the test-memory launcher from the server provider.

However, now, every attempt fails with a traceback as outlined in the log output below.

My initial guess on this is that because I Hit F it had already started marking things as non-resumable and crafting the submission file, and that makes it "resume not-supported"

So this is probably more about cleaning up or handling that exception to be more user friendly / informative.

Workaround to unstick this was to delete the session data in /var/tmp.

To Reproduce

Ran test-memory until end of run On the review screen I hit F to finish but then quicly hit CTRL-C to cancel out completely Restarted test-memory Get traceback.

Environment

Checkbox v 4.0.0.dev292 from edge PPA Noble on Z13 LPAR instance

Relevant log output

ubuntu@s1lp10-jeff-lane:~$ test-memory
WARNING:plainbox.secure.providers.v1:Skipped file: /usr/share/checkbox-provider-base/units/camera/README.rst
WARNING:plainbox.secure.providers.v1:Skipped file: /usr/share/checkbox-provider-base/units/snapd/README.md
WARNING:plainbox.secure.providers.v1:Skipped file: /usr/share/checkbox-provider-base/units/stress/suspend_cycles_reboot.md
Traceback (most recent call last):
  File "/usr/bin/checkbox-cli", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/usr/lib/python3/dist-packages/checkbox_ng/launcher/checkbox_cli.py", line 166, in main
    return subcmd.invoked(ctx)
           ^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/checkbox_ng/launcher/subcommands.py", line 257, in invoked
    if not self._auto_resume_session(self.resume_candidates):
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/checkbox_ng/launcher/subcommands.py", line 425, in _auto_resume_session
    self._resume_session(last_session.id, None)
  File "/usr/lib/python3/dist-packages/checkbox_ng/launcher/subcommands.py", line 597, in _resume_session
    raise ValueError(
ValueError: Unsupported outcome for resume not-supported

Additional context

No response

syncronize-issues-to-jira[bot] commented 3 months ago

Thank you for reporting us your feedback!

The internal ticket has been created: https://warthogs.atlassian.net/browse/CHECKBOX-1457.

This message was autogenerated