From: Tamir Duberstein <tamird@kernel.org>
To: "Kernel.org Tools" <tools@kernel.org>
Cc: Konstantin Ryabitsev <konstantin@linuxfoundation.org>,
Tamir Duberstein <tamird@kernel.org>
Subject: [PATCH b4 00/12] Enable stricter local checks
Date: Tue, 07 Apr 2026 12:48:29 -0400 [thread overview]
Message-ID: <20260407-ruff-check-v1-0-c9568541ff67@kernel.org> (raw)
This series makes b4 local developer checks enforceable from the
review TUI and makes the repo clean under ruff, mypy, pyright, and ty.
The early patches set ruff formatting and import behavior, make the
test environment reproducible under uv, and type the misc helpers enough
for whole-repo mypy. The middle patches tighten mypy and pyright, then
add ty with all rules enabled and bump the Python requirement to 3.11
because the code already uses 3.11-only syntax.
The last patch wires the review TUI to run the same local checks through
a JSON-emitting series check helper, so reviewers can see ruff, mypy,
pyright, ty, and pytest results from b4 itself.
Signed-off-by: Tamir Duberstein <tamird@kernel.org>
---
Tamir Duberstein (12):
Configure ruff format with single quotes
Fix ruff check warnings
Use ruff to sort imports
Import dependencies unconditionally
Fix tests under uv with complex git config
Fix typings in misc/
Enable mypy unreachable warnings
Enable and fix pyright diagnostics
Avoid duplicate map lookups
Add ty and configuration
Enable pyright strict mode
Add local CI review check
.b4-config | 1 +
misc/b4-ci.py | 57 ++++++++
misc/retrieve_lore_thread.py | 15 +-
misc/review-ci-example.py | 6 +-
misc/send-receive.py | 246 ++++++++++++++++++++-----------
pyproject.toml | 42 +++++-
src/b4/__init__.py | 293 +++++++++++++++++++------------------
src/b4/bugs/__init__.py | 8 +-
src/b4/bugs/_import.py | 3 +-
src/b4/bugs/_tui.py | 9 +-
src/b4/command.py | 17 ++-
src/b4/diff.py | 16 +-
src/b4/dig.py | 17 +--
src/b4/ez.py | 110 ++++++--------
src/b4/kr.py | 2 +-
src/b4/mbox.py | 35 ++---
src/b4/pr.py | 30 ++--
src/b4/review/__init__.py | 29 ++--
src/b4/review/_review.py | 15 +-
src/b4/review/checks.py | 17 ++-
src/b4/review/messages.py | 1 -
src/b4/review/tracking.py | 24 +--
src/b4/review_tui/__init__.py | 20 ++-
src/b4/review_tui/_common.py | 157 ++++++++++++++++----
src/b4/review_tui/_entry.py | 3 +-
src/b4/review_tui/_lite_app.py | 19 +--
src/b4/review_tui/_modals.py | 61 ++++----
src/b4/review_tui/_pw_app.py | 31 ++--
src/b4/review_tui/_review_app.py | 90 +++++++-----
src/b4/review_tui/_tracking_app.py | 83 ++++++-----
src/b4/tui/_common.py | 24 +--
src/b4/tui/_modals.py | 11 +-
src/b4/ty.py | 46 +++---
src/tests/conftest.py | 47 ++++--
src/tests/test___init__.py | 15 +-
src/tests/test_ez.py | 11 +-
src/tests/test_mbox.py | 11 +-
src/tests/test_patatt.py | 3 +-
src/tests/test_rethread.py | 4 +-
src/tests/test_review.py | 4 +-
src/tests/test_review_checks.py | 1 -
src/tests/test_review_show_info.py | 5 +-
src/tests/test_review_tracking.py | 9 +-
src/tests/test_three_way_merge.py | 7 +-
src/tests/test_tui_bugs.py | 1 -
src/tests/test_tui_modals.py | 18 ++-
src/tests/test_tui_review.py | 6 +-
src/tests/test_tui_tracking.py | 28 ++--
48 files changed, 1036 insertions(+), 672 deletions(-)
---
base-commit: 05a91672afb00b3b3b5f76c7757a518d80509c59
change-id: 20260403-ruff-check-79f9f5441956
Best regards,
--
Tamir Duberstein <tamird@kernel.org>
next reply other threads:[~2026-04-07 16:48 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-07 16:48 Tamir Duberstein [this message]
2026-04-07 16:48 ` [PATCH b4 01/12] Configure ruff format with single quotes Tamir Duberstein
2026-04-07 16:48 ` [PATCH b4 02/12] Fix ruff check warnings Tamir Duberstein
2026-04-07 16:48 ` [PATCH b4 03/12] Use ruff to sort imports Tamir Duberstein
2026-04-07 16:48 ` [PATCH b4 04/12] Import dependencies unconditionally Tamir Duberstein
2026-04-07 16:48 ` [PATCH b4 05/12] Fix tests under uv with complex git config Tamir Duberstein
2026-04-07 16:48 ` [PATCH b4 06/12] Fix typings in misc/ Tamir Duberstein
2026-04-07 16:48 ` [PATCH b4 07/12] Enable mypy unreachable warnings Tamir Duberstein
2026-04-07 16:48 ` [PATCH b4 08/12] Enable and fix pyright diagnostics Tamir Duberstein
2026-04-07 16:48 ` [PATCH b4 09/12] Avoid duplicate map lookups Tamir Duberstein
2026-04-07 16:48 ` [PATCH b4 10/12] Add ty and configuration Tamir Duberstein
2026-04-07 16:48 ` [PATCH b4 11/12] Enable pyright strict mode Tamir Duberstein
2026-04-07 16:48 ` [PATCH b4 12/12] Add local CI review check Tamir Duberstein
2026-04-10 15:05 ` [PATCH b4 00/12] Enable stricter local checks Tamir Duberstein
2026-04-10 15:21 ` Konstantin Ryabitsev
2026-04-10 22:39 ` Tamir Duberstein
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260407-ruff-check-v1-0-c9568541ff67@kernel.org \
--to=tamird@kernel.org \
--cc=konstantin@linuxfoundation.org \
--cc=tools@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox