Skip to content

chore(deps): combine and fix up dependabot bumps (black 26, mypy 2, pytest 9.1)#271

Merged
leongdl merged 1 commit into
OpenJobDescription:mainlinefrom
leongdl:dependabot
Jul 2, 2026
Merged

chore(deps): combine and fix up dependabot bumps (black 26, mypy 2, pytest 9.1)#271
leongdl merged 1 commit into
OpenJobDescription:mainlinefrom
leongdl:dependabot

Conversation

@leongdl

@leongdl leongdl commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

Combining and fixing up the three failing dependabot PRs (#267, #269, #270) so they can be closed.

Changes (requirements-testing.txt)

Why the individual PRs were failing

1. black 26 / mypy 2 drop Python 3.9. Both now require >=3.10, but this package supports >=3.9 and tests it in CI. Fixed with environment markers (matching the pytest marker pattern already in the file) so the 3.9 job keeps the last compatible release and 3.10+ gets the new major:

pytest == 9.1.*; python_version >= '3.10'
pytest == 8.4.*; python_version < '3.10'
black == 26.*; python_version >= '3.10'
black == 25.*; python_version < '3.10'
mypy == 2.1.*; python_version >= '3.10'
mypy == 1.19.*; python_version < '3.10'

Also applied black 26's docstring blank-line reformatting; verified black 25 agrees with the reformatted tree so the 3.9 black --check job stays green.

2. pytest 9.1 broke 7 tests in test_entrypoint.py. pytest 9.1 reworked log capture for non-propagating loggers (changelog #3697). The autouse mock_getLogger fixture patched the global logging.getLogger, which pytest 9.1's caplog now relies on to install its capture handler — so caplog.text came back empty. Fixed by patching EntryPoint._init_loggers instead (the actual thing the fixture was trying to stub out), which works on both pytest 8.4 (the 3.9 job) and 9.1 (3.10+).

Verification

  • ruff check / black --check — pass
  • mypy (2.1.0) — no issues in 146 source files
  • hatch run test — 475 passed, 26 skipped
  • Verified the 7 previously-failing tests pass under both pytest 8.4 and 9.1 (with xdist, matching CI)

Closes #267, closes #269, closes #270.

…ytest 9.1)

Combines dependabot PRs OpenJobDescription#267, OpenJobDescription#269, OpenJobDescription#270:
- black 25.* -> 26.* (OpenJobDescription#267)
- mypy 1.19.* -> 2.1.* (OpenJobDescription#269)
- pytest 9.0.* -> 9.1.* (OpenJobDescription#270)

black 26 and mypy 2 dropped Python 3.9 (require >=3.10). Pinned via
environment markers so the 3.9 CI job keeps the last 3.9-compatible
versions while 3.10+ gets the upgraded majors (matching the existing
pytest marker pattern). Applied black 26 reformatting.

pytest 9.1 reworked log capture for non-propagating loggers (pytest
changelog #3697). The mock_getLogger fixture patched the global
logging.getLogger, which broke caplog's handler installation on 9.1 and
caused 7 test_entrypoint.py failures. Fixed by patching
EntryPoint._init_loggers instead, which works on both pytest 8.4 (py3.9)
and 9.1 (py3.10+).

Verified: ruff, black, mypy 2.1.0, and 475 unit tests pass.
Signed-off-by: David Leong <116610336+leongdl@users.noreply.github.com>
@leongdl
leongdl requested a review from a team as a code owner July 2, 2026 02:34

@seant-aws seant-aws left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😎

@leongdl
leongdl enabled auto-merge (rebase) July 2, 2026 16:43
@leongdl
leongdl merged commit 7bff609 into OpenJobDescription:mainline Jul 2, 2026
25 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants