Spaces:
Sleeping
Sleeping
File size: 2,707 Bytes
31b602c 6424951 61cadeb 6424951 62f439a 6424951 56bab24 6424951 31b602c 6424951 92a832f 6424951 31b602c 92a832f 5c113ef 6424951 92a832f 31b602c 6424951 c879e61 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 | [build-system]
requires = ["setuptools>=68.0"]
build-backend = "setuptools.build_meta"
[project]
name = "streamlit-nba"
version = "1.1.0"
description = "NBA team builder and game prediction Streamlit application"
license = {text = "Apache-2.0"}
requires-python = ">=3.11"
dependencies = [
"streamlit>=1.28.0",
"tensorflow>=2.15.0",
"numpy>=1.24.0",
"pandas>=2.0.0",
"pydantic>=2.5.0",
]
[project.optional-dependencies]
dev = [
"pytest>=7.4.0",
"pytest-cov>=4.1.0",
"mypy>=1.7.0",
"ruff>=0.1.6",
"pandas-stubs>=2.0.0",
"pre-commit>=3.0.0",
]
train = [
"scikit-learn>=1.3.0",
"scikeras>=0.12.0",
]
[tool.mypy]
python_version = "3.11"
strict = true
warn_return_any = true
warn_unused_configs = true
disallow_untyped_defs = true
disallow_incomplete_defs = true
check_untyped_defs = true
disallow_untyped_decorators = true
no_implicit_optional = true
warn_redundant_casts = true
warn_unused_ignores = true
warn_no_return = true
warn_unreachable = true
# Third-party library ignores
[[tool.mypy.overrides]]
module = [
"streamlit.*",
"tensorflow.*",
"keras.*",
"sklearn.*",
"scikeras.*",
"pydantic.*",
"pydantic_core.*",
"numpy.*",
]
ignore_missing_imports = true
[tool.ruff]
target-version = "py311"
line-length = 88
[tool.ruff.lint]
select = [
"E", # pycodestyle errors
"W", # pycodestyle warnings
"F", # pyflakes
"I", # isort
"B", # flake8-bugbear
"C4", # flake8-comprehensions
"UP", # pyupgrade
"ARG", # flake8-unused-arguments
"SIM", # flake8-simplify
"TCH", # flake8-type-checking
"PTH", # flake8-use-pathlib
"PL", # pylint
"RUF", # ruff-specific
"S", # flake8-bandit (security)
]
ignore = [
"S101", # assert used (ok in tests)
"PLR0913", # too many arguments
"SIM105", # prefer explicit try-except over contextlib.suppress
"PLR2004", # magic numbers ok in game logic
"S311", # standard pseudo-random generators ok for game logic
"E501", # line length (handled by formatter or ignored)
]
[tool.ruff.lint.per-file-ignores]
"tests/*" = ["S101", "ARG001", "ARG002", "PLR2004", "PLC0415"]
"src/config.py" = ["PLC0415"] # lazy import of streamlit in configure_page()
[tool.pytest.ini_options]
testpaths = ["tests"]
python_files = ["test_*.py"]
python_functions = ["test_*"]
addopts = [
"-v",
"--tb=short",
"--strict-markers",
]
[tool.coverage.run]
source = ["src"]
branch = true
omit = [
"tests/*",
"scripts/*",
]
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"if TYPE_CHECKING:",
"raise NotImplementedError",
]
fail_under = 70
|