engine: the plugin host exists even when no plugin is configured

The host is what carries the registry to the core compactor. A plugin-less
run had none, so a conversation over max_bytes was refused instead of
compacted - the compaction that would have saved it could not be reached.
The fix landed in f712088; this is the check that keeps it.
This commit is contained in:
lotherk committed 2026-11-21 21:27:25 +00:00
1 parent fa16bfd0a9
commit 678e2814e6
2 files changed
+9 -1

No files matched your search

+1 -1
View File
@@ -3097,7 +3097,7 @@ load_plugins(struct sp_engine *e, const struct sp_engine_opts *o,
/*
* The host is created even without a single plugin: it is what carries
* the registry to the core compactor and the gate to the tools. Skiping
* the registry to the core compactor and the gate to the tools. Skipping
* it here left a plugin-less run with no compactor at all, so max_bytes
* killed every turn whose conversation was over the ceiling - the
* compaction that was supposed to save it could not be reached.
+8
View File
@@ -197,6 +197,14 @@ main(void)
fprintf(stderr, "engine: %s\n", err.p != NULL ? err.p : "?");
return 1;
}
/*
* The host exists even with no plugin configured. It is what carries the
* registry to the core compactor; without it a plugin-less run had no
* compactor at all and every conversation over max_bytes was refused
* instead of compacted (seen 2026-11-21 on a 90 KB session, budget
* 8000, "nothing sent").
*/
CHECK(sp_engine_host(eng) != NULL);
/*
* The prompt knows this directory has history and says how to read it;
* the default prompt tells the model to use the knowledge tools (tasks,