diff --git a/calparrot/proxy.py b/calparrot/proxy.py
index 4adbb647e1535c4818d0c2fa101e967f1863ac58..a14ee0e1d4326d25277263f36b700731434bb7f5 100644
--- a/calparrot/proxy.py
+++ b/calparrot/proxy.py
@@ -176,8 +176,9 @@ class ShutdownHandler(RequestHandler):
 
 
 class ProxyApp:
+    quit_event: asyncio.Event
+
     def __init__(self, creds, db_path='calparrot.sqlite'):
-        self.quit_event = asyncio.Event()
         self.response_store = ResponsesDB(db_path)
         base_url = creds['base_url'].rstrip('/')  # e.g. https://in.xfel.eu/calibration
 
@@ -210,6 +211,7 @@ class ProxyApp:
 
     async def serve(self):
         """Serve requests until asked to quit"""
+        self.quit_event = asyncio.Event()
         server = HTTPServer(self.tornado_app)
         # add_sockets hooks up the server to the event loop
         server.add_sockets(self.sockets)