MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / insertUnresolvedRef

Method insertUnresolvedRef

src/db/queries.ts:4799–4817  ·  view source on GitHub ↗

* Insert an unresolved reference

(ref: UnresolvedReference)

Source from the content-addressed store, hash-verified

4797 * Insert an unresolved reference
4798 */
4799 insertUnresolvedRef(ref: UnresolvedReference): void {
4800 if (!this.stmts.insertUnresolved) {
4801 this.stmts.insertUnresolved = this.db.prepare(`
4802 INSERT INTO unresolved_refs (from_node_id, reference_name, reference_kind, line, col, candidates, file_path, language)
4803 VALUES (@fromNodeId, @referenceName, @referenceKind, @line, @col, @candidates, @filePath, @language)
4804 `);
4805 }
4806
4807 this.stmts.insertUnresolved.run({
4808 fromNodeId: ref.fromNodeId,
4809 referenceName: ref.referenceName,
4810 referenceKind: ref.referenceKind,
4811 line: ref.line,
4812 col: ref.column,
4813 candidates: ref.candidates ? JSON.stringify(ref.candidates) : null,
4814 filePath: ref.filePath ?? '',
4815 language: ref.language ?? 'unknown',
4816 });
4817 }
4818
4819 /**
4820 * Insert multiple unresolved references in a transaction

Callers 9

fixtureFunction · 0.95
fixtureFunction · 0.95
fixtureFunction · 0.95
fixtureFunction · 0.95
fixtureFunction · 0.95
cli-sync.test.tsFile · 0.80
failedFunction · 0.80
sync.test.tsFile · 0.80

Calls 2

prepareMethod · 0.65
runMethod · 0.65

Tested by 6

fixtureFunction · 0.76
fixtureFunction · 0.76
fixtureFunction · 0.76
fixtureFunction · 0.76
fixtureFunction · 0.76
failedFunction · 0.64