Support adding exceptions through argument | --add-exceptions
See original GitHub issueCompatibility section in docs states:
FlakeHeaven supports all flake8 plugins, formatters, and configs. However, FlakeHeaven has it’s own beautiful way to configure enabled plugins and codes. So, options like --ignore and --select unsupported.
Problem
I use flakeheaven
as a linter in VSCode and some errors overlap with pylance
or mypy
, resulting in repeated errors and requiring more attention than it should. So ignoring overlapping errors makes sense.
However, I still want to see them when I execute flakeheaven
manually, since I’m not using pyright
manually.
Suggestion
It would be great to have option like --add-exceptions
, which then could be used like this:
"python.linting.flake8Path": "${workspaceFolder}/.venv/bin/flake8heavened",
"python.linting.flake8Args": ["--add-exceptions=-F821,-F401"],
What do you think?
I can make a PR implementing it, but want to listen to your opinions/suggestions on that first.
Issue Analytics
- State:
- Created a year ago
- Reactions:1
- Comments:8
Top Results From Across the Web
Adding Exceptions to the Windows Firewall
Double-click Windows Firewall to open the Windows Firewall window. Click the Exceptions tab. Click the Add Port button. Enter a name in the...
Read more >Rule exceptions and value lists | Elastic Security Solution [8.5]
In the Value lists table, click the required action button. Import value list flyout with action buttons highlighted. Add exceptions to a ruleedit....
Read more >How to add an exception to Windows Defender
Thanks for contacting our support. 1. Go to Start > Settings > Update & Security > Windows Security > Virus & threat protection....
Read more >What's new for Java 7 - Eclipse
The new Add exceptions to existing catch clause quick fix allows you to add uncaught exceptions to an existing catch clause. Add exceptions...
Read more >Built-in Exceptions — Python 3.11.1 documentation
In Python, all exceptions must be instances of a class that derives from BaseException ... Also, the filename2 constructor argument and attribute was...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi @Bobronium
did you try something like this:
If so, did you encounter any issues with this approach?
EDIT:
I tried it (
mian
branch) withflakeheaven lint --config .vscode/flakeheaven.toml example.py
andflake8heavened --config .vscode/flakeheaven.toml example.py
. Both workI’ve patched sources myself to fix
--config
argument and can confirm that it works, thank you.Waiting for #80 to be resolved then.
I’ll leave issue opened for a while, since
--add-exceptions
still would be nice to have.