Repository navigation
feat(ledger): list_unmapped_elements names the concept a contra nets against - #316
Merged
Merged
Conversation
jfrench9
added a commit
to RoboFinSystems/robosystems-typescript-client
that referenced
this pull request
Nov 25, 2026
…ainst (#337) ## Summary `LedgerClient.listUnmappedElements` now returns `netsAgainst` on each unmapped element. For a contra-asset account (accumulated amortization, an allowance), it names the reporting concept that the gross sibling under the same parent already maps to, which is the concept the contra should map to. It is `null` when the parent has no such sibling, has more than one, or the sibling is not mapped yet. The field comes from robosystems#2141, released in robosystems **v1.24.6**. The query selects it, so `listUnmappedElements` needs a server on v1.24.6 or later. Python twin: RoboFinSystems/robosystems-python-client#316. ## Changes - **Query** (`clients/graphql/queries/ledger/unmappedElements.ts`): selects `netsAgainst { elementId qname name confidence }`. - **Generated** (`clients/graphql/generated/graphql.ts`): regenerated against the local API on robosystems `main` at v1.24.6. Net effect: `LedgerUnmappedElement` gains `netsAgainst: { elementId, qname, name, confidence } | null`. The OpenAPI regen (`sdk/`) produced no change. - **Tests** (`clients/LedgerClient.test.ts`): the facade returns `netsAgainst` for a contra account and the request selects it. ## Compatibility Additive. `LedgerUnmappedElement` gains a nullable field, and no signature changes. The facade query selects a field that servers older than robosystems v1.24.6 do not have, so against those servers `listUnmappedElements` fails schema validation. The v1.24.6 production deploy is in progress. ## Testing - `ROBOSYSTEMS_API_URL=http://localhost:8000 npm run generate` against the local stack. - `npm run test:all`: validate (format, lint, typecheck), 523 tests in 13 files, and the build all pass. - Not run against a live API. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
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
LedgerClient.list_unmapped_elementsnow returnsnets_againston each unmapped element. For a contra-asset account (accumulated amortization, an allowance), it names the reporting concept the gross sibling under the same parent already maps to, which is the concept the contra should map to. It is absent when the parent has no such sibling, has more than one, or the sibling is not yet mapped. The field comes from robosystems#2141, released in robosystems v1.24.6. The query selects it, solist_unmapped_elementsneeds a server on v1.24.6 or later. TypeScript twin: RoboFinSystems/robosystems-typescript-client#337.Changes
graphql/operations/ledger/ListLedgerUnmappedElements.graphql): selectsnetsAgainst { elementId qname name confidence }.graphql/schema.graphql): refreshed from the API. The only drift is the newUnmappedElement.netsAgainst: SuggestedTargetfield, nullable. Regenerating the OpenAPI produced no change.graphql/generated/): regenerated. Net effect:ListLedgerUnmappedElementsUnmappedElements.nets_against(optional) and the newListLedgerUnmappedElementsUnmappedElementsNetsAgainstmodel, exported fromgraphql.generated.tests/test_ledger_client.py): the existing test assertsnets_against is Nonefor an ordinary account; a new test reads the concept for a contra.Compatibility
ADDITIVE: a new optional field on a generated model, plus a new generated model export. No facade signature changes. The facade query selects a field that servers before robosystems v1.24.6 do not have, so
list_unmapped_elementsfails schema validation against an older server. The v1.24.6 production deploy is in progress.Testing
just generate-sdkagainst the local stack, current with robosystemsmainat v1.24.6, thenjust generate-graphql.just test-all: 761 passed, 17 skipped; format, lint and typecheck clean.🤖 Generated with Claude Code