feat(plugin): support enterprise extension#861
Conversation
- Updated scripts to generate extension bridges and added relevant files to .gitignore. - Modified package.json to include new scripts for generating extension bridges and adjusted build process. - Introduced marketplace provider interface in ClawHubService for better extension handling. - Added new API route for marketplace capability in skills routes. - Integrated extension loading in main and renderer processes, allowing for dynamic extension management. - Updated sidebar and app components to support additional routes and navigation items from extensions.
…ng for extension loading - Added a function to retrieve extension packages from a manifest file, improving the extension system's integration. - Updated the main process external module check to account for dynamic extensions. - Enhanced error handling in the extension loader to provide more informative logging when extensions fail to load.
- Added a step to generate the extension bridge in the CI workflow. - Refactored gateway health state initialization in the Channels component to use a constant for default values.
- Added a step to generate the extension bridge in the CI workflow. - Introduced a minimal mock for the Electron module in the test setup to prevent failures when the Electron binary is not present.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0a38a6c9e9
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| "build": "node scripts/generate-ext-bridge.mjs && vite build && zx scripts/bundle-openclaw.mjs && zx scripts/bundle-openclaw-plugins.mjs && zx scripts/bundle-preinstalled-skills.mjs && electron-builder", | ||
| "build:vite": "vite build", |
There was a problem hiding this comment.
Run ext-bridge for all Vite build entrypoints
This change makes both main and renderer import _ext-bridge.generated modules, but only the build script now guarantees generation. build:vite is still a raw vite build, and test:e2e/package flows rely on that path; from a clean checkout (where generated files are ignored), those commands can fail with module resolution errors before bundling. Please add bridge generation to every script that invokes Vite directly (or add prebuild:vite/prepackage hooks) so release and local build/test commands remain self-contained.
Useful? React with 👍 / 👎.
| useEffect(() => { | ||
| loadExternalRendererExtensions(); | ||
| void rendererExtensionRegistry.initializeAll(); | ||
| return () => rendererExtensionRegistry.teardownAll(); | ||
| }, []); |
There was a problem hiding this comment.
Trigger rerender after loading renderer extensions
loadExternalRendererExtensions() runs inside a mount effect, but no state is updated afterward, so extension routes/navigation registered there are absent on the first render and only appear if some unrelated store update happens later. This makes route availability timing-dependent (e.g., deep-linking to an extension route can render without a matching route initially). Consider loading extensions before initial render or toggling local state after registration to guarantee deterministic route/nav registration.
Useful? React with 👍 / 👎.
…ll-ai#861) Extension registry, loader, builtin extensions (diagnostics, marketplace), renderer-side extension routes, and extension bridge generator.
Summary
Refactor the project to support service-oriented and plugin-based configuration, and ensure compatibility with the enterprise version.
Related Issue(s)
Type of Change
Validation
Checklist