Asib27's picture
try 1
065fee7 verified
raw
history blame
4.63 kB
[build-system]
requires = ["maturin>=1.2,<2.0"]
build-backend = "maturin"
[project]
name = "rpds-py"
description = "Python bindings to Rust's persistent data structures (rpds)"
requires-python = ">=3.8"
readme = "README.rst"
license = {text = "MIT"}
keywords = ["data structures", "rust", "persistent"]
authors = [
{ name = "Julian Berman", email = "Julian+rpds@GrayVines.com" },
]
classifiers = [
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Rust",
"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",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
]
dynamic = ["version"]
[project.urls]
Documentation = "https://rpds.readthedocs.io/"
Homepage = "https://github.com/crate-py/rpds"
Issues = "https://github.com/crate-py/rpds/issues/"
Funding = "https://github.com/sponsors/Julian"
Tidelift = "https://tidelift.com/subscription/pkg/pypi-rpds-py?utm_source=pypi-rpds-py&utm_medium=referral&utm_campaign=pypi-link"
Source = "https://github.com/crate-py/rpds"
[tool.black]
line-length = 79
[tool.coverage.html]
show_contexts = true
skip_covered = false
[tool.coverage.run]
branch = true
dynamic_context = "test_function"
[tool.coverage.report]
exclude_also = [
"if TYPE_CHECKING:",
"\\s*\\.\\.\\.\\s*",
]
fail_under = 100
show_missing = true
skip_covered = true
[tool.doc8]
ignore = [
"D000", # see PyCQA/doc8#125
"D001", # one sentence per line, so max length doesn't make sense
]
[tool.maturin]
features = ["pyo3/extension-module"]
[tool.pyright]
reportUnnecessaryTypeIgnoreComment = true
strict = ["**/*"]
exclude = [
"**/tests/__init__.py",
"**/tests/test_*.py",
]
[tool.ruff]
line-length = 79
[tool.ruff.lint]
select = ["ALL"]
ignore = [
"A001", # It's fine to shadow builtins
"A002",
"A003",
"ARG", # This is all wrong whenever an interface is involved
"ANN", # Just let the type checker do this
"B006", # Mutable arguments require care but are OK if you don't abuse them
"B008", # It's totally OK to call functions for default arguments.
"B904", # raise SomeException(...) is fine.
"B905", # No need for explicit strict, this is simply zip's default behavior
"C408", # Calling dict is fine when it saves quoting the keys
"C901", # Not really something to focus on
"D105", # It's fine to not have docstrings for magic methods.
"D107", # __init__ especially doesn't need a docstring
"D200", # This rule makes diffs uglier when expanding docstrings
"D203", # No blank lines before docstrings.
"D212", # Start docstrings on the second line.
"D400", # This rule misses sassy docstrings ending with ! or ?
"D401", # This rule is too flaky.
"D406", # Section headers should end with a colon not a newline
"D407", # Underlines aren't needed
"D412", # Plz spaces after section headers
"EM101", # These don't bother me, it's fine there's some duplication.
"EM102",
"FBT", # It's worth avoiding boolean args but I don't care to enforce it
"FIX", # Yes thanks, if I could it wouldn't be there
"N", # These naming rules are silly
"PLR0912", # These metrics are fine to be aware of but not to enforce
"PLR0913",
"PLR0915",
"PLW2901", # Shadowing for loop variables is occasionally fine.
"PT006", # pytest parametrize takes strings as well
"PYI025", # wat, I'm not confused, thanks.
"RET502", # Returning None implicitly is fine
"RET503",
"RET505", # These push you to use `if` instead of `elif`, but for no reason
"RET506",
"RSE102", # Ha, what, who even knew you could leave the parens off. But no.
"SIM300", # Not sure what heuristic this uses, but it's easily incorrect
"SLF001", # Private usage within this package itself is fine
"TD", # These TODO style rules are also silly
"UP007", # We support 3.8 + 3.9
]
[tool.ruff.lint.flake8-pytest-style]
mark-parentheses = false
[tool.ruff.lint.flake8-quotes]
docstring-quotes = "double"
[tool.ruff.lint.isort]
combine-as-imports = true
from-first = true
known-first-party = ["rpds"]
[tool.ruff.lint.per-file-ignores]
"noxfile.py" = ["ANN", "D100", "S101", "T201"]
"docs/*" = ["ANN", "D", "INP001"]
"tests/*" = ["ANN", "B018", "D", "PLR", "RUF012", "S", "SIM", "TRY"]