Skip to content

v1.5.0

Choose a tag to compare

@vdavez vdavez released this 04 Aug 11:25
83c3003

Two additive features. No breaking SDK surface — but see the relation note below if you branch on relationship labels.

Added

relationships(type, source) on entities (#54)

Each entry in the entity relationships expand now exposes type (the stable key) and source (the system that asserted it), both selectable via shape.

PaginatedResponse.meta (#55)

The API returns a response-level meta block carrying agency-filter diagnostics. The SDK built its response envelope key-by-key, so meta was read by nobody and discarded — SDK users were the one group that could not see it.

response = client.list_contracts(awarding_agency="HUD|HUDD")

response.unresolved_agency_tokens   # {'awarding_agency': ['HUDD']}
response.resolved_agencies          # what each token DID match
response.agency_warnings            # the API's notes

Agency values resolve fuzzily, which fails in two different ways. A token can match nothing and be dropped, or it can match the wrong organization and quietly scope your query to that subtree. Both look identical to "no such records exist".

resolved_agencies is the one worth understanding: in the wrong-organization case nothing is dropped, so a dropped-token check cannot detect it. Comparing the resolved name is the only client-side signal.

All three accessors return empty rather than raising when meta is absent or malformed.

Fully-unresolvable agency filters now raise (#55)

TangoValidationError naming the offending value, instead of an empty page. No SDK change was needed — the existing 400 handler already read the API's error key — but it is new behavior for list_subawards(), list_opportunities(), list_notices() and list_vehicles().

Changed

⚠️ The relation value vocabulary changed upstream — match on type instead (#54)

relation stopped collapsing to affiliate. No SDK code change is required (relation was and remains a str), but if you have application code branching on the string affiliate, switch it to type — that is the stable key. This is the only item in this release that can quietly change an existing caller's behavior.

Notes

PaginatedResponse.page_metadata is documented as always None. The API has never emitted a page_metadata key, so the field has only ever read something that does not exist. Retained so existing attribute access keeps working; use meta.


Full changelog: https://github.com/makegov/tango-python/blob/main/CHANGELOG.md