3

I need to disable a warning of a pycodestyle check within a python code snippet.

How to do that?

Alex
  • 41,580
  • 88
  • 260
  • 469
  • You should show the snippet and say what warning is raised. Maybe the `#noqa` comment over the offending line could help. – Serge Ballesta Mar 12 '21 at 08:27
  • the `# noqa` comment on the offending line does not help. – Alex Mar 12 '21 at 08:59
  • You should add the code and warning. It could help others to propose solutions... – Serge Ballesta Mar 12 '21 at 10:12
  • I did not try to post an answer... What I meant is that I do not know any generic way to silence a pycodestyle warning, but I know that some specific warning can be silenced at the file level. As I did not know whether it was relevant here, I just asked for details. And honestly, as you got no answers in 1 hour and only my comment, I also hoped that those details could help others, that would know pycodstyle better than I do, to post answers. Said differently I was just trying to help you the best I could... – Serge Ballesta Mar 12 '21 at 11:02
  • I did not know that only specific warning can be silenced. Thanks for that information! I want to silence the W503 warning `Line break occurred before a binary operator` – Alex Mar 12 '21 at 11:36

0 Answers0