Commit 6c4aca5
authored
chore: add benchmark npm script and stale embeddings warning (#604)
* chore: add benchmark npm script and stale embeddings warning
Add `npm run benchmark` script to make benchmark execution discoverable
instead of requiring manual `node --import ./scripts/ts-resolve-loader.js`
invocation.
Warn users when embeddings predate the last graph rebuild so they know
to re-run `codegraph embed` for fresh search results.
Impact: 1 functions changed, 8 affected
* fix: correct stale-embeddings off-by-one and simplify guards (#604)
- Move setBuildMeta before stale-embeddings check so built_at reflects
the current build, fixing the off-by-one where the warning fired one
rebuild cycle late
- Fix NaN-check order: validate embedTime before comparing
- Remove redundant embedTime < now guard (always true for real timestamps)
- Use single buildNow timestamp for both metadata and comparison
Impact: 1 functions changed, 8 affected1 parent ecc6f81 commit 6c4aca5
2 files changed
Lines changed: 42 additions & 15 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
| 46 | + | |
46 | 47 | | |
47 | 48 | | |
48 | 49 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
40 | 44 | | |
41 | 45 | | |
42 | 46 | | |
| |||
63 | 67 | | |
64 | 68 | | |
65 | 69 | | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
66 | 86 | | |
67 | 87 | | |
68 | 88 | | |
| |||
83 | 103 | | |
84 | 104 | | |
85 | 105 | | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
86 | 127 | | |
87 | 128 | | |
88 | 129 | | |
| |||
108 | 149 | | |
109 | 150 | | |
110 | 151 | | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | | - | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
121 | | - | |
122 | | - | |
123 | | - | |
124 | | - | |
125 | | - | |
126 | 152 | | |
127 | 153 | | |
128 | 154 | | |
| |||
0 commit comments