pythonisort

disable isort check for 2 empty lines before <anything>


How can I disable isort check for 2 empty lines before <anything>

import sys

class Person:
    def __init__(self):
        self.name = "moish"

I tried with telling isort to ignore whitespace but that didn't help:

$ isort -ws main.py
Fixing /home/oren/main.py <----- arrrggghhh leave spacing to me

Solution

  • Use the --lines-after-imports argument