Files
MediaManager-maxdorninger-1/ruff.toml
Maximilian Dorninger f5253990e0 switch from APScheduler to Taskiq (#461)
This PR replaces the APScheduler lib with the Taskiq task queuing lib. 

# why

APScheduler doesn't support FastAPI's DI in tasks, this makes them quite
cumbersome to read and write since DB, Repositories and Services all
need to be instanciated manually.

Moreover, Taskiq makes it easier to start background tasks from FastAPI
requests. This enables MM to move to a more event-based architecture.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* App now uses an orchestrated async startup/shutdown and runs
background scheduling via a database-backed task queue; startup enqueues
pre-load/import/update tasks.

* **Bug Fixes**
* Improved torrent client handling with clearer conflict messages and
guidance for manual resolution.
* Enhanced logging around season, episode and metadata update
operations; minor regex/behaviour formatting preserved.

* **Chores**
* Updated dependencies to support the new task queue and connection
pooling.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-02-26 21:23:24 +01:00

45 lines
970 B
TOML

exclude = ["alembic/versions"]
namespace-packages = ["alembic", "metadata_relay"]
[format]
line-ending = "lf"
quote-style = "double"
[lint]
# to be enabled: BLE, C90, CPY, D, DOC, DTZ, FBT, G, PL, RSE, SLF, SIM, TC
extend-select = [
"A", "ARG", "ASYNC", "ANN",
"B",
"C4", "COM",
"DTZ",
"E", "EM", "EXE",
"F", "FA", "FAST", "FIX", "FLY", "FURB",
"I", "ICN", "INP", "INT", "ISC",
"LOG",
"N",
"PERF", "PGH", "PIE", "PT", "PTH", "PYI",
"Q",
"RET", "RUF",
"S", "SLOT",
"T10", "T20", "TD", "TID", "TRY",
"UP",
"W",
"YTT"
]
ignore = [
# incompatible with formatter
"COM812",
# lines too long
"E501",
# currently a bug?! with providers and depends
"FAST003",
# I'm not sure if we want to lint them
"FIX002",
# let's decide if we want this
"TD002", "TD003",
]
[lint.flake8-bugbear]
extend-immutable-calls = ["fastapi.Depends", "fastapi.Path", "taskiq.TaskiqDepends"]