Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make the find_severity API official #20

Open
smarie opened this issue May 18, 2021 · 0 comments · May be fixed by #21
Open

Make the find_severity API official #20

smarie opened this issue May 18, 2021 · 0 comments · May be fixed by #21

Comments

@smarie
Copy link

smarie commented May 18, 2021

Hi, thanks so much for this nice plugin !

I recently created a commandline tool to generate badges for tests, coverage and flake8: https://smarie.github.io/python-genbadge/

Concerning flake8, it plays very nicely with the html pages generated by your plugin, as you can see by clicking on the badge in the genbadge doc.

In order to aggregate the number of issues by severity (the 3 color codes in the html report), I have to use the flake8-html internal API, more precisely flake8_html.plugin.find_severity: https://github.com/smarie/python-genbadge/blob/main/genbadge/utils_flake8.py#L45

Indeed, flake8 by itself does not provide such severity levels. For the sake of longer-term maintenance, would it be possible to secure this function and expose it at package level (in the __init__.py) so that it can continue to be available even if the internal structure changes ?

(I proposed a PR for this)

Thanks in advance !

smarie added a commit to smarie/flake8-html that referenced this issue May 18, 2021
Fixes lordmauve#20

This is for tools such as [`genbadge`](https://github.com/smarie/python-genbadge) to get the same level of severity as `flake8_html` from the `flake8` codes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant