Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1597040

Summary: 0.0 runtime causes ValueError: math domain error
Product: Red Hat OpenStack Reporter: Attila Fazekas <afazekas>
Component: python-stestrAssignee: Chandan Kumar <chkumar>
Status: CLOSED ERRATA QA Contact: Martin Kopec <mkopec>
Severity: high Docs Contact:
Priority: high    
Version: 13.0 (Queens)CC: chkumar, whayutin
Target Milestone: z3Keywords: Triaged, ZStream
Target Release: 13.0 (Queens)   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: python-stestr-2.1.0-1.el7ost Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-11-14 01:14:59 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Attila Fazekas 2018-07-01 20:05:56 UTC
Description of problem:
ostestr -r nothingtorun
The specified regex doesn't match with anything
Slowest Tests:
Traceback (most recent call last):
  File "/bin/ostestr", line 10, in <module>
    sys.exit(main())
  File "/usr/lib/python2.7/site-packages/os_testr/ostestr.py", line 263, in main
    exit(ostestr(sys.argv[1:]))
  File "/usr/lib/python2.7/site-packages/os_testr/ostestr.py", line 259, in ostestr
    return _select_and_call_runner(opts, regex, others)
  File "/usr/lib/python2.7/site-packages/os_testr/ostestr.py", line 212, in _select_and_call_runner
    black_regex=opts.black_regex)
  File "/usr/lib/python2.7/site-packages/os_testr/ostestr.py", line 171, in call_testr
    commands.slowest_command()
  File "/usr/lib/python2.7/site-packages/stestr/commands/slowest.py", line 93, in slowest
    known_times = format_times(known_times)
  File "/usr/lib/python2.7/site-packages/stestr/commands/slowest.py", line 42, in format_times
    math.log10(times[0][1])) + 1
ValueError: math domain error


Version-Release number of selected component (if applicable):
python2-stestr-1.1.0-1.el7ost.1.noarch




Expected results:
No excpetion

Comment 1 Attila Fazekas 2018-07-20 08:52:28 UTC
Looks like you actually need to run a skipped test or something which fails within time resolution.

$ ostestr -r test_reboot_server_soft

Comment 3 Martin Kopec 2018-09-13 16:51:58 UTC
The fixes has been merged -> moving the bug to POST
Now those changes need to be included in the next python-stestr release.

Comment 15 Martin Kopec 2018-10-25 20:15:10 UTC
The python-stestr-2.1.0-1.el7ost package contains fix of the issue. It's available since 2018-10-22.4 puddle. 

Steps of verification:

[stack@undercloud-0 ~]$ sudo rpm -qa | grep stestr
python2-stestr-1.1.0-1.el7ost.1.noarch
[stack@undercloud-0 tempest-dir]$ ostestr -r AttachVolumeMultiAttachTest
{1} setUpClass (tempest.api.compute.admin.test_volume_swap.AttachVolumeMultiAttachTest) ... SKIPPED: The microversion range[2.60 - latest] of this test is out of the configuration range[None - None].
{0} setUpClass (tempest.api.compute.volumes.test_attach_volume.AttachVolumeMultiAttachTest) ... SKIPPED: The microversion range[2.60 - latest] of this test is out of the configuration range[None - None].

======
Totals
======
Ran: 2 tests in 1.0000 sec.
 - Passed: 0
 - Skipped: 2
 - Expected Fail: 0
 - Unexpected Success: 0
 - Failed: 0
Sum of execute time for each test: 0.0000 sec.

==============
Worker Balance
==============
 - Worker 0 (1 tests) => 0:00:00
 - Worker 1 (1 tests) => 0:00:00

Slowest Tests:
Traceback (most recent call last):
  File "/bin/ostestr", line 10, in <module>
    sys.exit(main())
  File "/usr/lib/python2.7/site-packages/os_testr/ostestr.py", line 263, in main
    exit(ostestr(sys.argv[1:]))
  File "/usr/lib/python2.7/site-packages/os_testr/ostestr.py", line 259, in ostestr
    return _select_and_call_runner(opts, regex, others)
  File "/usr/lib/python2.7/site-packages/os_testr/ostestr.py", line 212, in _select_and_call_runner
    black_regex=opts.black_regex)
  File "/usr/lib/python2.7/site-packages/os_testr/ostestr.py", line 171, in call_testr
    commands.slowest_command()
  File "/usr/lib/python2.7/site-packages/stestr/commands/slowest.py", line 93, in slowest
    known_times = format_times(known_times)
  File "/usr/lib/python2.7/site-packages/stestr/commands/slowest.py", line 42, in format_times
    math.log10(times[0][1])) + 1
ValueError: math domain error



[stack@undercloud-0 tempest-dir]$ ostestr -r AttachVolumeMultiAttachTest
{1} setUpClass (tempest.api.compute.admin.test_volume_swap.AttachVolumeMultiAttachTest) ... SKIPPED: The microversion range[2.60 - latest] of this test is out of the configuration range[None - None].
{0} setUpClass (tempest.api.compute.volumes.test_attach_volume.AttachVolumeMultiAttachTest) ... SKIPPED: The microversion range[2.60 - latest] of this test is out of the configuration range[None - None].

======
Totals
======
Ran: 2 tests in 1.0000 sec.
 - Passed: 0
 - Skipped: 2
 - Expected Fail: 0
 - Unexpected Success: 0
 - Failed: 0
Sum of execute time for each test: 0.0000 sec.

==============
Worker Balance
==============
 - Worker 0 (1 tests) => 0:00:00
 - Worker 1 (1 tests) => 0:00:00

Slowest Tests:
Test id                                                                                  Runtime (s)
---------------------------------------------------------------------------------------  -----------
setUpClass (tempest.api.compute.admin.test_volume_swap.AttachVolumeMultiAttachTest)      0.000
setUpClass (tempest.api.compute.volumes.test_attach_volume.AttachVolumeMultiAttachTest)  0.000
[stack@undercloud-0 tempest-dir]$ 
[stack@undercloud-0 tempest-dir]$  sudo rpm -qa | grep stestr
python2-stestr-2.1.0-1.el7ost.noarch

Comment 19 errata-xmlrpc 2018-11-14 01:14:59 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2018:3611