-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #917 from sirosen/convert-to-pyproject
Convert configuration to pyproject.toml, still using setuptools
- Loading branch information
Showing
4 changed files
with
129 additions
and
142 deletions.
There are no files selected for viewing
This file contains 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,4 @@ | ||
[flake8] | ||
exclude = .git,.tox,__pycache__,.eggs,dist,.venv*,docs,build | ||
max-line-length = 88 | ||
extend-ignore = W503,W504,E203 |
This file contains 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,124 @@ | ||
[build-system] | ||
requires = ["setuptools>=61.2"] | ||
build-backend = "setuptools.build_meta" | ||
|
||
[project] | ||
name = "globus-sdk" | ||
authors = [ | ||
{ name = "Globus Team", email = "[email protected]" }, | ||
] | ||
description = "Globus SDK for Python" | ||
keywords = ["globus"] | ||
classifiers = [ | ||
"Development Status :: 5 - Production/Stable", | ||
"Intended Audience :: Developers", | ||
"License :: OSI Approved :: Apache Software License", | ||
"Programming Language :: Python", | ||
"Programming Language :: Python :: 3.7", | ||
"Programming Language :: Python :: 3.8", | ||
"Programming Language :: Python :: 3.9", | ||
"Programming Language :: Python :: 3.10", | ||
"Programming Language :: Python :: 3.11", | ||
"Programming Language :: Python :: 3.12", | ||
] | ||
requires-python = ">=3.7" | ||
dependencies = [ | ||
"requests>=2.19.1,<3.0.0", | ||
"pyjwt[crypto]>=2.0.0,<3.0.0", | ||
# cryptography 3.4.0 is known-bugged, see: | ||
# https://github.com/pyca/cryptography/issues/5756 | ||
# pyjwt requires cryptography>=3.3.1, | ||
# so there's no point in setting a lower bound than that | ||
"cryptography>=3.3.1,!=3.4.0", | ||
# depend on the latest version of typing-extensions on python versions which do | ||
# not have all of the typing features we use | ||
'typing_extensions>=4.0; python_version<"3.10"', | ||
] | ||
dynamic = ["version"] | ||
|
||
[project.readme] | ||
file = "README.rst" | ||
content-type = "text/x-rst" | ||
|
||
[project.license] | ||
text = "Apache-2.0" | ||
|
||
[project.urls] | ||
Homepage = "https://github.com/globus/globus-sdk-python" | ||
|
||
[tool.setuptools.packages.find] | ||
where = ["src"] | ||
namespaces = false | ||
|
||
[tool.setuptools.package-data] | ||
globus_sdk = ["py.typed"] | ||
|
||
[tool.setuptools.dynamic.version] | ||
attr = "globus_sdk.__version__" | ||
|
||
# non-packaging tool configs follow | ||
|
||
[tool.pytest.ini_options] | ||
addopts = "--no-success-flaky-report" | ||
testpaths = ["tests"] | ||
norecursedirs = ["tests/non-pytest"] | ||
filterwarnings = [ | ||
"error", | ||
] | ||
|
||
[tool.scriv] | ||
version = "literal: src/globus_sdk/version.py: __version__" | ||
format = "rst" | ||
output_file = "changelog.rst" | ||
entry_title_template = 'v{{ version }} ({{ date.strftime(\"%Y-%m-%d\") }})' | ||
rst_header_chars = "-~" | ||
categories = [ | ||
"Python Support", | ||
"Added", | ||
"Removed", | ||
"Changed", | ||
"Deprecated", | ||
"Fixed", | ||
"Documentation", | ||
"Security", | ||
"Development", | ||
] | ||
|
||
[tool.isort] | ||
profile = "black" | ||
known_first_party = ["tests", "globus_sdk"] | ||
|
||
[tool.mypy] | ||
strict = true | ||
warn_unreachable = true | ||
warn_no_return = true | ||
|
||
[tool.pylint] | ||
load-plugins = ["pylint.extensions.docparams"] | ||
accept-no-param-doc = "false" | ||
|
||
[tool.pylint."messages control"] | ||
disable = [ | ||
# formatting and cosmetic rules (handled by 'black', etc) | ||
"format", "C", | ||
# refactoring rules (e.g. duplicate or similar code) are very prone to | ||
# false positives | ||
"R", | ||
# emitted when pylint fails to import a module; these warnings | ||
# are usually false-positives for optional dependencies | ||
"import-error", | ||
# "disallowed" usage of our own classes and objects gets underfoot | ||
"protected-access", | ||
# objections to log messages doing eager (vs lazy) string formatting | ||
# the perf benefit of deferred logging doesn't always outweigh the readability cost | ||
"logging-fstring-interpolation", "logging-format-interpolation", | ||
# fixme comments are often useful; re-enable this to quickly find FIXME and | ||
# TODO comments | ||
"fixme", | ||
# most SDK methods currently do not document the exceptions which they raise | ||
# this is an area for potential improvement | ||
"missing-raises-doc", | ||
] | ||
|
||
[tool.pylint.variables] | ||
ignored-argument-names = "args|kwargs" |
This file contains 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