Actions
Bug #77589
closed
JM
KC
dashboard unit test WRT nvmeof cli is consistently failing make check
Bug #77589:
dashboard unit test WRT nvmeof cli is consistently failing make check
Due date:
% Done:
0%
Source:
Backport:
tentacle umbrella
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Tags (freeform):
Merge Commit:
Fixed In:
v21.3.0-338-gb4f29b38df
Released In:
Upkeep Timestamp:
2026-08-28T01:41:33+00:00
Description
Make check is consistently failing:
The following tests FAILED:
7 - run-tox-mgr-dashboard-py3 (Failed)
tests/test_host.py ..................... [ 36%]
tests/test_iscsi.py ............................................. [ 42%]
tests/test_nfs.py .............. [ 43%]
tests/test_notification.py .... [ 44%]
tests/test_nvmeof_cli.py ......F
__________ TestNvmeofCLICommand.test_command_return_empty_cmd_result ___________
self = <dashboard.tests.test_nvmeof_cli.TestNvmeofCLICommand object at 0x7a5c3a807250>
base_call_return_none_mock = <MagicMock id='134536497250464'>
sample_command = 'test command'
def test_command_return_empty_cmd_result(self, base_call_return_none_mock, sample_command):
result = NvmeofCLICommand.COMMANDS[sample_command].call(MagicMock(), {})
assert isinstance(result, HandleCommandResult)
> assert result.retval == 0
E AssertionError: assert -22 == 0
E + where -22 = HandleCommandResult(retval=-22, stdout='', stderr='max() arg is an empty sequence').retval
tests/test_nvmeof_cli.py:119: AssertionError
tests/test_nvmeof_cli.py ......................F
_ TestNvmeofCLICommandSuccessMessage.test_success_message_fn_failure_falls_back_to_default_formatting _
self = <dashboard.tests.test_nvmeof_cli.TestNvmeofCLICommandSuccessMessage object at 0x7a5c3a805330>
def test_success_message_fn_failure_falls_back_to_default_formatting(self):
test_cmd = "nvmeof success fn failure fallback"
class Model(NamedTuple):
status: str
@NvmeofCLICommand(
test_cmd,
Model,
success_message_template="TEMPLATE {nqn}",
success_message_fn=lambda _f: 1 / 0
)
def fn(self, nqn: str):
return {"status": 0}
res = NvmeofCLICommand.COMMANDS[test_cmd].call(
MagicMock(),
{"format": "plain", "nqn": "subsysB"}
)
> assert res.retval == 0
E AssertionError: assert -22 == 0
E + where -22 = HandleCommandResult(retval=-22, stdout='', stderr='max() arg is an empty sequence').retval
tests/test_nvmeof_cli.py:789: AssertionError
------------------------------ Captured log call -------------------------------
WARNING dashboard.services.nvmeof_cli:nvmeof_cli.py:447 success_message_fn failed for nvmeof success fn failure fallback
Traceback (most recent call last):
File "/ceph/src/pybind/mgr/dashboard/services/nvmeof_cli.py", line 444, in get_success_msg
return self._success_message_fn(merged_fields)
File "/ceph/src/pybind/mgr/dashboard/tests/test_nvmeof_cli.py", line 780, in <lambda>
success_message_fn=lambda _f: 1 / 0
ZeroDivisionError: division by zero
https://jenkins.ceph.com/job/ceph-pull-requests/186651/console
https://jenkins.ceph.com/job/ceph-pull-requests/186652/console
https://jenkins.ceph.com/job/ceph-pull-requests/186653/console
https://jenkins.ceph.com/job/ceph-pull-requests/186654/console
JM Updated by John Mulligan 5 months ago
- Description updated (diff)
UB Updated by Upkeep Bot 5 months ago
- Status changed from Fix Under Review to Resolved
- Merge Commit set to b4f29b38dfdd3ee2d83c44aa6ced47f704030d2f
- Fixed In set to v21.3.0-338-gb4f29b38df
- Upkeep Timestamp set to 2026-06-23T10:14:22+00:00
UB Updated by Upkeep Bot 5 months ago
- Copied to Backport #77608: tentacle: dashboard unit test WRT nvmeof cli is consistently failing make check added
UB Updated by Upkeep Bot 5 months ago
- Copied to Backport #77609: umbrella: dashboard unit test WRT nvmeof cli is consistently failing make check added
UB Updated by Upkeep Bot 5 months ago
- Tags (freeform) set to backport_processed
UB Updated by Upkeep Bot 3 months ago
- Tags (freeform) deleted (
backport_processed) - Upkeep Timestamp changed from 2026-06-23T10:14:22+00:00 to 2026-08-28T01:41:33+00:00
Actions