From cb2165b3ab2f20a6ad1d9d7d7e6343b36dc40442 Mon Sep 17 00:00:00 2001 From: Tsonglew Date: Thu, 7 Nov 2024 22:06:46 +0800 Subject: [PATCH] Fix agent start failed in async mode when profiling is enabled (#360) --- CHANGELOG.md | 1 + skywalking/command/command_service.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6943691e..a943610a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ - Fix pulsar client does not support init arguments other than service_url (#351) - Fix outdated make dev-fix rule in CodeStyle.md (#350) - Fix TestClient for fastapi cause the req.client None error (#355) + - Fix agent start failed in async mode when profiling is enabled (#360) ### 1.1.0 diff --git a/skywalking/command/command_service.py b/skywalking/command/command_service.py index c968fc98..732fc6dd 100644 --- a/skywalking/command/command_service.py +++ b/skywalking/command/command_service.py @@ -68,11 +68,11 @@ def receive_command(self, commands: Commands): class CommandServiceAsync: def __init__(self): - self._commands = AsyncQueue() # type: AsyncQueue # don't execute same command twice self._command_serial_number_cache = CommandSerialNumberCache() async def dispatch(self): + self._commands = AsyncQueue() # type: AsyncQueue while True: # block until a command is available command = await self._commands.get() # type: BaseCommand