Skip to content

OP-3468: Python 3.10 - 3.14 support#10

Merged
jpogozelski-xoi merged 7 commits into
developfrom
chore/OP-3468/upgrade-python3.10-3.14
Mar 26, 2026
Merged

OP-3468: Python 3.10 - 3.14 support#10
jpogozelski-xoi merged 7 commits into
developfrom
chore/OP-3468/upgrade-python3.10-3.14

Conversation

@jpogozelski-xoi

Copy link
Copy Markdown
Contributor

No description provided.

jpogozelski-xoi and others added 4 commits March 24, 2026 16:52
- unit-test.yml: replace pipenv with astral-sh/setup-uv, expand matrix
  to 3.10-3.14, add unit-tests-complete fan-in job
- publish.yml: replace setup.py build + gh-action-pypi-publish with
  uv build + uv publish

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Add readme, license, Python version classifiers, and project URL.
Drop ignore_missing_imports from mypy config — stdlib-only package
has no untyped dependencies.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings March 25, 2026 14:00

Copilot AI 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.

Pull request overview

This PR modernizes the project for Python 3.10–3.14 by migrating packaging/tooling to pyproject.toml + uv, updating CI and pre-commit to use uv, and making small typing/import adjustments for newer Python versions.

Changes:

  • Replace legacy setup.py/Pipenv workflow with pyproject.toml (Hatchling) + uv.lock dependency locking.
  • Update GitHub Actions and pre-commit hooks to run mypy/pytest/pylint via uv across a Python 3.10–3.14 matrix.
  • Update internal imports/type hints (collections.abc imports, PEP 604 unions) and expose a defined public API via __all__.

Reviewed changes

Copilot reviewed 14 out of 17 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
uv.lock Adds uv lockfile with Python 3.10–3.14 resolution markers.
pyproject.toml Introduces PEP 621 project metadata, dev dependency groups, and Hatchling build backend.
setup.py Removes setuptools-based build config in favor of pyproject.toml.
Pipfile / Pipfile.lock Removes Pipenv dependency management.
env_runner.py Removes Pipenv-specific runner script.
mise.toml Adds mise tool config pinning uv.
.python-version Adds a pinned default local Python version (3.10.20).
.pre-commit-config.yaml Switches Black repo, updates yamllint, and runs pylint/mypy via uv.
.github/workflows/unit-test.yml Converts CI to a Python 3.10–3.14 matrix using uv.
.github/workflows/publish.yml Switches release build/publish steps to uv build / uv publish.
purify/purify.py Updates typing imports and annotations for 3.10+.
tests/purify_test.py Uses collections.abc.Sequence for typing in 3.10+.
purify/__init__.py Defines __all__ for explicit public API exports.
purify/__about__.py Changes version source to importlib.metadata.
.gitignore Stops ignoring pyproject.toml and .python-version; fixes .DS_Store entry formatting.
.flake8 Expands ignored rules to accommodate new formatting/ellipsis usage.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread purify/__about__.py

import importlib.metadata

__version__ = importlib.metadata.version("purify")

Copilot AI Mar 25, 2026

Copy link

Choose a reason for hiding this comment

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

importlib.metadata.version("purify") will raise PackageNotFoundError when importing from a source checkout where the distribution metadata isn't installed (e.g., running tests with PYTHONPATH=. or python -c 'import purify' before installing). Consider wrapping this in a try/except with a safe fallback (e.g., "0+unknown"), or keeping a static __version__ that matches pyproject.toml to avoid import-time failures.

Suggested change
__version__ = importlib.metadata.version("purify")
try:
__version__ = importlib.metadata.version("purify")
except importlib.metadata.PackageNotFoundError:
__version__ = "0+unknown"

Copilot uses AI. Check for mistakes.
Comment thread pyproject.toml
jpogozelski-xoi and others added 3 commits March 25, 2026 10:15
Pin actions/labeler@main -> @v6, update labeler.yml to v5
changed-files format, replace Pipfile* with pyproject.toml/uv.lock.
Bump codeql-action v3 -> v4, release-drafter v5 -> v7.
Add missing document-start markers to yaml files.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
pre-commit-hooks v5+ dropped the flake8 hook. Move flake8 to its own
repo (PyCQA/flake8@7.3.0) and reorder to run after black.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@jpogozelski-xoi jpogozelski-xoi requested a review from a team March 25, 2026 16:01
@jpogozelski-xoi jpogozelski-xoi merged commit 34e4512 into develop Mar 26, 2026
9 of 10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants