When generating tags the order of endpoints wasn't taken into account.
Two endpoints with the same url prefix, for example `/api/cluster/` and
`/api/cluster/user`, have different docs and the tags is generated from
a doc of one of these two, and since the order of these endpoints might
vary it is imperative to sort them to have a deterministic output.
Signed-off-by: Pere Diaz Bou <pdiazbou@redhat.com>
list_of_ctrl.add(endpoint.ctrl)
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_descr = ""
if hasattr(ctrl, 'doc_info'):
-rrequirements-lint.txt
[testenv]
+basepython=python3
deps =
{[base]deps}
{[base-test]deps}
pytest {posargs}
[testenv:run]
-basepython=python3
deps =
{[base]deps}
{[base-test]deps}
rstcheck --report info --debug -- {[rstlint]dirs}
[testenv:lint]
-basepython=python3
deps =
{[base]deps}
{[base-lint]deps}
{[base-rst]commands}
[testenv:flake8]
-basepython = python3
deps = {[base-lint]deps}
commands =
flake8 --config=tox.ini {posargs}
[testenv:pylint]
-basepython = python3
deps =
{[base]deps}
{[base-lint]deps}
pylint {[pylint]addopts} {posargs:{[pylint]dirs}}
[testenv:rst]
-basepython = python3
deps = {[base-lint]deps}
commands =
rstcheck --report info --debug -- {posargs:{[rstlint]dirs}}
# --aggressive
[testenv:fix]
-basepython=python3
deps =
{[base-lint]deps}
commands =
python ci/check_grafana_dashboards.py frontend/src/app ../../../../monitoring/ceph-mixin/dashboards_out
[testenv:openapi-{check,fix}]
-basepython = python3
allowlist_externals = diff
description =
check: Ensure that auto-generated OpenAPI Specification matches the current version