feat(graph): add Godot edge subkind, impact target/verify-plan, orphan confidence#88
Merged
Merged
Conversation
…n confidence Surface six audit-CLI consumability improvements for Godot projects. Batch 1 (golden-neutral, CLI-only): - audit --impact: echo the changed path as `target` on every affected row, and emit a boundary `note` when impact is empty for a Godot resource/script path (data-driven numeric-id / DSL refs are not followed statically). - audit --orphans: add static `reason`/`confidence`/`note` (confidence "low" for Godot resource/scene files, else "high"). - audit --verify-plan: derive a load/open plan (loadScripts/openScenes/reasons) from the impact result. Batch 2 (deliberate schema v5->v6 + golden bump): - New structural ReferenceSubkind enum (script_attach, scene_instance, ext_resource, group_member, signal_method, gdscript_load_path) threaded RefView -> UnresolvedRef -> store -> resolver edge.metadata.subkind -> resource_impact edgeSubkind. GdscriptLoadPath is reserved (no emit site yet). - New nullable unresolved_refs.reference_subkind column (added LAST), forward idempotent migration, single named-access read mapper. - Canonicalize omits the key when NULL so existing rows stay byte-identical; the only golden delta is the .schema column add (+ schema_versions v6). EdgeKind is unchanged; subkind is orthogonal metadata. No domain semantics.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Six CLI/static-graph improvements from the v0.18.0 Godot feedback:
target— everyaudit --impact --jsonaffected row now echoes the changed path astarget.edgeSubkind— a new STRUCTURAL label (not a domain label) distinguishing the otherwise-opaquereferences/instantiatesedges a.tscn/.tresparser emits:script_attach,scene_instance,ext_resource,group_member,signal_method(and a reservedgdscript_load_path, deferred — no emit site today). Rides a new nullableunresolved_refs.reference_subkindcolumn +edge.metadata.subkind, mirroring the existingfnRefchannel.EdgeKindis NOT extended.audit --orphansrows gainreason/confidence/note; godot resources/scenes are flaggedconfidence: "low"with a data-driven caveat (they may be referenced by numeric ids / DSL paths static analysis doesn't follow).--verify-plan—audit --impact X --verify-planderives a static verification plan (loadScripts/openScenes/reasons) for Codex/CI/Godot MCP Pro to consume.All strictly within CodeGraph's deterministic static-graph scope — no Godot runtime, no ResourceLoader, no WorldFlipper business semantics, no NL queries.
Schema bump (deliberate, isolated)
Adds
unresolved_refs.reference_subkind TEXT(schema v5→v6, forward/idempotent/non-destructiveALTER). Governed by two rules that keep golden byte-stable:ALTERappend) → fresh-create and migrated DBs render identical.schema.The ONLY golden delta is the pinned
.schemachange (+1 line each incolby.schema.sql/mini/schema.sql) + the migratedmini/colby.db. No node/edge/unresolved/files canonical-row change.Verification
make cigreen (fmt + clippy -D warnings + workspace test + guardrail)cargo test -p codegraph-benchgreen (golden oracle + sync equivalence)old_v5_database_migrates_to_v6_without_data_loss) + fresh-vs-migrated.schemaparity test passDownstream-only (no upstream colby analogue; v1.1.2 unrelated).