Merge pull request #48032 from rhcs-dashboard/openapi-check-fix

mgr/dashboard: fix openapi-check

Reviewed-by: Ernesto Puerta <epuertat@redhat.com>
Reviewed-by: Laura Flores <lflores@redhat.com>
Reviewed-by: Nizamudeen A <nia@redhat.com>
This commit is contained in:
Nizamudeen A 2022-09-10 12:49:28 +05:30 committed by GitHub
commit c49b81c7d6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 8 deletions

View File

@ -33,7 +33,7 @@ class Docs(BaseController):
list_of_ctrl.add(endpoint.ctrl) list_of_ctrl.add(endpoint.ctrl)
tag_map: Dict[str, str] = {} tag_map: Dict[str, str] = {}
for ctrl in list_of_ctrl: for ctrl in sorted(list_of_ctrl, key=lambda ctrl: ctrl.__name__):
tag_name = ctrl.__name__ tag_name = ctrl.__name__
tag_descr = "" tag_descr = ""
if hasattr(ctrl, 'doc_info'): if hasattr(ctrl, 'doc_info'):

View File

@ -30,6 +30,7 @@ deps =
-rrequirements-lint.txt -rrequirements-lint.txt
[testenv] [testenv]
basepython=python3
deps = deps =
{[base]deps} {[base]deps}
{[base-test]deps} {[base-test]deps}
@ -47,7 +48,6 @@ commands =
pytest {posargs} pytest {posargs}
[testenv:run] [testenv:run]
basepython=python3
deps = deps =
{[base]deps} {[base]deps}
{[base-test]deps} {[base-test]deps}
@ -99,7 +99,6 @@ commands =
rstcheck --report info --debug -- {[rstlint]dirs} rstcheck --report info --debug -- {[rstlint]dirs}
[testenv:lint] [testenv:lint]
basepython=python3
deps = deps =
{[base]deps} {[base]deps}
{[base-lint]deps} {[base-lint]deps}
@ -112,13 +111,11 @@ commands =
{[base-rst]commands} {[base-rst]commands}
[testenv:flake8] [testenv:flake8]
basepython = python3
deps = {[base-lint]deps} deps = {[base-lint]deps}
commands = commands =
flake8 --config=tox.ini {posargs} flake8 --config=tox.ini {posargs}
[testenv:pylint] [testenv:pylint]
basepython = python3
deps = deps =
{[base]deps} {[base]deps}
{[base-lint]deps} {[base-lint]deps}
@ -126,7 +123,6 @@ commands =
pylint {[pylint]addopts} {posargs:{[pylint]dirs}} pylint {[pylint]addopts} {posargs:{[pylint]dirs}}
[testenv:rst] [testenv:rst]
basepython = python3
deps = {[base-lint]deps} deps = {[base-lint]deps}
commands = commands =
rstcheck --report info --debug -- {posargs:{[rstlint]dirs}} rstcheck --report info --debug -- {posargs:{[rstlint]dirs}}
@ -142,7 +138,6 @@ addopts =
# --aggressive # --aggressive
[testenv:fix] [testenv:fix]
basepython=python3
deps = deps =
{[base-lint]deps} {[base-lint]deps}
commands = commands =
@ -156,7 +151,6 @@ commands =
python ci/check_grafana_dashboards.py frontend/src/app ../../../../monitoring/ceph-mixin/dashboards_out python ci/check_grafana_dashboards.py frontend/src/app ../../../../monitoring/ceph-mixin/dashboards_out
[testenv:openapi-{check,fix}] [testenv:openapi-{check,fix}]
basepython = python3
allowlist_externals = diff allowlist_externals = diff
description = description =
check: Ensure that auto-generated OpenAPI Specification matches the current version check: Ensure that auto-generated OpenAPI Specification matches the current version