Skip to content

chore(dreaming): commit bench-reflective-dreaming bundler stub#15

Merged
LightDriverCS merged 2 commits into
mainfrom
chore/dreaming-bundler-stub
Apr 28, 2026
Merged

chore(dreaming): commit bench-reflective-dreaming bundler stub#15
LightDriverCS merged 2 commits into
mainfrom
chore/dreaming-bundler-stub

Conversation

@LightDriverCS
Copy link
Copy Markdown

@LightDriverCS LightDriverCS commented Apr 28, 2026

Summary

Commits the 6-line extensions/bench-reflective-dreaming/index.ts bundler stub that's been sitting untracked since 2026-04-20.

Why

The bench-reflective-dreaming plugin is runtime: "scripts" (real behavior in scripts/install.mjs + scripts/uninstall.mjs), but the tsdown bundler defaults to ./index.ts when a manifested plugin has no package.json. The stub should have shipped with #1 (the dreaming + claude-code-bridge feature PR) or #4 (the fleet-canon prompt fix) but was missed.

Why a real export instead of export {}

oxlint's unicorn/require-module-specifiers rule rejects export {} ("Empty export specifier is not allowed"). export const PLUGIN_RUNTIME = "scripts" as const; keeps the stub a real module without changing runtime behavior.

Test plan

  • Pre-commit hooks green (tsgo + oxlint + madge + import cycles)

🤖 Generated with Claude Code

Anvil Handoff

  • Hammer summary: Commits the 6-line extensions/bench-reflective-dreaming/index.ts bundler stub (untracked since 2026-04-20). Should have shipped with feat(extensions): bench-reflective-dreaming + claude-code-bridge #1 or fix(dreaming): fleet-canon emits openclaw-required frontmatter #4. Initially export {}; but oxlint rejected; ships as export const PLUGIN_RUNTIME = "scripts" as const;. Independent of the Phase D2.1 stack.
  • Primary paths changed: extensions/bench-reflective-dreaming/index.ts (new)
  • Verification run: Pre-commit green (tsgo + oxlint + madge + import-cycle).
  • Known risks: PLUGIN_RUNTIME constant is unreferenced — future tightening of unused-export rules could trip again. Bundler still needs index.ts to exist for tsdown discovery.
  • Suggested Anvil focus: Run the openclaw bundle (pnpm build or equivalent) and confirm tsdown actually emits the dreaming plugin. Compare against other runtime: "scripts" plugins for the canonical stub pattern.

Cory Shelton and others added 2 commits April 28, 2026 01:16
The bench-reflective-dreaming plugin is `runtime: "scripts"` (real
behavior in scripts/install.mjs + scripts/uninstall.mjs), but the
tsdown bundler defaults to ./index.ts when a manifested plugin has
no package.json. This commits the minimal stub that's been sitting
untracked since 2026-04-20 — should have shipped with PR #1 / #4.

The export keeps the stub a real module (oxlint's
`unicorn/require-module-specifiers` rejects `export {}`).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Surfaced by Codex Anvil (PR #15 smoke 20260428T074754Z): the bare
`export const PLUGIN_RUNTIME` satisfied tsdown but didn't satisfy the
OpenClaw plugin loader contract — `src/plugins/loader.ts` rejects
modules without `register` or `activate`. If the plugin were ever
explicitly enabled, the loader would fail.

Replaces the bare constant with a no-op `definePluginEntry`. Real
behavior still lives in `scripts/install.mjs` + `scripts/uninstall.mjs`
(scripts-runtime plugin); the no-op `register()` keeps the loader
happy without registering anything at import time.

Verified by Codex: explicit-enabled load returns `status: "loaded"`,
`pnpm build` emits `dist/extensions/bench-reflective-dreaming/index.js`,
all bundled-plugin tests pass.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@LightDriverCS LightDriverCS merged commit 88e122d into main Apr 28, 2026
4 of 11 checks passed
@LightDriverCS LightDriverCS deleted the chore/dreaming-bundler-stub branch April 28, 2026 08:24
LightDriverCS added a commit that referenced this pull request Apr 28, 2026
…with Anvil repair) (#16)

Indexes the canon/ directory as a first-class memory-wiki page kind. Without this, daily canon roll-ups written by reflective-dreaming agents were invisible to wiki.search / wiki.get / wiki.status / compile pipeline.

Includes Codex Anvil 5.5 xhigh repair (verdict REPAIR → applied):
- Vault init now creates canon/ (was crashing compileMemoryWikiVault with ENOENT)
- Status text + root-index count include canon
- wiki repair scans canon for structure consistency
- Regression tests across 7 test files

Supersedes #10. Rebased onto post-#15 main so pnpm build clears.

🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant