-
Notifications
You must be signed in to change notification settings - Fork 30
Convert python project configuration to pyproject.toml. #115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
roberthdevries
wants to merge
2
commits into
wolfSSL:master
Choose a base branch
from
roberthdevries:add-pyproject-toml
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+143
−27
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,137 @@ | ||
| [project] | ||
| name = "wolfcrypt" | ||
| description = "Python module that encapsulates wolfSSL's crypto engine API." | ||
| readme = "README.rst" | ||
| requires-python = ">=3.10" | ||
| authors = [ | ||
| {name = "wolfSSL Inc.", email="info@wolfssl.com"}, | ||
| ] | ||
| license = "GPL-2.0-only OR LicenseRef-WolfSSL" | ||
| license-files = ["LICENSING.rst"] | ||
| keywords = ["wolfssl", "wolfcrypt", "security", "cryptography"] | ||
| classifiers = [ | ||
| "Operating System :: OS Independent", | ||
| "Programming Language :: Python :: 3", | ||
| "Programming Language :: Python :: 3.10", | ||
| "Programming Language :: Python :: 3.11", | ||
| "Programming Language :: Python :: 3.12", | ||
| "Programming Language :: Python :: 3.13", | ||
| "Programming Language :: Python :: 3.14", | ||
| "Topic :: Security", | ||
| "Topic :: Security :: Cryptography", | ||
| "Topic :: Software Development" | ||
| ] | ||
| dynamic = ["version"] | ||
| dependencies = [ | ||
| "cffi>=1.0.0", | ||
| ] | ||
|
|
||
| [project.urls] | ||
| Homepage = "https://github.com/wolfssl/wolfcrypt-py" | ||
|
|
||
| [build-system] | ||
| requires = ["setuptools"] | ||
| build-backend = "setuptools.build_meta:__legacy__" | ||
|
|
||
| [dependency-groups] | ||
| dev = [ | ||
| "mypy", | ||
| "pytest", | ||
| "ruff", | ||
| "sphinx", | ||
| "sphinx-rtd-theme", | ||
| "tox >= 4", | ||
| "ty", | ||
| "types-cffi", | ||
| ] | ||
|
|
||
| [tool.tox] | ||
| requires = ["tox>=4"] | ||
| env_list = ["py3"] | ||
|
|
||
| [tool.tox.env_run_base] | ||
| package = "wheel" | ||
| deps = ["-rrequirements/test.txt"] | ||
| commands = [["py.test", "tests/"]] | ||
|
|
||
|
|
||
| [tool.ruff] | ||
| # Exclude a variety of commonly ignored directories. | ||
| exclude = [ | ||
| ".bzr", | ||
| ".direnv", | ||
| ".eggs", | ||
| ".git", | ||
| ".git-rewrite", | ||
| ".hg", | ||
| ".idea", | ||
| ".ipynb_checkpoints", | ||
| ".mypy_cache", | ||
| ".nox", | ||
| ".pants.d", | ||
| ".pyenv", | ||
| ".pytest_cache", | ||
| ".pytype", | ||
| ".ruff_cache", | ||
| ".svn", | ||
| ".tox", | ||
| ".venv", | ||
| ".vscode", | ||
| "__pypackages__", | ||
| "_build", | ||
| "buck-out", | ||
| "build", | ||
| "dist", | ||
| "lib", | ||
| "node_modules", | ||
| "site-packages", | ||
| "venv", | ||
| ] | ||
|
|
||
| # The GitHub editor is 127 characters wide. | ||
| line-length = 127 | ||
| indent-width = 4 | ||
|
|
||
| # Assume Python 3.10 | ||
| target-version = "py310" | ||
|
|
||
| [tool.ruff.lint] | ||
| # Enable Pyflakes (`F`) and a subset of the pycodestyle (`E`) codes by default. | ||
| # Unlike Flake8, Ruff doesn't enable pycodestyle warnings (`W`) or | ||
| # McCabe complexity (`C901`) by default. | ||
| select = ["E4", "E7", "E9", "F", "B", "UP"] | ||
| ignore = ["UP031", "UP025", "UP032"] | ||
|
|
||
| # Allow fix for all enabled rules (when `--fix`) is provided. | ||
| fixable = ["ALL"] | ||
| unfixable = [] | ||
|
|
||
| # Allow unused variables when underscore-prefixed. | ||
| dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$" | ||
|
|
||
| [tool.ruff.format] | ||
| # Like Black, use double quotes for strings. | ||
| quote-style = "double" | ||
|
|
||
| # Like Black, indent with spaces, rather than tabs. | ||
| indent-style = "space" | ||
|
|
||
| # Like Black, respect magic trailing commas. | ||
| skip-magic-trailing-comma = false | ||
|
|
||
| # Like Black, automatically detect the appropriate line ending. | ||
| line-ending = "auto" | ||
|
|
||
| # Enable auto-formatting of code examples in docstrings. Markdown, | ||
| # reStructuredText code/literal blocks and doctests are all supported. | ||
| # | ||
| # This is currently disabled by default, but it is planned for this | ||
| # to be opt-out in the future. | ||
| docstring-code-format = false | ||
|
|
||
| # Set the line length limit used when formatting code snippets in | ||
| # docstrings. | ||
| # | ||
| # This only has an effect when the `docstring-code-format` setting is | ||
| # enabled. | ||
| docstring-code-line-length = "dynamic" | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🟠 [Medium]
requires-python = ">=3.10"silently drops Python 3.6–3.9 supportThe previous
setup.pyadvertised support for Python 3.6, 3.7, 3.8, and 3.9 via classifiers (with no explicitpython_requires). The new metadata bumps the floor to Python 3.10, which is a backward-incompatible change for downstream users still on 3.8/3.9 (still in widespread enterprise/distro use as of 2026). The PR description (Modern python projects standardize on pyproject.toml…) only mentions configuration consolidation, not a Python-version bump. If this is intentional it should be called out in the PR description and/or CHANGELOG; if not, restore the lower floor (e.g.>=3.8).Recommendation: Confirm the Python 3.10 floor is intentional and document the deprecation in the changelog; otherwise lower the floor back to the previously-supported version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is intentional as older Python version are end-of-life. Ref: https://devguide.python.org/versions/
A note will be added to the Release Notes.
I tested with Python versions 3.10-3.15 that the software passes the unit tests which means that the statement above is actually true.
There is already one other patches (not merged) that adds something to the ChangeLog. Adding something now will create a merge conflict, as is true for some other patches as well. It would help a lot if these patches were merged on short notice, to help preventing this in the near future.