mirror of
https://github.com/openclaw/openclaw.git
synced 2026-08-02 07:01:34 +00:00
fix(release): scope dependency conflicts to bundled plugins (#113350)
This commit is contained in:
committed by
GitHub
parent
e430a1beb2
commit
4e9cba2aba
@@ -50,6 +50,11 @@ export function collectBundledPluginPackageDependencySpecs(bundledPluginsDir) {
|
||||
|
||||
for (const packageJsonPath of packageJsonPaths) {
|
||||
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, "utf8"));
|
||||
// External official plugins own isolated npm projects, so their dependency
|
||||
// specs do not need to match packages bundled into the root distribution.
|
||||
if (packageJson.openclaw?.build?.bundledDist === false) {
|
||||
continue;
|
||||
}
|
||||
const pluginId = path.basename(path.dirname(packageJsonPath));
|
||||
for (const [name, spec] of collectRuntimeDependencySpecs(packageJson)) {
|
||||
const existing = specs.get(name);
|
||||
|
||||
@@ -74,6 +74,16 @@ describe("scripts/lib/plugin-package-dependencies.mjs", () => {
|
||||
shared: "^1.1.0",
|
||||
},
|
||||
});
|
||||
writePackageJson(root, "external", {
|
||||
dependencies: {
|
||||
shared: "^9.0.0",
|
||||
},
|
||||
openclaw: {
|
||||
build: {
|
||||
bundledDist: false,
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
expect([...collectBundledPluginPackageDependencySpecs(root)]).toEqual([
|
||||
[
|
||||
|
||||
Reference in New Issue
Block a user