-
Notifications
You must be signed in to change notification settings - Fork 47
[PY-619] metadata.json parser utilities
#738
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
darwin/path_utils.py
Outdated
| with open(path) as f: | ||
| manifest = json.load(f) | ||
|
|
||
| return manifest |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we parse_manifest(manifest) here as well so we're returning the list[property] rather than raw dict
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the reason why I put both parsing functions in different files:
parse_manifestin path_utils.pyparse_propertiesin datatypes.py
is because it needs thePropertyclass to be imported from datatypes.py file - and when imported in path_utils.py, it creates a cyclic dependency on both files.
Other solution would be to move the Property class to path_utils.py? Thoughts?
Nathanjp91
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some things to change.
manifest.json parser utilitiesmetadata.json parser utilities
Nathanjp91
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good.
Problem
Feature request: need utility functions for parsing
metadata.jsonto import Properties when importing Annotations.Solution
Parse
metadata.jsonto create list of newly introduced Property class.Changelog
Parsing
metadata.jsonfor Properties Import