π€ Auto-generated by Claude Fable 5.1 (claude-fable-5-1) via Claude Code β NOT human-reviewed. Verify before acting.
ovos_utils.log.log_deprecation names the logger it writes to after the call site:
log_name = f"{LOG.name} - {name}:{func_name or call[3]}:{call[2]}"
LOG.create_logger(log_name).warning(...)
create_logger gives that logger its own StreamHandler and sets propagate = False. So every deprecation lands on a logger such as OVOS - ovos_bus_client.session:_normalize_location_input:87, one per call site, that no client can name in advance, and a filter on the OVOS logger never sees it. There is no configuration or environment switch for deprecations either (checked LOG.init and the logging config keys in ovos-utils 0.8.5).
Why it matters: ovos-bus-client 2.11 logs a deprecation every time it reads a session whose location is in the nested city/coordinate/timezone shape. A hub whose ovos-core still serialises that shape (every stock install: ovos-config's default location is nested) makes every client log it on every message it receives. Measured on a HiveMind satellite: three lines per question, and three hundred in six minutes of connection probes. The client cannot change the hub's shape, so the only honest thing it can do is drop that one record β and the only place to catch it is LOG.create_logger itself, which is what we wrap today (thalovant 0.6.7, transport.py).
Would you take either of these?
- An opt-out:
LOG.init(config={"deprecations": False}) / "logging": {"deprecations": false} in mycroft.conf, or OVOS_LOG_DEPRECATIONS=0, under which log_deprecation returns without logging.
- A fixed child logger for deprecations (
OVOS.deprecation, with the call site kept in the message as it is now) so a standard logging.Filter or level can be applied to it.
Either would let a client that has heard the deprecation, and cannot act on it, stop repeating it. Happy to send a PR for whichever you prefer.
Versions: ovos-utils 0.8.5, ovos-bus-client 2.11.7a1, Python 3.12.
ovos_utils.log.log_deprecationnames the logger it writes to after the call site:create_loggergives that logger its ownStreamHandlerand setspropagate = False. So every deprecation lands on a logger such asOVOS - ovos_bus_client.session:_normalize_location_input:87, one per call site, that no client can name in advance, and a filter on theOVOSlogger never sees it. There is no configuration or environment switch for deprecations either (checkedLOG.initand theloggingconfig keys in ovos-utils 0.8.5).Why it matters:
ovos-bus-client2.11 logs a deprecation every time it reads a session whoselocationis in the nestedcity/coordinate/timezoneshape. A hub whose ovos-core still serialises that shape (every stock install: ovos-config's defaultlocationis nested) makes every client log it on every message it receives. Measured on a HiveMind satellite: three lines per question, and three hundred in six minutes of connection probes. The client cannot change the hub's shape, so the only honest thing it can do is drop that one record β and the only place to catch it isLOG.create_loggeritself, which is what we wrap today (thalovant0.6.7,transport.py).Would you take either of these?
LOG.init(config={"deprecations": False})/"logging": {"deprecations": false}inmycroft.conf, orOVOS_LOG_DEPRECATIONS=0, under whichlog_deprecationreturns without logging.OVOS.deprecation, with the call site kept in the message as it is now) so a standardlogging.Filteror level can be applied to it.Either would let a client that has heard the deprecation, and cannot act on it, stop repeating it. Happy to send a PR for whichever you prefer.
Versions: ovos-utils 0.8.5, ovos-bus-client 2.11.7a1, Python 3.12.