--Apple-Mail=_7EAF7C88-C1BC-4F5F-800E-30A0F63EE9E8
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain;
charset=us-ascii
I writting code to generate a VM.
But I'm getting :
Traceback (most recent call last):
...
newvm =3D self.api.vms.add(params.VM(**kwargs))
File =
"build/bdist.macosx-10.10-x86_64/egg/ovirtsdk/infrastructure/brokers.py", =
line 35195, in add
File =
"build/bdist.macosx-10.10-x86_64/egg/ovirtsdk/utils/parsehelper.py", =
line 53, in toXml
File "build/bdist.macosx-10.10-x86_64/egg/ovirtsdk/xml/params.py", =
line 24888, in export_
File "build/bdist.macosx-10.10-x86_64/egg/ovirtsdk/xml/params.py", =
line 24946, in exportChildren
AttributeError: 'str' object has no attribute 'export_'
I made a bug in my call to params.VM. But I have no way to know which =
argument is wrong, the message is too terse :
AttributeError: 'str' object has no attribute 'export_'
It should be better if the given attribute name was given, it will save =
me time.=
--Apple-Mail=_7EAF7C88-C1BC-4F5F-800E-30A0F63EE9E8
Content-Transfer-Encoding: quoted-printable
Content-Type: text/html;
charset=us-ascii
<html><head><meta http-equiv=3D"Content-Type"
content=3D"text/html =
charset=3Dus-ascii"></head><body style=3D"word-wrap: break-word; =
-webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" =
class=3D"">I writting code to generate a VM.<div
class=3D""><br =
class=3D""></div><div class=3D"">But I'm getting
:</div><div =
class=3D""><div style=3D"margin: 0px; font-size: 11px; font-family:
=
Menlo;" class=3D"">Traceback (most recent call last):</div><div
=
style=3D"margin: 0px; font-size: 11px; font-family: Menlo;" =
class=3D""> ...</div><div style=3D"margin: 0px;
font-size: 11px; =
font-family: Menlo;" class=3D""> newvm =3D =
self.api.vms.add(params.VM(**kwargs))</div><div style=3D"margin: 0px; =
font-size: 11px; font-family: Menlo;" class=3D""> File =
"build/bdist.macosx-10.10-x86_64/egg/ovirtsdk/infrastructure/brokers.py", =
line 35195, in add</div><div style=3D"margin: 0px; font-size: 11px; =
font-family: Menlo;" class=3D""> File =
"build/bdist.macosx-10.10-x86_64/egg/ovirtsdk/utils/parsehelper.py", =
line 53, in toXml</div><div style=3D"margin: 0px; font-size: 11px; =
font-family: Menlo;" class=3D""> File =
"build/bdist.macosx-10.10-x86_64/egg/ovirtsdk/xml/params.py", line =
24888, in export_</div><div style=3D"margin: 0px; font-size: 11px; =
font-family: Menlo;" class=3D""> File =
"build/bdist.macosx-10.10-x86_64/egg/ovirtsdk/xml/params.py", line =
24946, in exportChildren</div><div style=3D"margin: 0px; font-size: =
11px; font-family: Menlo;" class=3D"">AttributeError: 'str'
object has =
no attribute 'export_'</div></div><div
class=3D""><br =
class=3D""></div><div class=3D"">I made a bug in my
call to <span =
style=3D"font-family: Menlo; font-size: 11px;"
class=3D"">params.VM. But =
I have no way to know which argument is wrong, the message is too terse =
:</span></div><div class=3D""><div
class=3D""><div style=3D"margin: 0px; =
font-size: 11px; font-family: Menlo;" class=3D"">
=
AttributeError: 'str' object has no attribute =
'export_'</div></div></div><div
class=3D""><br class=3D""></div><div =
class=3D"">It should be better if the given attribute name was given, it =
will save me time.</div></body></html>=
--Apple-Mail=_7EAF7C88-C1BC-4F5F-800E-30A0F63EE9E8--