<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:SimSun;
panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
{font-family:SimSun;
panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:SimSun;
panose-1:2 1 6 0 3 1 1 1 1 1;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:"Calibri","sans-serif";
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.25in 1.0in 1.25in;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal">Hi <o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I’m a freshman in openstack. I want to contribute and learn some exciting by joining openstack. I will be grateful if anyone can help me on my starting process.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Now I encounter a problem when I tried the UT with tox.<o:p></o:p></p>
<p class="MsoNormal">I execute the following command,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><span style="color:#0070C0">(.venv-nova)[jiapei2@localhost nova]$ tox -e py27 tests.unit.api.openstack.compute.test_server_action<o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">And then I got the results:<o:p></o:p></p>
<p class="MsoNormal"><span style="color:#0070C0">=====<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">Totals<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">======<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">Ran: 136 tests in 51.0000 sec.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">- Passed: 40<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">- Skipped: 0<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">- Expected Fail: 0<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">- Unexpected Success: 0<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">- Failed: 96<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">Sum of execute time for each test: 293.4456 sec.</span><o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">One of the errors is like,<o:p></o:p></p>
<p class="MsoNormal"><span style="color:#0070C0">~~~~~~~~~~~~~~~~~~~~~~~<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">Captured pythonlogging:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">~~~~~~~~~~~~~~~~~~~~~~~<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> 2017-03-24 10:25:17,374 ERROR [nova.api.openstack.extensions] Unexpected exception in API method<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> Traceback (most recent call last):<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/api/openstack/extensions.py", line 478, in wrapped<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> return f(*args, **kwargs)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/api/openstack/compute/servers.py", line 882, in _action_revert_resize<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> instance = self._get_server(context, req, id)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/api/openstack/compute/servers.py", line 450, in _get_server<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> expected_attrs=expected_attrs)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/api/openstack/common.py", line 516, in get_instance<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> expected_attrs=expected_attrs)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/compute/api.py", line 2072, in get<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> context, instance_id, expected_attrs=expected_attrs)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "/home/jiapei2/PycharmProjects/nova/.tox/py27/lib/python2.7/site-packages/oslo_versionedobjects/base.py", line 181, in wrapper<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> result = fn(cls, context, *args, **kwargs)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/objects/instance.py", line 399, in get_by_uuid<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> use_slave=use_slave)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/db/sqlalchemy/api.py", line 285, in wrapper<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> return f(*args, **kwargs)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/objects/instance.py", line 391, in _db_instance_get_by_uuid<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> columns_to_join=columns_to_join)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/tests/unit/api/openstack/fakes.py", line 358, in _return_server<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> return stub_instance(1, **kwargs)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/tests/unit/api/openstack/fakes.py", line 484, in stub_instance<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> instance_type = flavors.get_default_flavor()<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/compute/flavors.py", line 206, in get_default_flavor<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> return get_flavor_by_name(name)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/compute/flavors.py", line 217, in get_flavor_by_name<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> return objects.Flavor.get_by_name(ctxt, name)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "/home/jiapei2/PycharmProjects/nova/.tox/py27/lib/python2.7/site-packages/oslo_versionedobjects/base.py", line 181, in wrapper<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> result = fn(cls, context, *args, **kwargs)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/objects/flavor.py", line 139, in get_by_name<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> db_flavor = db.flavor_get_by_name(context, name)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/db/api.py", line 1507, in flavor_get_by_name<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> return IMPL.flavor_get_by_name(context, name)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/db/sqlalchemy/api.py", line 229, in wrapper<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> return f(*args, **kwargs)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "/home/jiapei2/PycharmProjects/nova/.tox/py27/lib/python2.7/site-packages/oslo_db/sqlalchemy/enginefacade.py", line 709, in wrapper<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> return fn(*args, **kwargs)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/db/sqlalchemy/api.py", line 5105, in flavor_get_by_name<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> raise exception.FlavorNotFoundByName(flavor_name=name)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> FlavorNotFoundByName: Flavor with name m1.small could not be found.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">Captured traceback:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">~~~~~~~~~~~~~~~~~~~<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> Traceback (most recent call last):<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/tests/unit/api/openstack/compute/test_server_actions.py", line 890, in test_revert_resize_server<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> body=body)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> File "nova/api/openstack/extensions.py", line 504, in wrapped<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> raise webob.exc.HTTPInternalServerError(explanation=msg)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> webob.exc.HTTPInternalServerError: Unexpected API Error. Please report this at http://bugs.launchpad.net/nova/ and attach the Nova API log if possible.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0"> <class 'nova.exception.FlavorNotFoundByName'><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#0070C0">~~~~~~~~~~~~~~~~~~~~<o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Is there anyting wrong with my configurations or procedures? I didn’t change any code and just run “tox”.<o:p></o:p></p>
<p class="MsoNormal">Any advice will be much appreciated.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thanks and regards,<o:p></o:p></p>
<p class="MsoNormal">Jeremy<o:p></o:p></p>
</div>
</body>
</html>