diff options
| author | Carlos Fernandez <carlosfsanz@meta.com> | 2026-03-26 13:46:38 -0700 |
|---|---|---|
| committer | LUCI <gerrit-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2026-04-03 07:50:52 -0700 |
| commit | 573983948ae0550b0f655ea81431bb08ce0bd540 (patch) | |
| tree | 1065ee4ce7373f8bb164b5c66b824e141a74082c /run_tests.vpython3 | |
| parent | 3f3c681a02ed27663e06c35328b494b9245881b5 (diff) | |
| download | git-repo-573983948ae0550b0f655ea81431bb08ce0bd540.tar.gz | |
Fix all flake8 warnings from newer flake8-bugbear and flake8-comprehensions
Address warnings introduced by flake8-bugbear 24.12.12 and
flake8-comprehensions 3.16.0:
- C408: Replace dict()/list() calls with literal {} and []
- C413: Remove unnecessary list() around sorted()
- C414: Remove unnecessary list() inside sorted()
- C419: Suppress intentional list comprehension in all() (noqa)
- B001: Replace bare except with except Exception
- B006: Replace mutable default arguments with None
- B010: Replace setattr() with direct attribute assignment
- B017: Use RuntimeError instead of Exception in tests
- B019: Suppress lru_cache on methods for long-lived objects (noqa)
- B033: Remove duplicate item in set literal
Change-Id: If4693d3e946200bbc22f689f7b94da604addcb80
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/566321
Tested-by: Carlos Fernandez <carlosfsanz@meta.com>
Commit-Queue: Carlos Fernandez <carlosfsanz@meta.com>
Reviewed-by: Mike Frysinger <vapier@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Diffstat (limited to 'run_tests.vpython3')
| -rw-r--r-- | run_tests.vpython3 | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/run_tests.vpython3 b/run_tests.vpython3 index e6dfe7c63..e07d08256 100644 --- a/run_tests.vpython3 +++ b/run_tests.vpython3 | |||
| @@ -48,10 +48,10 @@ wheel: < | |||
| 48 | version: "version:3.0.7" | 48 | version: "version:3.0.7" |
| 49 | > | 49 | > |
| 50 | 50 | ||
| 51 | # Required by pytest==8.3.4 | 51 | # Required by pytest==8.3.4 and flake8-bugbear==24.12.12 |
| 52 | wheel: < | 52 | wheel: < |
| 53 | name: "infra/python/wheels/attrs-py2_py3" | 53 | name: "infra/python/wheels/attrs-py3" |
| 54 | version: "version:21.4.0" | 54 | version: "version:24.2.0" |
| 55 | > | 55 | > |
| 56 | 56 | ||
| 57 | # NB: Keep in sync with constraints.txt. | 57 | # NB: Keep in sync with constraints.txt. |
| @@ -120,6 +120,16 @@ wheel: < | |||
| 120 | > | 120 | > |
| 121 | 121 | ||
| 122 | wheel: < | 122 | wheel: < |
| 123 | name: "infra/python/wheels/flake8-bugbear-py3" | ||
| 124 | version: "version:24.12.12" | ||
| 125 | > | ||
| 126 | |||
| 127 | wheel: < | ||
| 128 | name: "infra/python/wheels/flake8-comprehensions-py3" | ||
| 129 | version: "version:3.16.0" | ||
| 130 | > | ||
| 131 | |||
| 132 | wheel: < | ||
| 123 | name: "infra/python/wheels/isort-py3" | 133 | name: "infra/python/wheels/isort-py3" |
| 124 | version: "version:5.10.1" | 134 | version: "version:5.10.1" |
| 125 | > | 135 | > |
