fix(dr-egeria): fix silently-dropped/mis-mapped attributes found by new consumption audit - #372
Merged
dwolfson merged 1 commit intoSep 18, 2026
Conversation
…ew consumption audit (ISSUE-97 to ISSUE-106) Adds scripts/dr_egeria_attribute_consumption_audit.py, a static audit that checks whether every compact-spec attribute is actually read by its Dr.Egeria processor, and whether Reference Name/Reference Name List attributes are read with the matching guid/guid_list cardinality key. Used it to find and fix a wide batch of silently-dropped or mis-mapped attributes across Data Designer, Digital Product, Governance Officer, Collection Manager, Actor Manager, Solution Architect, and Feedback commands, plus two pyegeria SDK/model bugs it led to: - guid vs guid_list cardinality mismatches (In Data Specification/ Structure/Dictionary/Field) leaving singular references unlinked - Digital Product's Current Version never mapped (and Product Status/ Type removed as spec cruft with no real DTO field) - Purpose silently dropped on ~30 Collection-family commands despite being a required field - Data Lens's 9 fields, Data Grain's 3 fields, and Data Field's Position/Min/Max Cardinality never mapped - Link Agreement Terms and Conditions declared the wrong relationship type entirely (CollectionMembership instead of the real AgreementItem) - Link Associated List had no implementation at all (always raised NotImplementedError); wired via the existing generic MetadataExpert.create_related_elements mechanism - Create Glossary was unconditionally applying both Taxonomy and CanonicalVocabulary classifications regardless of user input - pyegeria: InitialClassifications' serializer popped the wrong dict key after by_alias=True dumping, silently dropping every classification property beyond "class" across the whole SDK - several case-mismatched/phantom-key attribute lookups (Allow Duplicates, Media Type Other Id, Dependency Description, etc.) - 10 compact-spec attributes removed as confirmed cruft (no backing field anywhere in the live Egeria type system) Every fix verified live against qs-view-server with throwaway elements, fetched back and confirmed, then deleted. Full root-cause writeups for each issue are in PYEGERIA_ISSUES.md (ISSUE-97 through ISSUE-106). Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
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
Adds
scripts/dr_egeria_attribute_consumption_audit.py, a static audit that checks whether every compact-spec attribute is actually read by its Dr.Egeria processor, and whetherReference Name/Reference Name Listattributes are read with the matchingguid/guid_listcardinality key. Used it to find and fix a wide batch of silently-dropped or mis-mapped attributes, plus two pyegeria SDK/model bugs it led to. Full root-cause writeups for every issue are inPYEGERIA_ISSUES.md(ISSUE-97 through ISSUE-106).guidvsguid_listcardinality mismatches (In Data Specification/Structure/Dictionary/Field) leaving singular references unlinkedCurrent Versionnever mapped (andProduct Status/Typeremoved as spec cruft with no real DTO field)Purposesilently dropped on ~30 Collection-family commands despite being a required fieldPosition/Min/Max Cardinalitynever mappedLink Agreement Terms and Conditionsdeclared the wrong relationship type entirely (CollectionMembershipinstead of the realAgreementItem)Link Associated Listhad no implementation at all (always raisedNotImplementedError); wired via the existing genericMetadataExpert.create_related_elementsmechanismCreate Glossarywas unconditionally applying bothTaxonomyandCanonicalVocabularyclassifications regardless of user inputInitialClassifications' serializer popped the wrong dict key afterby_alias=Truedumping, silently dropping every classification property beyondclassacross the whole SDKAllow Duplicates,Media Type Other Id,Dependency Description, etc.)Test plan
pytest tests/micro-tests -m unitpasses, no regressionsvalidate_compact_specs: 0 errorsqs-view-serverwith throwaway elements — created, fetched back to confirm the actual persisted values, then deletedscripts/dr_egeria_attribute_consumption_audit.pyre-run scoped to every touched command: 0 findings🤖 Generated with Claude Code