yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #72283
[Bug 1726213] Re: KNOWN_EXCEPTIONS don't include all possible exceptions
** Also affects: glance/queens
Importance: Undecided
Status: New
** Changed in: glance/queens
Milestone: None => queens-stable-2
** Changed in: glance/queens
Importance: Undecided => High
** Changed in: glance/queens
Status: New => Triaged
** Changed in: glance/queens
Assignee: (unassigned) => Brian Rosmaita (brian-rosmaita)
** Tags removed: queens-backport-potential
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1726213
Title:
KNOWN_EXCEPTIONS don't include all possible exceptions
Status in Glance:
In Progress
Status in Glance queens series:
Triaged
Bug description:
oslo.config may raise a ConfigFileValueError when run
server.start(***) in `glance/cmd/api.py`, which is a subclass of
ValueError so it can be caught using KNOWN_EXCEPTIONS.
But ConfigFileValueError is not in the KNOWN_EXCEPTIONS, use index
method of KNOWN_EXCEPTIONS will raise an ValueError, which is
unexpected:
```
2017-10-22 22:47:46.460 94 CRITICAL glance [-] Unhandled error: ValueError: tuple.index(x): x not in tuple
2017-10-22 22:47:46.460 94 ERROR glance Traceback (most recent call last):
2017-10-22 22:47:46.460 94 ERROR glance File "/var/lib/kolla/venv/bin/glance-api", line 10, in <module>
2017-10-22 22:47:46.460 94 ERROR glance sys.exit(main())
2017-10-22 22:47:46.460 94 ERROR glance File "/var/lib/kolla/venv/lib/python2.7/site-packages/glance/cmd/api.py", line 92, in main
2017-10-22 22:47:46.460 94 ERROR glance fail(e)
2017-10-22 22:47:46.460 94 ERROR glance File "/var/lib/kolla/venv/lib/python2.7/site-packages/glance/cmd/api.py", line 65, in fail
2017-10-22 22:47:46.460 94 ERROR glance return_code = KNOWN_EXCEPTIONS.index(type(e)) + 1
2017-10-22 22:47:46.460 94 ERROR glance ValueError: tuple.index(x): x not in tuple
2017-10-22 22:47:46.460 94 ERROR glance
```
To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1726213/+subscriptions
References