fix(cron): make skip_memory configurable via config.yaml (salvage of #9825 by @nightq) - #52897
fix(cron): make skip_memory configurable via config.yaml (salvage of #9825 by @nightq)#52897Bartok9 wants to merge 2 commits into
Conversation
|
Plate-clear rebase (2026-07-11)
|
3702f26 to
bab4eec
Compare
|
Correction rebase — previous automated conflict resolution incorrectly dropped large upstream sections (took entire feature-side file). Rebuilt from original patch intent onto current |
bab4eec to
d08c4bf
Compare
|
Production + tests re-applied cleanly on current main (prior rebuild dropped source hunks). Diff should be small and intentional again. |
d08c4bf to
d5ee850
Compare
|
Clean re-apply: source helper + skip_memory=_resolve_cron_skip_memory(_cfg) + tests; removed accidental .rej files from prior automated mess. |
d5ee850 to
75dc0be
Compare
|
Thanks for salvaging the original report. The current-main premise is real: Problems
Suggested changes
Automated hermes-sweeper review. |
|
Thanks — the memory-scope concern is the right gate to close before merge. You're correct that
Will push the revised version rather than merge as-is. |
Follow-up: provider-only scope (per teknium review)Addressed the merge gate without a blanket memory opt-in:
Ready for re-review / merge when convenient. Credit remains with #9825/@nightq for the original premise. |
…ousResearch#9825 by @nightq) Rebuilt on latest main (Bartok9 hygiene 2026-08-01). Original: NousResearch#52897
|
Rebuilt onto latest — Bartok9 public PR hygiene 2026-08-01 |
de63235 to
1866cfd
Compare
…tok9 Per-PR attribution so check-attribution passes on this branch (Teknium).
Summary
Salvage of #9825 by @nightq — rebased onto current
origin/main. Closes #9763.Cron jobs hardcode
skip_memory=Truewhen constructing the agent, so external memory providers (e.g. mem0) are unusable from cron — there's no way to opt in.Root Cause
Symptom — A user who wants their cron jobs to read/write an external memory provider (mem0, Honcho, etc.) can't: cron always passes
skip_memory=Trueregardless of config.Root cause — In
run_job(cron/scheduler.py), theAIAgent(...)construction setsskip_memory=Trueliterally, with a comment that cron system prompts would corrupt user representations. That's a sensible default, but it's wired as an unconditional constant — there's no config knob.Evidence — The added tests exercise
_resolve_cron_skip_memory, the new resolver that feeds the kwarg; without the fix the symbol doesn't exist and the value was a hardcoded constant.Fix + why this level — Read
cron.skip_memoryfrom config.yaml, defaulting toTrue(backward compatible). I centralized the resolution into_resolve_cron_skip_memory(cfg)rather than inliningcfg.get(...), so the behavior is unit-testable at a real seam (the original PR only asserted dict semantics in isolation, which couldn't fail without the source change). This is the correct level — one resolver feeds the single cron agent construction; the default preserves the "don't corrupt user representations" intent while letting power users opt in.Scope / risk — One helper + one wired kwarg. Default behavior is unchanged (still
Truewhen unset/cronsection missing/non-dict). Onlycron.skip_memory: falsechanges behavior, which is exactly the opt-in this enables.Changes from original
_resolve_cron_skip_memory(a genuine test seam) and replaced the original's tautological dict-semantics tests with tests that import and exercise the real resolver — they fail without the fix (ImportError / hardcoded constant).Verification
Real behavior proof
Credit: salvage of #9825 by @nightq — rebased onto current main with guardrail tests.