Skip to content

Commit ede3804

Browse files
committed
more logging tweaks
1 parent ee63fea commit ede3804

3 files changed

Lines changed: 4 additions & 5 deletions

File tree

yaqd-core/yaqd_core/_is_daemon.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ async def _main(cls, config_filepath, config_file, args=None):
221221
try:
222222
config = cls._parse_config(config_file, section, args)
223223
except ValueError as e:
224-
logger.error(str(e))
224+
logger.info(str(e))
225225
continue
226226
logger.debug(f"Starting {section} with {config}")
227227
await cls._start_daemon(section, config, config_filepath)
@@ -280,7 +280,6 @@ def _parse_config(cls, config_file, section, args=None):
280280
pass
281281

282282
if not config.get("enable", True):
283-
logger.info(f"Section '{section}' is disabled")
284283
raise ValueError(f"Section '{section}' is disabled")
285284
return config
286285

yaqd-core/yaqd_core/_protocol.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,14 @@ def __init__(self, daemon, *args, **kwargs):
1717

1818
def connection_lost(self, exc):
1919
peername = self.transport.get_extra_info("peername")
20-
self.logger.info(f"Connection lost from {peername} to {self._daemon.name}")
20+
self.logger.info(f"Connection with {peername} lost")
2121
self.task.cancel()
2222
self._daemon._connection_lost(peername)
2323

2424
def connection_made(self, transport):
2525
"""Process an incomming connection."""
2626
peername = transport.get_extra_info("peername")
27-
self.logger.info(f"Connection made from {peername} to {self._daemon.name}")
27+
self.logger.info(f"Connection with {peername} made")
2828
self.transport = transport
2929
self.unpacker = avrorpc.Unpacker(self._avro_protocol)
3030
self._daemon._connection_made(peername)

yaqd-core/yaqd_core/logging/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848

4949
formatter = logging.Formatter(
5050
"{levelname} : {asctime} : {name} : {message}",
51-
datefmt="%Y-%m-%dT%H:%M:%S%z",
51+
datefmt="%Y-%m-%dT%H:%M:%S",
5252
style="{",
5353
)
5454

0 commit comments

Comments
 (0)