Project

General

Profile

Bug #47185

TypeError: _daemon_add_misc() got an unexpected keyword argument

Added by Sebastian Wagner about 2 months ago. Updated about 2 months ago.

Status:
Resolved
Priority:
Urgent
Assignee:
-
Category:
orchestrator
Target version:
-
% Done:

0%

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

Description

https://pulpito.ceph.com/swagner-2020-08-28_09:46:34-rados:cephadm-wip-swagner-testing-2020-08-28-1004-distro-basic-smithi/5383116/

2020-08-28T10:01:45.393 INFO:teuthology.orchestra.run.smithi044:> sudo /home/ubuntu/cephtest/cephadm --image quay.ceph.io/ceph-ci/ceph:6258ea1dcfe72989baca3f3155cff7e60f2b9ac9 shell -c /etc/ceph/ceph.conf -k /etc/ceph/ceph.client.admin.keyring --fsid 19d8afaa-e915-11ea-a074-001a4aab830c -- ceph orch daemon add mon 'smithi044:[v2:172.21.15.44:3301,v1:172.21.15.44:6790]=c'
2020-08-28T10:01:47.113 INFO:teuthology.orchestra.run.smithi044.stderr:Error EINVAL: Traceback (most recent call last):
2020-08-28T10:01:47.114 INFO:teuthology.orchestra.run.smithi044.stderr:  File "/usr/share/ceph/mgr/mgr_module.py", line 1191, in _handle_command
2020-08-28T10:01:47.114 INFO:teuthology.orchestra.run.smithi044.stderr:    return self.handle_command(inbuf, cmd)
2020-08-28T10:01:47.114 INFO:teuthology.orchestra.run.smithi044.stderr:  File "/usr/share/ceph/mgr/orchestrator/_interface.py", line 141, in handle_command
2020-08-28T10:01:47.114 INFO:teuthology.orchestra.run.smithi044.stderr:    return dispatch[cmd['prefix']].call(self, cmd, inbuf)
2020-08-28T10:01:47.115 INFO:teuthology.orchestra.run.smithi044.stderr:  File "/usr/share/ceph/mgr/mgr_module.py", line 328, in call
2020-08-28T10:01:47.115 INFO:teuthology.orchestra.run.smithi044.stderr:    return self.func(mgr, **kwargs)
2020-08-28T10:01:47.115 INFO:teuthology.orchestra.run.smithi044.stderr:  File "/usr/share/ceph/mgr/orchestrator/_interface.py", line 103, in <lambda>
2020-08-28T10:01:47.115 INFO:teuthology.orchestra.run.smithi044.stderr:    wrapper_copy = lambda *l_args, **l_kwargs: wrapper(*l_args, **l_kwargs)
2020-08-28T10:01:47.115 INFO:teuthology.orchestra.run.smithi044.stderr:  File "/usr/share/ceph/mgr/orchestrator/_interface.py", line 92, in wrapper
2020-08-28T10:01:47.116 INFO:teuthology.orchestra.run.smithi044.stderr:    return func(*args, **kwargs)
2020-08-28T10:01:47.116 INFO:teuthology.orchestra.run.smithi044.stderr:TypeError: _daemon_add_misc() got an unexpected keyword argument 'smithi044:[v2:172.21.15.44:3301,v1:172.21.15.44:6790]'
2020-08-28T10:01:47.116 INFO:teuthology.orchestra.run.smithi044.stderr:

src: https://github.com/ceph/ceph-ci/blame/wip-swagner-testing-2020-08-28-1004/src/pybind/mgr/orchestrator/module.py#L769-L774

Possible cause: https://github.com/ceph/ceph-ci/commit/ee9dea6cbf9879208ca88786e7f3a944d479e9ed

History

#1 Updated by Sebastian Wagner about 2 months ago

  • Description updated (diff)

#2 Updated by Kefu Chai about 2 months ago

  • Priority changed from Normal to Urgent

#4 Updated by Kefu Chai about 2 months ago

ceph orch daemon add mon 'smithi044:[v2:172.21.15.44:3301,v1:172.21.15.44:6790]=c'

is parsed into a dict of

{"daemon_type": "mon",
 "placement": "smithi044:[v2:172.21.15.44:3301,v1:172.21.15.44:6790]=c}" 

while CLICommand.call() splits "smithi044:[v2:172.21.15.44:3301,v1:172.21.15.44:6790]=c}" into

{"smithi044:[v2:172.21.15.44:3301,v1:172.21.15.44:6790]": "c"}

hence the failure

Jan, what's the use case of passing key-worded arguments? i think the "ceph" cli should have already done the parsing job which always sends the properly parsed dict to ceph daemons according to the command spec.

#5 Updated by Kefu Chai about 2 months ago

also,

In [1]: "hello".split('=')
Out[1]: ['hello']

does not throw.

#6 Updated by Kefu Chai about 2 months ago

  • Pull request ID set to 36877

#7 Updated by Sebastian Wagner about 2 months ago

  • Status changed from New to Resolved

Also available in: Atom PDF