@prom.codes/memory-mcp 0.10.2 → 0.10.3

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.
Files changed (2) hide show
  1. package/dist/bin.js +12 -5
  2. package/package.json +1 -1
package/dist/bin.js CHANGED
@@ -3195,7 +3195,7 @@ ${f.value}`);
3195
3195
  // dist/server.js
3196
3196
  var SERVER_IDENTITY = {
3197
3197
  name: "prometheus-memory-mcp",
3198
- version: "0.10.2",
3198
+ version: "0.10.3",
3199
3199
  title: "prom.codes Memory"
3200
3200
  };
3201
3201
  var SERVER_INSTRUCTIONS = "Persistent agent memory for this workspace \u2014 USE IT PROACTIVELY; the user will not tell you to. Protocol:\n1. ONE-TIME: if this workspace has no Prometheus memory rule yet, call memory_setup now (idempotent) so the protocol is installed into the runtime rule files and survives future sessions. (The server also auto-installs it on startup when a project rule file already exists \u2014 memory_setup covers the rest.)\n2. SESSION START: before any non-trivial task, call memory_read to recall facts, decisions and procedures from earlier sessions.\n3. DURING WORK: when the user states a durable preference, decision, correction or project fact, store it with memory_write (semantic for facts, procedural for how-tos) \u2014 without being asked.\n4. LOOK-UP: use memory_search for keyword recall when memory_read is not specific enough.\n5. SESSION END: consolidate what was learned with memory_capture.\nCall memory_status anytime to check what is stored and whether the rule is installed. Never store secrets, API keys or credentials \u2014 such writes are rejected.";
@@ -3222,8 +3222,12 @@ async function main() {
3222
3222
  composedResolve = res;
3223
3223
  });
3224
3224
  registerTools(server, () => composedReady);
3225
- const shutdown = async (signal) => {
3226
- process.stderr.write(`prometheus-memory-mcp: received ${signal}, shutting down
3225
+ let shuttingDown = false;
3226
+ const shutdown = async (reason) => {
3227
+ if (shuttingDown)
3228
+ return;
3229
+ shuttingDown = true;
3230
+ process.stderr.write(`prometheus-memory-mcp: ${reason}, shutting down
3227
3231
  `);
3228
3232
  try {
3229
3233
  await server.close();
@@ -3233,8 +3237,11 @@ async function main() {
3233
3237
  process.exit(0);
3234
3238
  }
3235
3239
  };
3236
- process.once("SIGINT", shutdown);
3237
- process.once("SIGTERM", shutdown);
3240
+ process.once("SIGINT", () => void shutdown("received SIGINT"));
3241
+ process.once("SIGTERM", () => void shutdown("received SIGTERM"));
3242
+ process.stdin.once("end", () => void shutdown("stdin closed (client exited)"));
3243
+ process.stdin.once("close", () => void shutdown("stdin closed (client exited)"));
3244
+ server.server.onclose = () => void shutdown("transport closed (client exited)");
3238
3245
  const boot = (override, via) => {
3239
3246
  composed = composeFromEnv({
3240
3247
  env,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@prom.codes/memory-mcp",
3
- "version": "0.10.2",
3
+ "version": "0.10.3",
4
4
  "description": "prom.codes Memory — persistent, local-first agent memory as an MCP server.",
5
5
  "type": "module",
6
6
  "bin": {