We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 02f4faa commit f5d47b0Copy full SHA for f5d47b0
src/galaxy/api/plugin.py
@@ -200,7 +200,14 @@ def close(self) -> None:
200
logger.info("Closing plugin")
201
self._connection.close()
202
self._external_task_manager.cancel()
203
- self._internal_task_manager.create_task(self.shutdown(), "shutdown")
+
204
+ async def shutdown():
205
+ try:
206
+ await asyncio.wait_for(self.shutdown(), 30)
207
+ except asyncio.TimeoutError:
208
+ logging.warning("Plugin shutdown timed out")
209
210
+ self._internal_task_manager.create_task(shutdown(), "shutdown")
211
self._active = False
212
213
async def wait_closed(self) -> None:
0 commit comments