|
| 1 | +[build-system] |
| 2 | +requires = ["setuptools>=61.2"] |
| 3 | +build-backend = "setuptools.build_meta" |
| 4 | + |
| 5 | +[project] |
| 6 | +name = "modelgraph" |
| 7 | +version = "1.0.1" |
| 8 | +description = "Tool for extracting dependency graphs from gotran ODE models" |
| 9 | +authors = [{name = "Henrik Finsberg", email = "henriknf@simula.no"}] |
| 10 | +license = {text = "MIT"} |
| 11 | +classifiers = [ |
| 12 | + "License :: OSI Approved :: MIT License", |
| 13 | + "Programming Language :: Python :: 3", |
| 14 | + "Programming Language :: Python :: 3 :: Only", |
| 15 | +] |
| 16 | +keywords = ["ODE", "models", "graphs", "dependencies"] |
| 17 | +requires-python = ">=3.8" |
| 18 | +dependencies = [ |
| 19 | + "click", |
| 20 | + "networkx", |
| 21 | + "pydot", |
| 22 | + "importlib-metadata;python_version<'3.8'", |
| 23 | +] |
| 24 | + |
| 25 | +[project.readme] |
| 26 | +file = "README.md" |
| 27 | +content-type = "text/markdown" |
| 28 | + |
| 29 | +[project.urls] |
| 30 | +Homepage = "https://github.com/ComputationalPhysiology/modelgraph" |
| 31 | + |
| 32 | +[project.optional-dependencies] |
| 33 | +dev = [ |
| 34 | + "Sphinx", |
| 35 | + "black", |
| 36 | + "build", |
| 37 | + "bump2version", |
| 38 | + "flake8", |
| 39 | + "ipython", |
| 40 | + "isort", |
| 41 | + "mypy", |
| 42 | + "pdbpp", |
| 43 | + "pip", |
| 44 | + "pre-commit", |
| 45 | + "sphinx", |
| 46 | + "twine", |
| 47 | + "wheel", |
| 48 | +] |
| 49 | +docs = [ |
| 50 | + "Sphinx", |
| 51 | + "jupytext", |
| 52 | + "myst-parser", |
| 53 | + "gotran", |
| 54 | + "gotranx", |
| 55 | + "sphinx-press-theme", |
| 56 | +] |
| 57 | +gui = ["streamlit"] |
| 58 | +plot = [ |
| 59 | + "matplotlib", |
| 60 | + "pydot", |
| 61 | +] |
| 62 | +test = [ |
| 63 | + "gotran", |
| 64 | + "gotranx", |
| 65 | + "pytest", |
| 66 | + "pytest-cov", |
| 67 | +] |
| 68 | + |
| 69 | +[tool.setuptools] |
| 70 | +package-dir = {"" = "src"} |
| 71 | +zip-safe = false |
| 72 | +license-files = ["LICENSE"] |
| 73 | +include-package-data = false |
| 74 | + |
| 75 | +[tool.setuptools.packages.find] |
| 76 | +where = ["src"] |
| 77 | +namespaces = false |
| 78 | + |
| 79 | +[tool.flake8] |
| 80 | +exclude = "docs" |
| 81 | +ignore = "E203, E266, E501, W503, E731" |
| 82 | +max-line-length = "88" |
| 83 | +max-complexity = "18" |
| 84 | +select = "B,C,E,F,W,T4" |
| 85 | + |
| 86 | +[tool.aliases] |
| 87 | +test = "pytest" |
| 88 | + |
| 89 | +[tool.pytest.ini_options] |
| 90 | +addopts = "--cov=src/modelgraph --cov-report html --cov-report xml --cov-report term-missing -v" |
| 91 | +testpaths = ["tests"] |
| 92 | + |
| 93 | +[tool.mypy] |
| 94 | +files = ["src/modelgraph", "tests"] |
| 95 | +ignore_missing_imports = true |
| 96 | +exclude = "docs" |
| 97 | + |
| 98 | +[tool.coverage.run] |
| 99 | +omit = [ |
| 100 | + "src/modelgraph/gui.py", |
| 101 | + "src/modelgraph/cli.py", |
| 102 | + "src/modelgraph/__main__.py", |
| 103 | +] |
| 104 | + |
| 105 | + |
| 106 | +[tool.ruff] |
| 107 | + |
| 108 | +# Exclude a variety of commonly ignored directories. |
| 109 | +exclude = [ |
| 110 | + "examples", |
| 111 | + ".bzr", |
| 112 | + ".direnv", |
| 113 | + ".eggs", |
| 114 | + ".git", |
| 115 | + ".hg", |
| 116 | + ".mypy_cache", |
| 117 | + ".nox", |
| 118 | + ".pants.d", |
| 119 | + ".pytype", |
| 120 | + ".ruff_cache", |
| 121 | + ".svn", |
| 122 | + ".tox", |
| 123 | + ".venv", |
| 124 | + "__pypackages__", |
| 125 | + "_build", |
| 126 | + "buck-out", |
| 127 | + "build", |
| 128 | + "dist", |
| 129 | + "node_modules", |
| 130 | + "venv", |
| 131 | + "submit.py" |
| 132 | +] |
| 133 | + |
| 134 | +# Same as Black. |
| 135 | +line-length = 110 |
| 136 | + |
| 137 | +# Assume Python 3.10. |
| 138 | +target-version = "py310" |
| 139 | + |
| 140 | +[tool.ruff.lint] |
| 141 | +# Enable pycodestyle (`E`) and Pyflakes (`F`) codes by default. |
| 142 | +select = ["E", "F"] |
| 143 | +ignore = ["E402", "E741", "E743", "E731"] |
| 144 | + |
| 145 | +# Allow autofix for all enabled rules (when `--fix`) is provided. |
| 146 | +fixable = ["A", "B", "C", "D", "E", "F"] |
| 147 | +unfixable = [] |
| 148 | + |
| 149 | +# Allow unused variables when underscore-prefixed. |
| 150 | +dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$" |
| 151 | + |
| 152 | + |
| 153 | +[tool.ruff.lint.mccabe] |
| 154 | +# Unlike Flake8, default to a complexity level of 10. |
| 155 | +max-complexity = 10 |
0 commit comments