From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2126) id 175153858C74; Tue, 2 Apr 2024 17:21:53 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 175153858C74 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1712078514; bh=yMfWUEJ8fakIJN5k+qelX28zSLUnDj7lwLj4ZOLfdc0=; h=From:To:Subject:Date:From; b=MJ6oGHUTkTNd30KL9/QP9pH/sd0ngSV6WE4nyoiwSfw9na1U1hY0CMiQykhp5avbq Xf/rojrkzFr2Fk2lzLd1gTDiNcSh2a3vz/2Ems+1/fP0uYtILPO4jhCQ6RfZWfebzF ILL79PlSrKuUCRaq+1FlzcmDkFfeTd1GqrFlak/U= Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Tom Tromey To: gdb-cvs@sourceware.org Subject: [binutils-gdb] Prepare gdb for isort X-Act-Checkin: binutils-gdb X-Git-Author: Tom Tromey X-Git-Refname: refs/heads/master X-Git-Oldrev: e2238b2e2061cffd2b7ae2894747205a56d2f775 X-Git-Newrev: 68982f618b28aebf47343922fb79e59ace0246eb Message-Id: <20240402172154.175153858C74@sourceware.org> Date: Tue, 2 Apr 2024 17:21:53 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=3Dbinutils-gdb.git;h=3D68982f618b28= aebf47343922fb79e59ace0246eb commit 68982f618b28aebf47343922fb79e59ace0246eb Author: Tom Tromey Date: Wed Mar 20 09:36:40 2024 -0600 Prepare gdb for isort =20 This patch prepares gdb for isort: it adds a couple of isort marker comments where needed, and it adds an isort clause to setup.cfg. =20 Approved-By: Simon Marchi Diff: --- gdb/python/lib/gdb/__init__.py | 2 ++ gdb/python/lib/gdb/dap/__init__.py | 3 +++ gdb/setup.cfg | 3 +++ 3 files changed, 8 insertions(+) diff --git a/gdb/python/lib/gdb/__init__.py b/gdb/python/lib/gdb/__init__.py index aae0d3680aa..9db91d8261b 100644 --- a/gdb/python/lib/gdb/__init__.py +++ b/gdb/python/lib/gdb/__init__.py @@ -31,6 +31,8 @@ import _gdb # Note that two indicators are needed here to silence flake8. from _gdb import * # noqa: F401,F403 =20 +# isort: split + # Historically, gdb.events was always available, so ensure it's # still available without an explicit import. import _gdbevents as events diff --git a/gdb/python/lib/gdb/dap/__init__.py b/gdb/python/lib/gdb/dap/__= init__.py index 784015d1a07..51b95468a70 100644 --- a/gdb/python/lib/gdb/dap/__init__.py +++ b/gdb/python/lib/gdb/dap/__init__.py @@ -18,6 +18,8 @@ import os # This must come before other DAP imports. from . import startup =20 +# isort: split + # Load modules that define commands. These imports intentionally # ignore the unused import warning, as these modules are being loaded # for their side effects -- namely, registering DAP commands with the @@ -36,6 +38,7 @@ from . import scopes # noqa: F401 from . import sources # noqa: F401 from . import threads # noqa: F401 =20 +# isort: split from .server import Server =20 =20 diff --git a/gdb/setup.cfg b/gdb/setup.cfg index 2e83eb5cf56..d33058ea7f0 100644 --- a/gdb/setup.cfg +++ b/gdb/setup.cfg @@ -7,3 +7,6 @@ # E701: Multiple statements on one line (colon) # W503: line break before binary operator ignore =3D E203,E501,E701,W503 + +[isort] +profile =3D black