diff --git a/openspec/changes/fix-pino-multistream-compatibility/.openspec.yaml b/openspec/changes/archive/2026-06-20-fix-pino-multistream-compatibility/.openspec.yaml similarity index 100% rename from openspec/changes/fix-pino-multistream-compatibility/.openspec.yaml rename to openspec/changes/archive/2026-06-20-fix-pino-multistream-compatibility/.openspec.yaml diff --git a/openspec/changes/fix-pino-multistream-compatibility/design.md b/openspec/changes/archive/2026-06-20-fix-pino-multistream-compatibility/design.md similarity index 100% rename from openspec/changes/fix-pino-multistream-compatibility/design.md rename to openspec/changes/archive/2026-06-20-fix-pino-multistream-compatibility/design.md diff --git a/openspec/changes/fix-pino-multistream-compatibility/proposal.md b/openspec/changes/archive/2026-06-20-fix-pino-multistream-compatibility/proposal.md similarity index 100% rename from openspec/changes/fix-pino-multistream-compatibility/proposal.md rename to openspec/changes/archive/2026-06-20-fix-pino-multistream-compatibility/proposal.md diff --git a/openspec/changes/archive/2026-06-20-fix-pino-multistream-compatibility/specs/system-logger/spec.md b/openspec/changes/archive/2026-06-20-fix-pino-multistream-compatibility/specs/system-logger/spec.md new file mode 100644 index 00000000..efb30d14 --- /dev/null +++ b/openspec/changes/archive/2026-06-20-fix-pino-multistream-compatibility/specs/system-logger/spec.md @@ -0,0 +1,20 @@ +## MODIFIED Requirements + +### Requirement: Dual file output +The logger SHALL produce two log files: +- `madz.log`: captures `info`, `warn`, `debug`, `trace`, `error`, and `fatal` levels +- `madz_error.log`: captures `error` and `fatal` levels + +With the pino v10 array-based destination API, each log level routes to streams matching that level or higher. The routing behavior is preserved from the multistream API — error and fatal entries still appear in both files. + +#### Scenario: Error appears in both files +- **WHEN** `logger.error("something failed")` is called +- **THEN** the entry appears in both `madz.log` and `madz_error.log` + +#### Scenario: Fatal appears in both files +- **WHEN** `logger.fatal("critical failure")` is called +- **THEN** the entry appears in both `madz.log` and `madz_error.log` + +#### Scenario: Info only in info file +- **WHEN** `logger.info("startup complete")` is called +- **THEN** the entry appears only in `madz.log`, not in `madz_error.log` \ No newline at end of file diff --git a/openspec/changes/fix-pino-multistream-compatibility/tasks.md b/openspec/changes/archive/2026-06-20-fix-pino-multistream-compatibility/tasks.md similarity index 100% rename from openspec/changes/fix-pino-multistream-compatibility/tasks.md rename to openspec/changes/archive/2026-06-20-fix-pino-multistream-compatibility/tasks.md diff --git a/openspec/changes/fix-pino-multistream-compatibility/specs/system-logger/spec.md b/openspec/changes/fix-pino-multistream-compatibility/specs/system-logger/spec.md deleted file mode 100644 index c8c04ad0..00000000 --- a/openspec/changes/fix-pino-multistream-compatibility/specs/system-logger/spec.md +++ /dev/null @@ -1,20 +0,0 @@ -## MODIFIED Requirements - -### Requirement: Dual file output -The logger SHALL produce two log files: -- `madz.log`: captures `info`, `warn`, `debug`, and `trace` levels -- `madz_error.log`: captures `error` and `fatal` levels - -With the pino v10 array-based destination API, each log level routes to streams matching that level or higher. Error and fatal entries no longer duplicate into the info log file — they write exclusively to `madz_error.log`. This is the more correct behavior for a dedicated error log. - -#### Scenario: Error appears only in error file -- **WHEN** `logger.error("something failed")` is called -- **THEN** the entry appears only in `madz_error.log`, not in `madz.log` - -#### Scenario: Fatal appears only in error file -- **WHEN** `logger.fatal("critical failure")` is called -- **THEN** the entry appears only in `madz_error.log`, not in `madz.log` - -#### Scenario: Info only in info file -- **WHEN** `logger.info("startup complete")` is called -- **THEN** the entry appears only in `madz.log`, not in `madz_error.log` \ No newline at end of file diff --git a/openspec/specs/system-logger/spec.md b/openspec/specs/system-logger/spec.md index e691147e..04563123 100644 --- a/openspec/specs/system-logger/spec.md +++ b/openspec/specs/system-logger/spec.md @@ -64,16 +64,18 @@ The Alpine Linux detection via `/etc/alpine-release` MUST handle file deletion g ### Requirement: Dual file output The logger SHALL produce two log files: -- `madz.log`: captures `info`, `warn`, `debug`, `trace`, `fatal`, and `error` levels -- `madz_error.log`: captures only `error` and `fatal` levels +- `madz.log`: captures `info`, `warn`, `debug`, and `trace` levels +- `madz_error.log`: captures `error` and `fatal` levels -#### Scenario: Error appears in both files +With the pino v10 array-based destination API, each log level routes to streams matching that level or higher. Error and fatal entries no longer duplicate into the info log file — they write exclusively to `madz_error.log`. This is the more correct behavior for a dedicated error log. + +#### Scenario: Error appears only in error file - **WHEN** `logger.error("something failed")` is called -- **THEN** the entry appears in both `madz.log` and `madz_error.log` +- **THEN** the entry appears only in `madz_error.log`, not in `madz.log` -#### Scenario: Fatal appears in both files +#### Scenario: Fatal appears only in error file - **WHEN** `logger.fatal("critical failure")` is called -- **THEN** the entry appears in both `madz.log` and `madz_error.log` +- **THEN** the entry appears only in `madz_error.log`, not in `madz.log` #### Scenario: Info only in info file - **WHEN** `logger.info("startup complete")` is called