Project

General

Profile

Bug #40729

qa: vstart_runner fails because of string index out of range

Added by Volker Theile 4 months ago. Updated 4 months ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
-
Target version:
Start date:
07/11/2019
Due date:
% Done:

0%

Source:
Development
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature:

Description

When running the tasks.mgr.dashboard.test_auth.AuthTest QA test via vstart the following error occurs;

2019-07-11 12:50:40,896.896 INFO:__main__:======================================================================
2019-07-11 12:50:40,896.896 INFO:__main__:ERROR: test_login_without_password (tasks.mgr.dashboard.test_auth.AuthTest)
2019-07-11 12:50:40,896.896 INFO:__main__:----------------------------------------------------------------------
2019-07-11 12:50:40,896.896 INFO:__main__:Traceback (most recent call last):
2019-07-11 12:50:40,896.896 INFO:__main__:  File "/ceph/qa/tasks/mgr/dashboard/test_auth.py", line 32, in test_login_without_password
2019-07-11 12:50:40,897.897 INFO:__main__:    self.create_user('admin2', '', ['administrator'])
2019-07-11 12:50:40,897.897 INFO:__main__:  File "/ceph/qa/tasks/mgr/dashboard/helper.py", line 46, in create_user
2019-07-11 12:50:40,897.897 INFO:__main__:    cls._ceph_cmd(['dashboard', 'ac-user-create', username, password])
2019-07-11 12:50:40,897.897 INFO:__main__:  File "/ceph/qa/tasks/mgr/dashboard/helper.py", line 367, in _ceph_cmd
2019-07-11 12:50:40,897.897 INFO:__main__:    res = cls.mgr_cluster.mon_manager.raw_cluster_cmd(*cmd)
2019-07-11 12:50:40,897.897 INFO:__main__:  File "../qa/tasks/vstart_runner.py", line 700, in raw_cluster_cmd
2019-07-11 12:50:40,897.897 INFO:__main__:    proc = self.controller.run([os.path.join(BIN_PREFIX, "ceph")] + list(args), **kwargs)
2019-07-11 12:50:40,897.897 INFO:__main__:  File "../qa/tasks/vstart_runner.py", line 287, in run
2019-07-11 12:50:40,898.898 INFO:__main__:    args = self._perform_checks_and_return_list_of_args(args, omit_sudo)
2019-07-11 12:50:40,898.898 INFO:__main__:  File "../qa/tasks/vstart_runner.py", line 263, in _perform_checks_and_return_list_of_args
2019-07-11 12:50:40,898.898 INFO:__main__:    if (arg[0] in ['"', "'"] or arg[-1] in ['"', "'"]) and \
2019-07-11 12:50:40,898.898 INFO:__main__:IndexError: string index out of range
2019-07-11 12:50:40,898.898 INFO:__main__:

The problem occurs when LocalCephManager::raw_cluster_cmd() is called with a empty command parameter, e.g.

DashboardTestCase::_ceph_cmd(['dashboard', 'ac-user-create', 'foo', ''])

History

#1 Updated by Volker Theile 4 months ago

  • Description updated (diff)

#2 Updated by Volker Theile 4 months ago

  • Description updated (diff)

#3 Updated by Volker Theile 4 months ago

  • Description updated (diff)

#4 Updated by Volker Theile 4 months ago

  • Status changed from New to Need Review
  • Pull request ID set to 28990

#5 Updated by Sage Weil 4 months ago

  • Status changed from Need Review to Resolved

Also available in: Atom PDF