config_issues.py 559 B

123456789101112131415161718
  1. """The issue record config validation emits (``hermes config check``, doctor, startup warnings).
  2. Its own module so the facade (``hermes_cli.config``) and its check siblings share it without
  3. a facade import from the siblings."""
  4. from dataclasses import dataclass
  5. @dataclass
  6. class ConfigIssue:
  7. """A detected config structure problem."""
  8. severity: str # "error", "warning"
  9. message: str
  10. hint: str
  11. def _issue(issues: list[ConfigIssue], severity: str, message: str, hint: str) -> None:
  12. issues.append(ConfigIssue(severity, message, hint))