[tool.poetry]
name = "pyinaturalist"
version = "0.14.0.b2"
description = "iNaturalist API client for python"
authors = ["Nicolas Noé <nicolas@niconoe.eu>", "Jordan Cook <Jordan.Cook@pioneer.com>"]
license = "MIT"
readme = "README.md"
homepage = "https://github.com/niconoe/pyinaturalist"
repository = "https://github.com/niconoe/pyinaturalist"
documentation = "https://pyinaturalist.readthedocs.io"
keywords = ["inaturalist", "biodiversity", "conservation", "citizen-science", "community-science",
            "api", "api-client", "data-model", "requests"]
classifiers = [
    "Development Status :: 4 - Beta",
    "Intended Audience :: Developers",
    "Intended Audience :: Education",
    "Intended Audience :: Science/Research",
    "Typing :: Typed",
]
include = [
    { path = "*.md" },
    { path = "*.yml" },
    { path = "docs", format = "sdist" },
    { path = "examples", format = "sdist" },
    { path = "test", format = "sdist" }
]

[tool.poetry.dependencies]
python = "^3.6"
attrs = ">=21.2.0"
python-dateutil = ">=2.0"
requests = ">=2.20"

# These could potentially be made optional, but for now they're useful enough to include by default
keyring = ">=22.3"
python-forge = ">=18.6.0"
pyrate-limiter = ">=2.3.3"
rich = ">=10.0"

# Documentation dependencies needed for Readthedocs builds
furo = {version = ">=2021.6.24-beta.37", optional = true}
linkify-it-py = {version = "^1.0.1", optional = true}
myst-parser = {version = "^0.15.1", optional = true}
nbsphinx = { version = "^0.8.5", optional = true }
sphinx = { version = "^4.0.2", optional = true }
sphinx-automodapi = { version=">=0.13", optional = true}
sphinx-autodoc-typehints = { version = "^1.11", optional = true }
sphinx-copybutton = { version = "^0.3", optional = true }
sphinx-inline-tabs = {version = "^2021.4.11-beta.9", optional = true, python = ">=3.8"}
sphinxcontrib-apidoc = { version = "^0.3", optional = true }

[tool.poetry.extras]
all = []  # Placeholder for optional dependencies needed to run examples in docs
docs = ["furo", "linkify-it-py", "myst-parser", "nbsphinx", "sphinx", "sphinx-automodapi",
        "sphinx-autodoc-typehints", "sphinx-copybutton", "sphinx-inline-tabs", "sphinxcontrib-apidoc"]

[tool.poetry.dev-dependencies]
black = {version = "21.6b0", python = ">=3.6.2, <3.10"}
ipython = {version = ">=7.23", python = "^3.7"}
flake8 = "^3.9"
isort = "5.8.0"  # locked until issue #1762 is fixed
mypy = "^0.910"
pre-commit = {version = "^2.12", python = "^3.6.2"}
pytest = "^6.2"
pytest-cov = ">=2.11"
pytest-xdist = ">=2.2"
requests-mock = "^1.8"
rich = ">=10.0"
types-python-dateutil = ">=0.1.2"
types-requests = ">=0.1.8"

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

[tool.black]
skip-string-normalization = true
line-length = 105

[tool.coverage.html]
directory = 'test-reports'

[tool.coverage.run]
branch = true
source = ['pyinaturalist']
omit = ['pyinaturalist/api_docs/model_docs.py']

[tool.isort]
profile = 'black'
line_length = 105
skip_gitignore = true
skip = [
    'pyinaturalist/__init__.py',
    'pyinaturalist/models/__init__.py',
    'pyinaturalist/node_api.py',
]
known_first_party = ['test']
# Things that are common enough they may as well be grouped with stdlib imports
extra_standard_library = ['dateutil', 'pytest', 'setuptools']

[tool.mypy]
ignore_missing_imports = true
exclude = "examples|docs|downloads|dist|build|test"
