yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #79699
[Bug 1840978] [NEW] nova-manage commands with unexpected errors returning 1 conflict with expected cases of 1 for flow control
Public bug reported:
The archive_deleted_rows command returns 1 meaning some records were
archived and the code documents that if automating and not using
--until-complete, you should keep going while you get rc=1 until you get
rc=0:
https://github.com/openstack/nova/blob/0bf81cfe73340ba5cfd9cf44a38905014ba780f0/nova/cmd/manage.py#L505
The problem is if some unexpected error happens, let's say there is a
TypeError in the code or something, the command will also return 1:
https://github.com/openstack/nova/blob/0bf81cfe73340ba5cfd9cf44a38905014ba780f0/nova/cmd/manage.py#L2625
That unexpected error should probably be a 255 which generally means a
command failed in some unexpected way. There might be other nova-manage
commands that return 1 for flow control as well.
Note that changing the "unexpected error" code from 1 to 255 is an
upgrade impacting change worth a release note.
** Affects: nova
Importance: Low
Status: Triaged
** Tags: nova-manage
** Tags added: nova-manage
** Changed in: nova
Importance: Undecided => Low
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1840978
Title:
nova-manage commands with unexpected errors returning 1 conflict with
expected cases of 1 for flow control
Status in OpenStack Compute (nova):
Triaged
Bug description:
The archive_deleted_rows command returns 1 meaning some records were
archived and the code documents that if automating and not using
--until-complete, you should keep going while you get rc=1 until you
get rc=0:
https://github.com/openstack/nova/blob/0bf81cfe73340ba5cfd9cf44a38905014ba780f0/nova/cmd/manage.py#L505
The problem is if some unexpected error happens, let's say there is a
TypeError in the code or something, the command will also return 1:
https://github.com/openstack/nova/blob/0bf81cfe73340ba5cfd9cf44a38905014ba780f0/nova/cmd/manage.py#L2625
That unexpected error should probably be a 255 which generally means a
command failed in some unexpected way. There might be other nova-
manage commands that return 1 for flow control as well.
Note that changing the "unexpected error" code from 1 to 255 is an
upgrade impacting change worth a release note.
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1840978/+subscriptions
Follow ups