[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

[tool.hatch.metadata]
allow-direct-references = true

[project]
name = "psynet"
version = "13.1.1"
authors = [
  {name="Peter Harrison", email="pmch2@cam.ac.uk"},
  {name="Frank Höger", email="frank.hoeger@ae.mpg.de"},
  {name="Pol van Rijn", email="pol.van-rijn@ae.mpg.de"},
  {name="Raja Marjieh", email="raja.marjieh@princeton.edu"},
  {name="Nori Jacoby", email="nori.jacoby@ae.mpg.de"}
]
maintainers = [
  {name = "Peter Harrison", email = "pmch2@cam.ac.uk"}
]
license = {file = "LICENSE"}
description = "PsyNet – complex psychological experiments made easy"  # A framework for running advanced psychological experiments
keywords = ["psychology", "experiments", "online", "networks"]
readme = "README.md"
requires-python = ">=3.10"  # recommended Python version: 3.13
classifiers = [
    "Development Status :: 4 - Beta",
    "Programming Language :: Python :: 3.13",
    "Programming Language :: Python :: 3.12",
    "Programming Language :: Python :: 3.11",
    "Programming Language :: Python :: 3.10",
    "Framework :: Flask",
    "Operating System :: OS Independent",
    "License :: OSI Approved :: MIT License",
    "Intended Audience :: Science/Research",
]

dependencies = [
    "babel",
    "dallinger[docker]>=12.1.2,<13",
    # Unpin dominate once a new version is released which includes the following
    # fix for the Python 3.12 event loop warning:
    # https://github.com/Knio/dominate/commit/bdbdb8e5ddcf3213518dba0c7d054f14933460bf
    "debugpy",
    "dominate==2.9.1",
    "html2text",
    "joblib",
    "jsonpickle",
    "pandas",
    "paramiko",
    "polib",
    "progress",
    "pytest",
    "pytest-dependency",
    "pytest-mock",
    "pytest-timeout",
    "python-gettext",
    "rpdb",
    "slack_sdk",  # For Slack notifications
    "tenacity",
    "tomlkit",
    "tqdm",
    "yaspin",
    "arabic-reshaper",  # Used by VocabTest
    "pillow"  # Used by VocabTest
]

[project.optional-dependencies]
dev = [
    "bump-my-version",
    "furo",
    "google-cloud-translate",
    "isort",
    "openai",
    "pre-commit",
    "sphinx",
    "sphinx-autodoc-typehints",
    "sphinx-inline-tabs",
    "beautifulsoup4",
    "pytest-test-groups",
]
slack = [
    "slack_sdk",
]

[project.entry-points.pytest11]
pytest_psynet = "psynet.pytest_psynet"

[project.scripts]
psynet = "psynet.command_line:psynet"

[project.urls]
Changelog = "https://gitlab.com/PsyNetDev/PsyNet/-/blob/master/CHANGELOG.md"
Documentation = "https://psynetdev.gitlab.io/PsyNet/"
Homepage = "https://www.psynet.dev/"
Issues = "https://gitlab.com/PsyNetDev/PsyNet/-/issues"
Repository = "https://gitlab.com/PsyNetDev/PsyNet/"

[tool.hatch.build.targets.wheel]
include = ["/psynet"]

[tool.hatch.build.targets.sdist]
exclude = [
    "/.gitlab",
    "/.postgres_setup.sql",
    "/.run-ci-tests-locally-v2.sh",
    "/.run-ci-tests-locally.sh",
    "/.venv*",
    "/ci",
    "/demos",
    "/docs",
    "/tests",
]

[tool.black]
line-length = 88
target-version = ["py313"]
include = '\.pyi?$'
exclude = '''
/(
    \.eggs
  | \.git
  | \.hg
  | \.mypy_cache
  | \.tox
  | \.venv
  | docs/_build
  | dist
)/
'''
