Re: [PATCH v3 12/47] qapi: enforce import order/styling with isort

2020-09-28 Thread Cleber Rosa
On Thu, Sep 24, 2020 at 08:28:25PM -0400, John Snow wrote: > While we're mucking around with imports, we might as well formalize the > style we use. Let's use isort to do it for us. > > force_sort_within_sections: Intermingles "from x" and "import x" style > statements, such that sorting is always

Re: [PATCH v3 12/47] qapi: enforce import order/styling with isort

2020-09-28 Thread Cleber Rosa
On Mon, Sep 28, 2020 at 10:34:42AM -0400, John Snow wrote: > On 9/28/20 8:13 AM, Markus Armbruster wrote: > > PEP 8: "Surround top-level function and class definitions with two blank > > lines." > > > > [...] > > > > > > Yep, but flake8 does not complain about the first definitions that occur >

Re: [PATCH v3 12/47] qapi: enforce import order/styling with isort

2020-09-28 Thread John Snow
On 9/28/20 8:13 AM, Markus Armbruster wrote: PEP 8: "Surround top-level function and class definitions with two blank lines." [...] Yep, but flake8 does not complain about the first definitions that occur below imports. Why not? I don't know. Regardless, I can change it and fold the chang

Re: [PATCH v3 12/47] qapi: enforce import order/styling with isort

2020-09-28 Thread Markus Armbruster
John Snow writes: > On 9/25/20 5:20 AM, Markus Armbruster wrote: >> John Snow writes: >> >>> While we're mucking around with imports, we might as well formalize the >>> style we use. Let's use isort to do it for us. >>> >>> force_sort_within_sections: Intermingles "from x" and "import x" style

Re: [PATCH v3 12/47] qapi: enforce import order/styling with isort

2020-09-25 Thread John Snow
On 9/25/20 5:20 AM, Markus Armbruster wrote: John Snow writes: While we're mucking around with imports, we might as well formalize the style we use. Let's use isort to do it for us. force_sort_within_sections: Intermingles "from x" and "import x" style statements, such that sorting is always

Re: [PATCH v3 12/47] qapi: enforce import order/styling with isort

2020-09-25 Thread Markus Armbruster
John Snow writes: > While we're mucking around with imports, we might as well formalize the > style we use. Let's use isort to do it for us. > > force_sort_within_sections: Intermingles "from x" and "import x" style > statements, such that sorting is always performed strictly on the module > name

[PATCH v3 12/47] qapi: enforce import order/styling with isort

2020-09-24 Thread John Snow
While we're mucking around with imports, we might as well formalize the style we use. Let's use isort to do it for us. force_sort_within_sections: Intermingles "from x" and "import x" style statements, such that sorting is always performed strictly on the module name itself. force_grid_wrap=4: Fo