Skip to content

test(util): raise the util scripts' syntax floor to 3.8 (#1103) - #2197

Merged
JarryShaw merged 1 commit into
mainfrom
test/1103-util-syntax-floor-38
Oct 25, 2026
Merged

JarryShaw merged 1 commit into
mainfrom
test/1103-util-syntax-floor-38

Conversation

@JarryShaw

Copy link
Copy Markdown
Owner

What is the purpose of your pull request?

  • test — tests only

Description

Part of #1103, ruling 2: the util scripts' syntax floor rises from 3.7 to 3.8, matching requires-python.

  • Tests:
    • TestStandardLibraryOnly in test_actions_helper_2047 and the five test_release_*_1967 syntax checks now parse at FLOOR. FLOOR is imported from test_requires_python_floor_2051, the test that pins requires-python, so the version isn't a new literal.
    • Names say 3.8.
    • The self-documenting f-string check is removed: f'{x=}' is valid 3.8 syntax, and it existed only because 3.7 parsing accepted it.
  • Prose: the util/_actions.py and seven util/release_*.py docstrings say 3.8, as does workflows.rst's _actions.py sentence. With docstrings stripped, every util file's AST matches main.
  • Proof: a walrus expression is rejected at feature_version=(3, 7) and accepted at (3, 8). The change loosens a check, so there is no failing-without-it test.
  • Tests run: the floor tests and the tier guard (222), the reset-build test (7), and the 22 tests/project files that read workflows.rst (452) all pass.
  • Overlap: docs(repo): fifth whole-repo pass over the repository files (#1103) #2158 rewrites the same util/_actions.py paragraph. Whichever lands second takes docs(repo): fifth whole-repo pass over the repository files (#1103) #2158's wording with "3.8's syntax".

@JarryShaw JarryShaw added test Pull requests that add or correct tests (test: subject prefix) review: running A cross-review is in flight against the current head - no verdict yet labels Oct 25, 2026
Problem: the util scripts' syntax checks parsed with feature_version=(3, 7)
and the util docstrings promised 3.7 syntax, though requires-python is >=3.8
and no leg has run 3.7 since #2051.

Fix: the six checks parse at FLOOR from test_requires_python_floor_2051, which
pins requires-python's floor; the docstrings and workflows.rst say 3.8. The
self-documenting f-string check in test_actions_helper_2047 is removed:
f'{x=}' is 3.8 syntax.

Test: the changed tests pass; a walrus is rejected at (3, 7), accepted at FLOOR.
@JarryShaw

Copy link
Copy Markdown
Owner Author

Rebased onto main after #2158 merged: 05db861a4 → 9c6b5e322.

CI runs again on the new head. The cross-review in flight also covers this delta.

@JarryShaw
JarryShaw force-pushed the test/1103-util-syntax-floor-38 branch from 05db861 to 9c6b5e3 Compare October 25, 2026 14:21
@JarryShaw JarryShaw moved this to In review in PyPCAPKit Oct 25, 2026
@JarryShaw

Copy link
Copy Markdown
Owner Author

Review: GOOD TO GO at 9c6b5e322 (Sonnet): all 34 util files match main's AST once docstrings are stripped. FLOOR is (3, 8) and is pinned by the requires-python test. Importing it adds no test collections. Removing the f-string check is justified, no util syntax-floor claim for 3.7 remains, and the tests pass (229).

@JarryShaw JarryShaw added review: good-to-go Cross-review at the current head says ready; CI state is separate and removed review: running A cross-review is in flight against the current head - no verdict yet labels Oct 25, 2026
@JarryShaw

Copy link
Copy Markdown
Owner Author

Ready to merge at 9c6b5e322. Part of #1103 (ruling 2).

  • Review: Sonnet GOOD TO GO.
  • CI: all checks complete, Required checks passed SUCCESS, 0 failed.
  • KTLO: 12 legs, no warnings.
  • Ordering: project leg merged into main: 2288 tests, 0 failures.

@JarryShaw
JarryShaw merged commit 876fa18 into main Oct 25, 2026
60 checks passed
@github-project-automation github-project-automation Bot moved this from In review to Done in PyPCAPKit Oct 25, 2026
@JarryShaw
JarryShaw deleted the test/1103-util-syntax-floor-38 branch October 25, 2026 17:48
@JarryShaw JarryShaw removed the review: good-to-go Cross-review at the current head says ready; CI state is separate label Oct 25, 2026
@JarryShaw JarryShaw added this to the PyPCAPKit v1.5 milestone Oct 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test Pull requests that add or correct tests (test: subject prefix)

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant