proejct commit

This commit is contained in:
2026-09-24 15:45:31 +02:00
commit 82d52be8a5
63 changed files with 8748 additions and 0 deletions
+74
View File
@@ -0,0 +1,74 @@
[build-system]
requires = ["setuptools>=69"]
build-backend = "setuptools.build_meta"
[project]
name = "physics-sandbox"
version = "1.0.0"
description = "Interaktive 2D-Physik-Sandbox mit eigener Physik-Engine (Rendering mit pygame-ce)"
readme = "README.md"
requires-python = ">=3.10"
dependencies = ["pygame-ce>=2.5"]
[project.scripts]
physics-sandbox = "sandbox.main:main"
[tool.setuptools.packages.find]
where = ["src"]
# --------------------------------------------------------------------------- ruff
[tool.ruff]
line-length = 100
target-version = "py310"
src = ["src", "tests"]
[tool.ruff.lint]
select = [
"E", "W", # pycodestyle
"F", # pyflakes
"I", # Import-Sortierung
"B", # bugbear: typische Fehlerquellen
"UP", # moderne Python-Syntax
"SIM", # Vereinfachungen
"N", # Namenskonventionen
"C4", # Comprehensions
"PIE",
"RUF",
"D", # Docstrings für Module, Klassen und öffentliche Funktionen
"ANN", # Type Hints durchgehend
"PLR2004", # keine Magic Numbers in Vergleichen
]
ignore = [
"D105", # Docstrings für Dunder-Methoden (__add__ usw.) wären reines Rauschen
"D107", # __init__ wird im Klassen-Docstring beschrieben
# Kommentare und Docstrings sind deutsch und nutzen bewusst Formelzeichen (·, ×, ², ω, μ):
"RUF001", "RUF002", "RUF003",
]
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.ruff.lint.per-file-ignores]
# Testfunktionen sprechen über ihre Namen für sich; Zahlenwerte in Asserts sind gewollt.
"tests/**" = ["D101", "D102", "D103", "PLR2004"]
# --------------------------------------------------------------------------- pytest
[tool.pytest.ini_options]
testpaths = ["tests"]
pythonpath = ["src"]
addopts = "--strict-markers"
markers = [
"slow: länger laufende Tests (Stresstest, Smoke-Test der Hauptschleife)",
]
# --------------------------------------------------------------------------- coverage
[tool.coverage.run]
source = ["sandbox"]
branch = true
[tool.coverage.report]
show_missing = true
exclude_also = [
"if __name__ == .__main__.:",
"raise NotImplementedError",
]