chain-insights 0.43.0 → 0.43.1

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/README.md CHANGED
@@ -72,9 +72,21 @@ Insights Graph for the data.
72
72
  The plugin needs Node.js 22 or newer. Add this repository as a plugin
73
73
  marketplace, then install the `chain-insights` plugin from it.
74
74
 
75
- Without the plugin, `npm install -g chain-insights` then
76
- `cia setup claude-desktop` registers the installed proxy in Claude Desktop
77
- directly. Restart Claude Desktop afterwards.
75
+ Without the plugin, register the installed proxy in Claude Desktop directly:
76
+
77
+ 1. Quit Claude Desktop fully. Closing the window is not enough: it keeps
78
+ running and writes its settings file back, which can remove the new entry.
79
+ - macOS: Claude menu > Quit Claude (Cmd+Q).
80
+ - Windows: right-click the Claude icon in the taskbar tray > Quit.
81
+ - Linux: File menu > Quit, or the tray icon > Quit.
82
+ 2. Run `npm install -g chain-insights`, then `cia setup claude-desktop`.
83
+ It warns if Claude Desktop is still running.
84
+ 3. Start Claude Desktop. `chain-insights` shows under Settings > Developer.
85
+
86
+ The entry is written to `claude_desktop_config.json` under `mcpServers`:
87
+ `~/Library/Application Support/Claude` on macOS, `%APPDATA%\Claude` on
88
+ Windows, `~/.config/Claude` on Linux. A `.bak` copy of the previous file is
89
+ kept beside it.
78
90
 
79
91
  The plugin skills are copies of `skills/`. After editing a skill, run
80
92
  `node scripts/sync-plugin-skills.mjs`; a test fails while the copies differ.
package/bin/install.cjs CHANGED
@@ -318,8 +318,34 @@ function installClaudeDesktopMcp(configFile, proxyPath) {
318
318
  fs.writeFileSync(configFile, `${JSON.stringify(config, null, 2)}\n`, 'utf8')
319
319
  }
320
320
 
321
+ // Claude Desktop keeps its settings in the same file and writes the whole file
322
+ // back when it saves them, so an entry added while it runs can be lost.
323
+ function claudeDesktopRunning() {
324
+ const { spawnSync } = require('child_process')
325
+ try {
326
+ if (process.platform === 'win32') {
327
+ const out = spawnSync('tasklist', ['/FI', 'IMAGENAME eq Claude.exe', '/NH'], { encoding: 'utf8' })
328
+ return /claude\.exe/i.test(out.stdout || '')
329
+ }
330
+ const pgrepArgs = process.platform === 'darwin' ? ['-x', 'Claude'] : ['-f', '(^|/)claude-desktop( |$)']
331
+ return spawnSync('pgrep', pgrepArgs, { encoding: 'utf8' }).status === 0
332
+ } catch {
333
+ return false
334
+ }
335
+ }
336
+
337
+ function quitClaudeDesktopHint() {
338
+ if (process.platform === 'darwin') return 'Claude menu > Quit Claude (Cmd+Q)'
339
+ if (process.platform === 'win32') return 'right-click the Claude icon in the taskbar tray > Quit'
340
+ return 'File menu > Quit, or the tray icon > Quit'
341
+ }
342
+
321
343
  if (hasClaudeDesktop) {
322
344
  const desktopConfig = claudeDesktopConfigPath()
345
+ if (claudeDesktopRunning()) {
346
+ console.log(` ${bold}Claude Desktop is running.${reset} It can overwrite the new entry when it saves its own settings.`)
347
+ console.log(` Quit it fully (${quitClaudeDesktopHint()}), run ${cyan}cia setup claude-desktop${reset} again, then start Claude Desktop.`)
348
+ }
323
349
  try {
324
350
  installClaudeDesktopMcp(desktopConfig, proxyBinPath)
325
351
  console.log(` ${cyan}Claude Desktop MCP:${reset} registered in ${desktopConfig}`)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "chain-insights",
3
- "version": "0.43.0",
3
+ "version": "0.43.1",
4
4
  "description": "AML investigation CLI and MCP proxy for blockchain risk screening and Chain Insights Graph access",
5
5
  "homepage": "https://chain-insights.ai",
6
6
  "repository": {