Commit 2bcafc8
* fix(local-plugin): call initLogger in bootstrapMemoryCoreFull
`bootstrapMemoryCoreFull` in `apps/memos-local-plugin/core/pipeline/memory-core.ts`
never invoked `initLogger(config, home)` after `loadConfig(home)`. The logger
stayed in the `bootstrapConsoleOnly()` fallback (console + memory buffer +
SSE broadcast only), so the `FileRotatingTransport` / `JsonlEventsTransport`
sinks were never wired and `MEMOS_HOME/logs/` (memos.log, error.log,
audit.log, llm.jsonl, perf.jsonl, events.jsonl) was left empty even though
`config.logging.file.enabled` defaults to true.
The fix adds `initLogger` to the logger import and calls it after the config
is resolved and before the first `rootLogger.child(...)` call. `initLogger`
is idempotent and swaps the active root in place, so existing child handles
keep working.
A new regression test `tests/unit/pipeline/bootstrap-init-logger.test.ts`
boots the pipeline against a tmp home, emits a marker line, and asserts
that `memos.log` is created on disk and contains the marker. It fails on
the previous code (ENOENT for memos.log) and passes with this fix.
Fixes #2147
* style(hermes): format daemon manager
---------
Co-authored-by: MemOS AutoDev <autodev@memtensor.local>
Co-authored-by: jiachengzhen <jiacz@memtensor.cn>
1 parent 44fc2b5 commit 2bcafc8
2 files changed
Lines changed: 74 additions & 1 deletion
File tree
- apps/memos-local-plugin
- adapters/hermes/memos_provider
- tests/unit/pipeline
Lines changed: 0 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
215 | 215 | | |
216 | 216 | | |
217 | 217 | | |
218 | | - | |
219 | 218 | | |
220 | 219 | | |
221 | 220 | | |
| |||
Lines changed: 74 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
0 commit comments