Skip to content

Commit 0eb900d

Browse files
authored
Merge pull request #66 from stackhpc/upstream/yoga-2023-11-20
Synchronise yoga with upstream
2 parents 7e51252 + a6aaa11 commit 0eb900d

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

cloudkitty/api/v2/task/reprocess.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -253,10 +253,14 @@ def get(self, scope_ids=[], path_scope_id=None, offset=0, limit=100,
253253
if not isinstance(scope_ids, list):
254254
scope_ids = [scope_ids]
255255

256+
# Some versions of python-cloudkittyclient can send the order in upper
257+
# case, e.g. "DESC". Convert it to lower case for compatibility.
258+
order = order.lower()
259+
256260
if order not in ACCEPTED_GET_REPROCESSING_REQUEST_ORDERS:
257261
raise http_exceptions.BadRequest(
258-
"The order [%s] is not valid. Accepted values are %s.",
259-
order, ACCEPTED_GET_REPROCESSING_REQUEST_ORDERS)
262+
"The order [%s] is not valid. Accepted values are %s." %
263+
(order, ACCEPTED_GET_REPROCESSING_REQUEST_ORDERS))
260264

261265
schedules = self.schedule_reprocessing_db.get_all(
262266
identifier=scope_ids, remove_finished=False,
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
fixes:
3+
- |
4+
Fix retrieval of reprocessing tasks which was returning ``Internal Server
5+
Error``.

0 commit comments

Comments
 (0)