@lujoai/lujo-mcp 0.7.0 → 0.7.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bin/check.js CHANGED
@@ -73,7 +73,9 @@ if (exe) {
73
73
  }
74
74
 
75
75
  if (mismatches.length) {
76
- console.error(`[lujo-mcp-server] platform package '${pkg}' was found but its version does not match the meta package @${metaV}:`);
76
+ // FIX(v0.7.1-b7-2): 报错文案——此前 "@${metaV}" 拼成 "@0.7.0" 形似残缺的
77
+ // scoped 包名,误导排查;改为完整 scoped 引用 @lujoai/lujo-mcp@版本。
78
+ console.error(`[lujo-mcp-server] platform package '${pkg}' was found but its version does not match the meta package @lujoai/lujo-mcp@${metaV}:`);
77
79
  for (const m of mismatches) console.error(` - ${m}`);
78
80
  console.error('');
79
81
  console.error('The install is corrupt or version-mismatched. Reinstall to fix:');
package/bin/cli.js CHANGED
@@ -25,7 +25,14 @@ function binaryInDir(pkgDir, pkg, binFile) {
25
25
  // Fall back to reading the platform package's package.json bin field.
26
26
  const metaPath = path.join(pkgDir, 'package.json');
27
27
  if (fs.existsSync(metaPath)) {
28
- const meta = JSON.parse(fs.readFileSync(metaPath, 'utf8'));
28
+ // FIX(v0.7.1-b5-2): 平台包 package.json 损坏时 JSON.parse 抛异常会直接崩掉
29
+ // 启动器;降级为读不到 bin 字段(与文件不存在同语义),交给上层统一报错。
30
+ let meta;
31
+ try {
32
+ meta = JSON.parse(fs.readFileSync(metaPath, 'utf8'));
33
+ } catch {
34
+ meta = null;
35
+ }
29
36
  if (meta && meta.bin) {
30
37
  const binTarget = typeof meta.bin === 'string' ? meta.bin : meta.bin['lujo-mcp-server'] || meta.bin[pkg];
31
38
  if (binTarget) {