Skip to content

Commit ce80d90

Browse files
authored
Less verbose logs (#154)
- **Adjust logging level to be less verbose**
2 parents 4a1edd1 + 3d50954 commit ce80d90

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

RELEASE_NOTES.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
## New Features
1212

1313
* This release now supports the sdk up to rc2000.
14+
* Less logs are now on `INFO` level, and more on `DEBUG` level, making the output less verbose.
1415

1516
## Bug Fixes
1617

src/frequenz/dispatch/_bg_service.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ async def _fetch(self) -> None:
296296
self._dispatches = {}
297297

298298
try:
299-
_logger.info("Fetching dispatches for microgrid %s", self._microgrid_id)
299+
_logger.debug("Fetching dispatches for microgrid %s", self._microgrid_id)
300300
async for page in self._client.list(microgrid_id=self._microgrid_id):
301301
for client_dispatch in page:
302302
dispatch = Dispatch(client_dispatch)
@@ -314,15 +314,15 @@ async def _fetch(self) -> None:
314314
)
315315
await self._lifecycle_events_tx.send(Updated(dispatch=dispatch))
316316

317-
_logger.info("Received %s dispatches", len(self._dispatches))
317+
_logger.debug("Received %s dispatches", len(self._dispatches))
318318

319319
except grpc.aio.AioRpcError as error:
320320
_logger.error("Error fetching dispatches: %s", error)
321321
self._dispatches = old_dispatches
322322
return
323323

324324
for dispatch in old_dispatches.values():
325-
_logger.info("Deleted dispatch: %s", dispatch)
325+
_logger.debug("Deleted dispatch: %s", dispatch)
326326
await self._lifecycle_events_tx.send(Deleted(dispatch=dispatch))
327327
await self._update_dispatch_schedule_and_notify(None, dispatch)
328328

0 commit comments

Comments
 (0)