janw/podcast-archiver

View on GitHub
pyproject.toml

Summary

Maintainability
Test Coverage
[tool.poetry]
name = "podcast-archiver"
version = "1.7.1"
description = "Archive all episodes from your favorite podcasts"
# cspell: disable
authors = ["Jan Willhaus <mail@janwillhaus.de>"]
license = "MIT"
readme = "README.md"
packages = [{ include = "podcast_archiver" }]
classifiers = [
    "Development Status :: 4 - Beta",
    "Environment :: Console",
    "Intended Audience :: Information Technology",
    "Operating System :: MacOS",
    "Operating System :: Microsoft :: Windows",
    "Operating System :: POSIX :: Linux",
    "Topic :: Multimedia",
    "Topic :: Multimedia :: Sound/Audio",
    "Topic :: System :: Archiving",
    "Topic :: Utilities",
]
repository = "https://github.com/janw/podcast-archiver"

[tool.poetry.urls]
"Bug Reports" = "https://github.com/janw/podcast-archiver/issues"

[tool.poetry.scripts]
podcast-archiver = 'podcast_archiver.cli:main'

[tool.poetry.dependencies]
python = "^3.10"
feedparser = "^6.0.10"
requests = "^2.29.0"
pydantic = "^2.5.3"
platformdirs = ">=3.4,<5.0"
pyyaml = "^6.0"
rich-click = "^1.8.0"
python-slugify = "^8.0.1"
tqdm = "^4.66.4"

[tool.poetry.group.dev.dependencies]
ipython = "<8.30"
ipdb = "*"
ruff = "0.6.8"
pre-commit = ">=3,<5"
commitizen = "^3"
rich-codex = "^1"
mypy = "^1"
types-tqdm = "^4.66.0.20240417"

[tool.poetry.group.tests.dependencies]
pytest = "^8"
pytest-cov = "^5"
pytest-responses = "^0.5.1"
pytest-env = "1.1.5"

[tool.commitizen]
version_scheme = "semver"
version_provider = "poetry"
version_files = [
    "pyproject.toml:version = ",
    "podcast_archiver/__init__.py",
]
annotated_tag = true
tag_format = "v$version"
update_changelog_on_bump = true
changelog_start_rev = "0.4"
gpg_sign = true

[tool.ruff]
line-length = 120
target-version = "py310"
lint.extend-select = [
    "I",   # isort
    "B",   # bugbear
    "A",   # builtins
    "ISC", # implicit-str-concat
    "Q",   # quotes
    "TID", # tidy-imports
    "C4",  # comprehensions
    "SIM", # simplify
    "C90", # mccabe
    "FA",  # future-annotations
    "TCH", # type-checking
    "RUF", # ruff-specific
]
lint.ignore = [
    "SIM108", # if-else-block-instead-of-if-exp
    "ISC001", # single-line-implicit-string-concatenation
]

[tool.ruff.format]
quote-style = "double"

[tool.ruff.lint.mccabe]
max-complexity = 8

[tool.pytest.ini_options]
minversion = "6.0"
testpaths = ["tests",]
addopts = "--cov podcast_archiver --cov-config=pyproject.toml --cov-report term --no-cov-on-fail"

[tool.pytest_env]
PODCAST_ARCHIVER_CONFIG = ""
TESTING = 1

[tool.coverage.run]
branch = true
source = [
    "podcast_archiver",
]

[tool.coverage.report]
exclude_also = [
    "if TYPE_CHECKING:",
]
fail_under = 60
precision = 2
show_missing = true

[tool.mypy]
disallow_untyped_defs = true
disallow_any_generics = true
# disallow_subclassing_any = true
disallow_untyped_calls = true
disallow_incomplete_defs = true
warn_unused_configs = true
warn_redundant_casts = true
warn_unused_ignores = true
# warn_return_any = true
strict_optional = true
strict_equality = true
check_untyped_defs = true
no_implicit_reexport = true

packages = ["podcast_archiver", "tests"]
plugins = [
    "pydantic.mypy",
]

[[tool.mypy.overrides]]
module = [
    "feedparser.*",
    "requests.*",
    "slugify.*",
    "yaml.*",
]
ignore_missing_imports = true


[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"