mirror of
https://github.com/deepseek-ai/deepseek-harness
synced 2026-08-15 21:04:50 +00:00
Master's transactional loader made the invalid-provider PTY case regress: the HMR main watcher's initial scan refreshed the include mid-initial-apply, the concurrent group updates stranded the include fiber, and once serialized the failing apply's rollback deadlocked on HMR's refresh drain — dsh exited 13 with no diagnostic and the terminal stranded, the exact symptom this branch fixes. Serialize every include child-tree mutation through one queue and pass ignoreInitial to the HMR main watcher; the failing boot now settles through boot()'s labelled rejection with the tree disposed and exit 1. The PTY case asserts the settled diagnostic; the fail-loud release remains the guard for rejections boot cannot see.
@cordisjs/plugin-include
File-backed loader tree for Cordis. The include plugin reads a YAML or JSON file, turns it into loader entries, and writes updates back when the file is writable.
Usage
import { Context } from 'cordis'
import Loader from '@cordisjs/plugin-loader'
import Include from '@cordisjs/plugin-include'
const root = new Context()
await root.plugin(Loader, { baseUrl: import.meta.url })
await root.plugin(Include, {
path: './cordis.yml',
initial: [],
enableLogs: true,
})
Example cordis.yml:
- id: timer
name: '@cordisjs/plugin-timer'
- id: app
name: ./plugins/app
config:
message: hello
Config
| Field | Description |
|---|---|
path |
YAML or JSON file path resolved from ctx.baseUrl. |
initial |
Entry list written when the file is missing. |
patches |
Runtime patches applied after reading the file. |
enableLogs |
Enables loader apply, reload, and unload logs. |
Patches can insert entries or override fields on entries with a matching id.