Apply black formatter

This commit is contained in:
n07070
2026-06-04 00:31:04 +02:00
parent 0e0197e11c
commit 0c759dce9c
8 changed files with 103 additions and 49 deletions

View File

@@ -126,6 +126,7 @@ limiter = Limiter(
get_remote_address, app=app, default_limits=["1500 per day", "500 per hour"]
)
# General routes
@app.route("/")
@limiter.limit("1/second", override_defaults=False)
@@ -317,11 +318,13 @@ def api_queue_status():
"""API endpoint for entire queue"""
return jsonify(web.get_queue_state())
@app.route("/api/queue/completed", methods=["GET"])
def api_queue_completed():
"""API endpoint that returns the finished tasks"""
return jsonify(web.get_queue_completed())
@app.route("/api/worker", methods=["GET"])
def api_worker_state():
"""API endpoint to get the worker state"""