@sdsrs/code-graph 0.82.0 → 0.83.0

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
@@ -7,7 +7,7 @@ A high-performance code knowledge graph server implementing the [Model Context P
7
7
  - **Multi-language parsing** — Tree-sitter AST extraction across tiers of depth:
8
8
  - **Full** (calls + imports + inheritance + HTTP routes + test markers): TypeScript/TSX, JavaScript, Go, Python, Rust, Java
9
9
  - **Smoke-tested** (calls + imports + inheritance): C#, Kotlin, Ruby, PHP, Swift, Dart
10
- - **Limited** (functions + calls + `#include` imports + gtest test markers; `Class::method` scope qualification deferred): C, C++
10
+ - **Limited** (functions + calls + `#include` imports + gtest test markers + C++ base-class inheritance; `Class::method` scope qualification deferred): C, C++
11
11
  - **Scripting**: Bash (functions + commands + `source`/`.` imports), Markdown (headings)
12
12
  - **File-FTS only** (no AST symbol extraction): HTML, CSS, JSON
13
13
  - **Semantic code search** — Hybrid BM25 full-text + vector semantic search with Reciprocal Rank Fusion (RRF), powered by sqlite-vec
@@ -301,7 +301,7 @@ Available when installed as a Claude Code plugin:
301
301
  |----------|-----------|-------------------|
302
302
  | TypeScript | .ts, .tsx | calls, imports, exports, inherits, implements, routes_to |
303
303
  | JavaScript | .js, .jsx, .mjs, .cjs | calls, imports, exports, inherits, routes_to |
304
- | Go | .go | calls, imports, routes_to |
304
+ | Go | .go | calls, imports, inherits, routes_to |
305
305
  | Python | .py, .pyi | calls, imports, inherits, routes_to |
306
306
  | Rust | .rs | calls, imports, inherits, implements |
307
307
  | Java | .java | calls, imports, inherits, implements |
@@ -310,7 +310,7 @@ Available when installed as a Claude Code plugin:
310
310
  | Ruby | .rb | calls, imports, inherits |
311
311
  | PHP | .php | calls, imports, inherits, implements |
312
312
  | Swift | .swift | calls, imports, inherits |
313
- | Dart | .dart | calls, imports, implements |
313
+ | Dart | .dart | calls, imports, inherits, implements |
314
314
  | C | .c, .h | calls, imports |
315
315
  | C++ | .cpp, .cc, .cxx, .hpp | calls, imports, inherits |
316
316
  | HTML | .html, .htm | structural parsing |
@@ -4,7 +4,7 @@
4
4
  "author": {
5
5
  "name": "sdsrs"
6
6
  },
7
- "version": "0.82.0",
7
+ "version": "0.83.0",
8
8
  "keywords": [
9
9
  "code-graph",
10
10
  "ast",
@@ -285,7 +285,7 @@ function runDiagnostics() {
285
285
 
286
286
  const STATUS_ICONS = { ok: '\u2705', warn: '\u26a0\ufe0f', error: '\u274c', skip: '\u2796' };
287
287
 
288
- function formatReport(results) {
288
+ function formatReport(results, { checkOnly = false } = {}) {
289
289
  const pluginVersion = getPluginVersion();
290
290
  const lines = [`\ud83d\udd0d code-graph doctor v${pluginVersion}`, ''];
291
291
 
@@ -302,7 +302,15 @@ function formatReport(results) {
302
302
  lines.push(' All checks passed.');
303
303
  } else {
304
304
  const fixable = issues.filter(r => r.fixId);
305
- lines.push(` ${issues.length} issue(s) found.${fixable.length > 0 ? ' Fixing...' : ''}`);
305
+ // `--check-only` is read-only (it never reaches runRepairs), so it must not
306
+ // claim "Fixing..." — that contradicts the documented contract and alarms
307
+ // the user into thinking their settings.json/MEMORY.md was just rewritten.
308
+ const suffix = fixable.length === 0
309
+ ? ''
310
+ : checkOnly
311
+ ? ' Run without --check-only to fix.'
312
+ : ' Fixing...';
313
+ lines.push(` ${issues.length} issue(s) found.${suffix}`);
306
314
  }
307
315
 
308
316
  return lines.join('\n');
@@ -526,7 +534,7 @@ function runRepairs(results) {
526
534
 
527
535
  function runDoctor(opts = {}) {
528
536
  const results = runDiagnostics();
529
- console.log(formatReport(results));
537
+ console.log(formatReport(results, { checkOnly: opts.checkOnly }));
530
538
 
531
539
  const issues = results.filter(r => r.status === 'warn' || r.status === 'error');
532
540
 
@@ -48,6 +48,22 @@ test('formatReport shows issue count when problems exist', () => {
48
48
  assert.ok(output.includes('issue'));
49
49
  });
50
50
 
51
+ test('formatReport: --check-only never says "Fixing..." (it does not repair)', () => {
52
+ const results = [
53
+ { name: 'Hook coverage', status: 'warn', detail: 'missing', fixId: 'hooks' },
54
+ ];
55
+ // Default (repair mode) announces the fix.
56
+ assert.ok(formatReport(results).includes('Fixing...'),
57
+ 'repair mode should announce Fixing...');
58
+ // --check-only is read-only: it must NOT claim to fix, and should point the
59
+ // user at the repair command instead.
60
+ const checkOnly = formatReport(results, { checkOnly: true });
61
+ assert.ok(!checkOnly.includes('Fixing...'),
62
+ `--check-only must not say "Fixing..."; got: ${checkOnly}`);
63
+ assert.ok(checkOnly.includes('--check-only'),
64
+ `--check-only should hint how to fix; got: ${checkOnly}`);
65
+ });
66
+
51
67
  test('formatReport shows all-clear when no problems', () => {
52
68
  const results = [
53
69
  { name: 'Binary version', status: 'ok', detail: 'v0.7.16' },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sdsrs/code-graph",
3
- "version": "0.82.0",
3
+ "version": "0.83.0",
4
4
  "description": "MCP server that indexes codebases into an AST knowledge graph with semantic search, call graph traversal, and HTTP route tracing",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -35,10 +35,10 @@
35
35
  "node": ">=16"
36
36
  },
37
37
  "optionalDependencies": {
38
- "@sdsrs/code-graph-linux-x64": "0.82.0",
39
- "@sdsrs/code-graph-linux-arm64": "0.82.0",
40
- "@sdsrs/code-graph-darwin-x64": "0.82.0",
41
- "@sdsrs/code-graph-darwin-arm64": "0.82.0",
42
- "@sdsrs/code-graph-win32-x64": "0.82.0"
38
+ "@sdsrs/code-graph-linux-x64": "0.83.0",
39
+ "@sdsrs/code-graph-linux-arm64": "0.83.0",
40
+ "@sdsrs/code-graph-darwin-x64": "0.83.0",
41
+ "@sdsrs/code-graph-darwin-arm64": "0.83.0",
42
+ "@sdsrs/code-graph-win32-x64": "0.83.0"
43
43
  }
44
44
  }