diff --git a/.mergify.yml b/.mergify.yml index f6e4df9bf..1fbe9c58c 100644 --- a/.mergify.yml +++ b/.mergify.yml @@ -1,18 +1,39 @@ +queue_rules: + - name: default + conditions: + - check-success=doc (docs) + - check-success=doc (docs-gnocchi-web) + - check-success=check (pep8) + - check-success=test (py36, postgresql-file-upgrade-from-4.3) + - check-success=test (py36, mysql-file) + - check-success=test (py36, mysql-swift) + - check-success=test (py36, mysql-s3) + - check-success=test (py36, postgresql-file) + - check-success=test (py36, postgresql-swift) + - check-success=test (py36, postgresql-s3) + - check-success=test (py38, mysql-ceph-upgrade-from-4.3) + - check-success=test (py38, postgresql-file-upgrade-from-4.3) + - check-success=test (py38, mysql-file) + - check-success=test (py38, mysql-swift) + - check-success=test (py38, mysql-s3) + - check-success=test (py38, mysql-ceph) + - check-success=test (py38, postgresql-file) + - check-success=test (py38, postgresql-swift) + - check-success=test (py38, postgresql-s3) + - check-success=test (py38, postgresql-ceph) + pull_request_rules: - name: automatic merge actions: - merge: - method: rebase - rebase_fallback: merge - strict: true + queue: + method: merge + name: default conditions: - label!=work-in-progress - '#approved-reviews-by>=1' - check-success=doc (docs) - check-success=doc (docs-gnocchi-web) - - check-success=check (pep8) - - check-success=test (py36, postgresql-file-upgrade-from-4.3) - check-success=test (py36, mysql-file) - check-success=test (py36, mysql-swift) @@ -20,7 +41,6 @@ pull_request_rules: - check-success=test (py36, postgresql-file) - check-success=test (py36, postgresql-swift) - check-success=test (py36, postgresql-s3) - - check-success=test (py38, mysql-ceph-upgrade-from-4.3) - check-success=test (py38, postgresql-file-upgrade-from-4.3) - check-success=test (py38, mysql-file) @@ -34,10 +54,9 @@ pull_request_rules: - name: automatic merge backports from Mergify actions: - merge: - method: rebase - rebase_fallback: merge - strict: true + queue: + method: merge + name: default conditions: - base~=^stable/.* - label!=work-in-progress diff --git a/gnocchi/rest/api.py b/gnocchi/rest/api.py index e7f851238..396b32101 100644 --- a/gnocchi/rest/api.py +++ b/gnocchi/rest/api.py @@ -1296,7 +1296,7 @@ class QueryStringSearchAttrFilter(object): @classmethod def _parsed_query2dict(cls, parsed_query): result = None - while parsed_query: + while len(parsed_query.asList()): part = parsed_query.pop() if part in cls.binary_operator: result = {part: {parsed_query.pop(): result}} diff --git a/gnocchi/tests/functional/gabbits/aggregates-with-metric-ids.yaml b/gnocchi/tests/functional/gabbits/aggregates-with-metric-ids.yaml index d2cff26a0..ab9f6dfa0 100644 --- a/gnocchi/tests/functional/gabbits/aggregates-with-metric-ids.yaml +++ b/gnocchi/tests/functional/gabbits/aggregates-with-metric-ids.yaml @@ -645,7 +645,7 @@ tests: $.code: 400 $.description.cause: "Invalid operations" $.description.reason: "/^Fail to parse the operations string/" - $.description.detail: '/^Expected "\)", found end of text \(at char 15\), \(line:1, col:16\)/' + $.description.detail: /^Expected \'\)\', found end of text \(at char 15\), \(line:1, col:16\)/ - name: get invalid metric operations POST: /v1/aggregates