context-mode 1.0.42 → 1.0.44

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.
@@ -5,8 +5,8 @@
5
5
  *
6
6
  * Kiro specifics:
7
7
  * - Hooks via agent config files (~/.kiro/agents/<name>.json)
8
- * - Config: ~/.kiro/settings/mcp_config.json (JSON format)
9
- * - MCP: full support via mcpServers in mcp_config.json
8
+ * - Config: ~/.kiro/settings/mcp.json (JSON format)
9
+ * - MCP: full support via mcpServers in mcp.json
10
10
  * - Hook exit codes: 0=allow, 2=block
11
11
  * - Cannot modify tool input (exit codes only)
12
12
  * - Session dir: ~/.kiro/context-mode/sessions/
@@ -5,8 +5,8 @@
5
5
  *
6
6
  * Kiro specifics:
7
7
  * - Hooks via agent config files (~/.kiro/agents/<name>.json)
8
- * - Config: ~/.kiro/settings/mcp_config.json (JSON format)
9
- * - MCP: full support via mcpServers in mcp_config.json
8
+ * - Config: ~/.kiro/settings/mcp.json (JSON format)
9
+ * - MCP: full support via mcpServers in mcp.json
10
10
  * - Hook exit codes: 0=allow, 2=block
11
11
  * - Cannot modify tool input (exit codes only)
12
12
  * - Session dir: ~/.kiro/context-mode/sessions/
@@ -93,7 +93,7 @@ export class KiroAdapter {
93
93
  }
94
94
  // ── Configuration ──────────────────────────────────────
95
95
  getSettingsPath() {
96
- return resolve(homedir(), ".kiro", "settings", "mcp_config.json");
96
+ return resolve(homedir(), ".kiro", "settings", "mcp.json");
97
97
  }
98
98
  getSessionDir() {
99
99
  const dir = join(homedir(), ".kiro", "context-mode", "sessions");
@@ -201,14 +201,14 @@ export class KiroAdapter {
201
201
  check: "MCP registration",
202
202
  status: "fail",
203
203
  message: "context-mode not found in mcpServers",
204
- fix: "Add context-mode to mcpServers in ~/.kiro/settings/mcp_config.json",
204
+ fix: "Add context-mode to mcpServers in ~/.kiro/settings/mcp.json",
205
205
  };
206
206
  }
207
207
  catch {
208
208
  return {
209
209
  check: "MCP registration",
210
210
  status: "warn",
211
- message: "Could not read ~/.kiro/settings/mcp_config.json",
211
+ message: "Could not read ~/.kiro/settings/mcp.json",
212
212
  };
213
213
  }
214
214
  }
@@ -281,7 +281,7 @@ export class KiroAdapter {
281
281
  return [];
282
282
  }
283
283
  updatePluginRegistry(_pluginRoot, _version) {
284
- // Kiro plugin registry is managed via mcp_config.json
284
+ // Kiro plugin registry is managed via mcp.json
285
285
  }
286
286
  // ── Routing Instructions (soft enforcement) ────────────
287
287
  getRoutingInstructionsConfig() {
package/build/db-base.js CHANGED
@@ -95,7 +95,13 @@ export function loadDatabase() {
95
95
  if (!_Database) {
96
96
  const require = createRequire(import.meta.url);
97
97
  try {
98
- _Database = require("better-sqlite3");
98
+ const mod = require("better-sqlite3");
99
+ // Bun's require("better-sqlite3") doesn't throw — returns undefined (#163).
100
+ // Validate the result is a usable constructor before assigning.
101
+ if (!mod || typeof mod !== "function") {
102
+ throw new Error("better-sqlite3 loaded but not usable (Bun compatibility issue)");
103
+ }
104
+ _Database = mod;
99
105
  }
100
106
  catch {
101
107
  // better-sqlite3 unavailable (Bun runtime) — wrap bun:sqlite