@velvetmonkey/flywheel-memory 2.5.3 → 2.5.5

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/index.js +12 -4
  2. package/package.json +2 -2
package/dist/index.js CHANGED
@@ -7672,8 +7672,10 @@ function normalizePath(filePath) {
7672
7672
  return normalized;
7673
7673
  }
7674
7674
  function getRelativePath(vaultPath2, filePath) {
7675
- const relative3 = path5.relative(vaultPath2, filePath);
7676
- return normalizePath(relative3);
7675
+ const normalizedVault = normalizePath(vaultPath2);
7676
+ const normalizedFile = normalizePath(filePath);
7677
+ const relative3 = path5.posix.relative(normalizedVault, normalizedFile);
7678
+ return relative3;
7677
7679
  }
7678
7680
  function shouldWatch(filePath, vaultPath2) {
7679
7681
  const normalized = normalizePath(filePath);
@@ -8106,11 +8108,13 @@ async function upsertNote(index, vaultPath2, notePath) {
8106
8108
  entityFieldChanged
8107
8109
  };
8108
8110
  } catch (error) {
8111
+ const err = error instanceof Error ? error : new Error(String(error));
8112
+ console.error(`[flywheel] upsertNote FAILED for ${notePath}: ${err.message}`);
8109
8113
  return {
8110
8114
  success: false,
8111
8115
  action: "unchanged",
8112
8116
  path: notePath,
8113
- error: error instanceof Error ? error : new Error(String(error))
8117
+ error: err
8114
8118
  };
8115
8119
  }
8116
8120
  }
@@ -9634,7 +9638,11 @@ var PipelineRunner = class {
9634
9638
  ...p.batch,
9635
9639
  events: p.events.map((e) => ({ ...e, path: path15.join(p.vp, e.path) }))
9636
9640
  };
9637
- const batchResult = await processBatch(vaultIndex2, p.vp, absoluteBatch);
9641
+ const batchResult = await processBatch(vaultIndex2, p.vp, absoluteBatch, {
9642
+ onError: (filePath, error) => {
9643
+ serverLog("watcher", `File processing error: ${filePath}: ${error.message}`, "error");
9644
+ }
9645
+ });
9638
9646
  this.hasEntityRelevantChanges = batchResult.hasEntityRelevantChanges;
9639
9647
  vaultIndex2.builtAt = /* @__PURE__ */ new Date();
9640
9648
  serverLog("watcher", `Incremental: ${batchResult.successful}/${batchResult.total} files in ${batchResult.durationMs}ms`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@velvetmonkey/flywheel-memory",
3
- "version": "2.5.3",
3
+ "version": "2.5.5",
4
4
  "description": "MCP tools that search, write, and auto-link your Obsidian vault — and learn from your edits.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -55,7 +55,7 @@
55
55
  "dependencies": {
56
56
  "@huggingface/transformers": "^3.8.1",
57
57
  "@modelcontextprotocol/sdk": "^1.25.1",
58
- "@velvetmonkey/vault-core": "^2.5.3",
58
+ "@velvetmonkey/vault-core": "^2.5.5",
59
59
  "better-sqlite3": "^12.0.0",
60
60
  "chokidar": "^4.0.0",
61
61
  "gray-matter": "^4.0.3",