From 12817ea21bf77594053928142438926c7ff9dd98 Mon Sep 17 00:00:00 2001 From: Laurent Peuch Date: Thu, 7 Feb 2019 14:11:57 +0100 Subject: [PATCH] [mod] add a dummy page for /github GET to avoid stupid errors in logs --- server.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/server.py b/server.py index 38a9a1c..203c67c 100644 --- a/server.py +++ b/server.py @@ -39,6 +39,11 @@ def notify(message, repository="dev"): subprocess.check_call(["python", "./to_room.py", gitbot_password, message, chan]) +@app.route("/github", methods=['GET']) +async def github_get(request): + return text("You aren't supposed to go on this page using a browser, it's for webhooks push instead.") + + @app.route("/github", methods=['POST']) async def github(request): # Only SHA1 is supported