Description
discover_plugins() exceptions are caught and logged at DEBUG level in two places, both invisible at the default INFO log level (config.yaml logging.level: INFO). If ANY plugin import fails at startup — syntax error, missing dependency, import cycle — the operator gets zero indication unless they bump log level to DEBUG.
Affected locations
1. Gateway startup — gateway/run.py line 3477
try:
from hermes_cli.plugins import discover_plugins
discover_plugins()
except Exception:
logger.debug(
"plugin discovery failed at gateway startup", exc_info=True,
)
2. CLI startup — hermes_cli/main.py line 12502
try:
from hermes_cli.plugins import discover_plugins
discover_plugins()
except Exception:
logger.debug(
"plugin discovery failed at CLI startup",
exc_info=True,
)
Reproduce
- Install a broken plugin (e.g., one with a syntax error in
__init__.py)
- Restart gateway or CLI with default
logging.level: INFO
- Observe: no error in agent.log, gateway.log, errors.log, or stderr
- Set
HERMES_PLUGINS_DEBUG=1 or bump log level to DEBUG → error appears
Expected behavior
logger.warning(...) — so the failure is visible at default INFO level. Plugin discovery failures should never be silent at production log levels.
Impact
Operators can deploy broken plugins and not know they failed to load. The plugin appears enabled in config but silently does nothing. Diagnosing requires either setting HERMES_PLUGINS_DEBUG=1 (undocumented for most users) or editing config to raise log level.
Suggested fix
Change logger.debug(...) → logger.warning(...) in both locations.
Description
discover_plugins()exceptions are caught and logged atDEBUGlevel in two places, both invisible at the defaultINFOlog level (config.yamllogging.level: INFO). If ANY plugin import fails at startup — syntax error, missing dependency, import cycle — the operator gets zero indication unless they bump log level to DEBUG.Affected locations
1. Gateway startup —
gateway/run.pyline 34772. CLI startup —
hermes_cli/main.pyline 12502Reproduce
__init__.py)logging.level: INFOHERMES_PLUGINS_DEBUG=1or bump log level to DEBUG → error appearsExpected behavior
logger.warning(...)— so the failure is visible at default INFO level. Plugin discovery failures should never be silent at production log levels.Impact
Operators can deploy broken plugins and not know they failed to load. The plugin appears enabled in config but silently does nothing. Diagnosing requires either setting
HERMES_PLUGINS_DEBUG=1(undocumented for most users) or editing config to raise log level.Suggested fix
Change
logger.debug(...)→logger.warning(...)in both locations.