bare-agent 0.16.1 → 0.16.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.
@@ -1,7 +1,7 @@
1
1
  # bareagent — Integration Guide
2
2
 
3
3
  > For AI assistants and developers wiring bareagent into a project.
4
- > v0.16.1 | Node.js >= 18 | one required dep (`bareguard ^0.4.2`) | Apache 2.0
4
+ > v0.16.2 | Node.js >= 18 | one required dep (`bareguard ^0.4.2`) | Apache 2.0
5
5
  >
6
6
  > Full human guide with composition examples, design philosophy, and recipes: [Usage Guide](docs/02-features/usage-guide.md)
7
7
 
@@ -257,7 +257,9 @@ $HOME/IDE configs — NOT the project-cwd `./.mcp.json`** (v0.16.1): a checked-i
257
257
  config in an untrusted repo would otherwise auto-spawn arbitrary commands. To
258
258
  include the project config, pass `createMCPBridge({ includeProjectConfig: true })`,
259
259
  or a `confirmServer` hook (which implies it, since the hook vets every command).
260
- Explicitly-passed `configPaths` are honored verbatim. Pass `confirmServer(name,
260
+ Explicitly-passed `configPaths` are honored verbatim. So you're not left guessing,
261
+ discovery logs a one-line hint (v0.16.2) when a `./.mcp.json` is present but skipped —
262
+ naming the opt-in — rather than silently ignoring it. Pass `confirmServer(name,
261
263
  def) => boolean` to approve each server **before its command is spawned** (return
262
264
  `false` to skip it; a throw fails closed). When no `confirmServer` is set, the
263
265
  bridge still trusts all *discovered* servers and prints a one-time warning naming
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bare-agent",
3
- "version": "0.16.1",
3
+ "version": "0.16.2",
4
4
  "files": [
5
5
  "index.js",
6
6
  "index.d.ts",
package/src/mcp-bridge.js CHANGED
@@ -89,7 +89,17 @@ function discoverServers(configPaths, { includeProjectConfig = false } = {}) {
89
89
  paths = TRUSTED_CONFIG_PATHS.map(fn => fn());
90
90
  // Project config kept at highest precedence (front) when explicitly opted in — preserves the
91
91
  // historical "project overrides home" ordering for callers that want it.
92
- if (includeProjectConfig) paths.unshift(PROJECT_CONFIG_PATH());
92
+ if (includeProjectConfig) {
93
+ paths.unshift(PROJECT_CONFIG_PATH());
94
+ } else if (existsSync(PROJECT_CONFIG_PATH())) {
95
+ // Don't fail silently: a present-but-skipped project config is the common legitimate case
96
+ // (your own repo). Say so, and point at the opt-in — otherwise the servers just never appear
97
+ // and there's no on-screen reason why.
98
+ console.warn(
99
+ `[MCP Bridge] found ./.mcp.json but did not load it (untrusted-cwd default since v0.16.1). ` +
100
+ `Pass { includeProjectConfig: true } or a confirmServer hook to enable project-local servers.`,
101
+ );
102
+ }
93
103
  }
94
104
  /** @type {Map<string, ServerDef>} */
95
105
  const servers = new Map();