Uh oh!
There was an error while loading. Please reload this page.
fix(typescript): External-node reconstruction conforms to the slim TSExternalSymbol model - #265
Merged
Merged
Conversation
Merged
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 freeto 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.
Closes#231 (reopened — the earlier close deferred to 2.x work that doesn't exist yet; this is the live 1.x fix).
TSNeo4jBackend.get_external_symbols() raised ValidationError('extra_forbidden') for EVERY External (phantom) node — the default configuration on real apps — because reconstruct.external() passed signature and kind into the extra='forbid' TSExternalSymbol model, which declares only name+module. Reproduced with signature='' per the report.
Fix conforms the reconstructor to both contracts at once: the SDK model is slim by design (map key IS the signature), and the analyzer's published Neo4j schema (codeanalyzer-typescript schema.neo4j.json, External: {signature, name, module}) has no kind property at all — the reconstructor was fabricating it. No information loss: signature remains the external_symbols map key at the call site.
TDD: 3 regression tests (full graph props, empty-signature repro, backend-level via stubbed _run) — RED on main, GREEN after. TS suite at worktree baseline (29 passed, 19 skipped, 23 pre-existing gitignored-fixture errors, #255).
Rides 1.4.3 with #263.