[build-system]
requires = [
    "setuptools>=68.2.2; python_version < '4.0'  and python_version >= '3.8'",
    "Cython>=3.0.3",
]
build-backend = "setuptools.build_meta"  # comment out to disable pep517

[tool.coverage.run]
branch = true

[tool.coverage.report]
exclude_lines =[
    "pragma: no cover",
    ".*  # pragma: no cover",
    ".*  # nocover",
    "def __repr__",
    "raise AssertionError",
    "raise NotImplementedError",
    "if 0:",
    "if trace is not None",
    "verbose = .*",
    "^ *raise",
    "^ *pass *$",
    "if _debug:",
    "if __name__ == .__main__.:",
]

omit =[
    "*/setup.py"
]

[tool.cibuildwheel]
build = "cp38-* cp39-* cp310-* cp311-* cp312-* cp313-* cp314-*"
skip = ["*-win32", "cp3{9,10}-win_arm64", "cp313-musllinux_i686"]
build-frontend = "build"
build-verbosity = 1
test-command = "python {project}/run_tests.py"
test-extras = ["tests-strict", "runtime-strict"]

# https://cibuildwheel.readthedocs.io/en/stable/options/#archs
[tool.cibuildwheel.macos]
archs = ["x86_64", "universal2", "arm64"]
[tool.cibuildwheel.windows]
archs = ['AMD64', 'ARM64']


[tool.mypy]
ignore_missing_imports = true

[tool.xcookie]
tags = [ "pyutils", "binpy", "github",]
mod_name = "line_profiler"
repo_name = "line_profiler"
rel_mod_parent_dpath = "."
os = [ "all", "linux", "osx", "win",]
main_python = '3.13'
min_python = '3.8'
max_python = '3.14'
author = "Robert Kern"
author_email = "robert.kern@enthought.com"
description = "Line-by-line profiler"
url = "https://github.com/pyutils/line_profiler"
license = "BSD"
dev_status = "stable"
typed = true
skip_autogen = ["MANIFEST.in", "CHANGELOG.md"]
test_env = """
COVERAGE_CORE: ctrace
"""

[tool.xcookie.entry_points]
# the console_scripts entry point creates the xdoctest executable
console_scripts = [
    "kernprof=kernprof:main",
]


[tool.pytest.ini_options]
addopts = "--ignore-glob=setup.py --ignore-glob=dev --ignore-glob=setup.py --ignore-glob=docs --ignore-glob=agentx"
norecursedirs = ".git ignore build __pycache__ dev _skbuild docs agentx"
filterwarnings = [
    "default",
]
