Skip to content

fix: support Python 3.10#87

Merged
DataDave-Dev merged 1 commit into
DataDave-Dev:mainfrom
vku2018:codex/python-310-support
Jul 3, 2026
Merged

fix: support Python 3.10#87
DataDave-Dev merged 1 commit into
DataDave-Dev:mainfrom
vku2018:codex/python-310-support

Conversation

@vku2018

@vku2018 vku2018 commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Summary

Lowers the Python package minimum from 3.12 to 3.10 and adds the new minimum to CI.

This also fixes the one source syntax issue that Python 3.10 rejects: a nested f-string expression in cli.py that used an escaped quote. The output text is unchanged, but the expression is now built before the outer f-string.

Fixes #7.

Changes

  • Set requires-python = ">=3.10".
  • Add Python 3.10 and 3.11 classifiers.
  • Add 3.10 and 3.11 to the CI matrix while keeping 3.12, 3.13, and 3.14.
  • Document Python 3.10+ for the pip/pipx install path in English and Spanish READMEs.
  • Make _print_claude_summary parse under Python 3.10.

Validation

  • Parsed src, tests, and packaging with ast.parse(..., feature_version=(3, 10)).
  • python -m compileall -q src tests packaging
  • pytest -q tests/test_init.py::test_init_from_claude_md_creates_derived_rules tests/test_init.py::test_rules_from_claude_md_maps_signals_by_language tests/test_init.py::test_init_from_claude_md_composes_with_baseline tests/test_mcp.py::test_propose_rules_from_claude_md
  • becwright check --all (blocking rules passed; existing warning-only comment findings remain warnings)
  • git diff --check

I also ran the full local suite with Python 3.11 on Windows:

pytest -q --cov=src/becwright --cov-report=term-missing --cov-fail-under=80

Result: 275 passed, 13 failed. The failures appear to be existing Windows/POSIX-shell assumptions in tests and check commands, for example PYTHONPATH=..., true, and sleep being interpreted by cmd.exe. Coverage still reached 93.22%.

Summary by CodeRabbit

  • New Features

    • Expanded Python compatibility to include Python 3.10 and 3.11.
    • Updated installation guidance for non-native platforms to use pipx install becwright with Python 3.10 or newer.
  • Bug Fixes

    • Broadened CI test coverage to run against more Python versions, helping catch compatibility issues earlier.
  • Documentation

    • Clarified setup instructions in the README for supported platforms and Python requirements.

@coderabbitai

coderabbitai Bot commented Jul 3, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 2e09b3ee-be65-4cf9-8ae4-a2bfdd9c5e36

📥 Commits

Reviewing files that changed from the base of the PR and between 212d39a and 85371fc.

📒 Files selected for processing (5)
  • .github/workflows/ci.yml
  • README.es.md
  • README.md
  • pyproject.toml
  • src/becwright/cli.py

📝 Walkthrough

Walkthrough

This PR lowers the minimum supported Python version to 3.10 by updating pyproject.toml's requires-python and classifiers, expanding the CI test matrix, updating README installation instructions, and includes a minor unrelated refactor in cli.py's summary printing.

Changes

Python 3.10 Minimum Version Support

Layer / File(s) Summary
Packaging metadata and CI matrix update
pyproject.toml, .github/workflows/ci.yml
requires-python lowered to >=3.10, header comment and Trove classifiers updated to reflect 3.10/3.11 support, and CI test matrix expanded to include Python 3.10 and 3.11.
README installation guidance update
README.md, README.es.md
Instructions for installing via pipx on unsupported platforms now specify Python 3.10 or newer as the requirement.

Unrelated Refactor

Layer / File(s) Summary
Claude summary formatting refactor
src/becwright/cli.py
_print_claude_summary computes the matched-trigger label into a local variable before printing, replacing inline f-string formatting.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Linked Issues check ❓ Inconclusive The PR satisfies the version, CI, docs, and syntax-fix objectives, but full Python 3.10 test-suite success isn't shown. Add evidence of a full test suite run on Python 3.10, or a CI job proving the new minimum passes end to end.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change of lowering Python support to 3.10.
Description check ✅ Passed The description covers the change, rationale, validation, and issue reference, even if the template headings differ.
Out of Scope Changes check ✅ Passed The cli.py refactor is directly tied to the Python 3.10 syntax fix, and no unrelated changes are apparent.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@DataDave-Dev DataDave-Dev marked this pull request as ready for review July 3, 2026 04:19
@DataDave-Dev DataDave-Dev self-requested a review as a code owner July 3, 2026 04:19
@DataDave-Dev DataDave-Dev merged commit e7c3e24 into DataDave-Dev:main Jul 3, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Lower the minimum Python version to 3.10

3 participants