-
Notifications
You must be signed in to change notification settings - Fork 112
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
Handle 'annotations' as abstraction of 'docs' and 'metadata' #322
Conversation
- update jar - add test
- JDBCBackend.{set,get}_doc are rolled into JDBCBackend.{set,get}_anno.
- annotate, {get,delete}_annotations - {set,get}_doc convenience methods
Codecov Report
@@ Coverage Diff @@
## feature/metadata-bulk-update #322 +/- ##
================================================================
- Coverage 97.36% 97.14% -0.22%
================================================================
Files 41 41
Lines 4322 4376 +54
================================================================
+ Hits 4208 4251 +43
- Misses 114 125 +11
Continue to review full report at Codecov.
|
class CodeList(Enum): | ||
"""Lists of codes in the ixmp data model.""" | ||
#: Annotation IDs. See :meth:`.set_anno` | ||
metadata = auto() |
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.
please change to meta
as described in the data model
jdata.put(str(k), v) | ||
self.jindex[s].setMeta(jdata) | ||
return | ||
# 'metadata' |
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.
please change to meta
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.
Clarifying question, copied from the description:
Achieves a superset of the functionality targeted by #314 and the same UX.
I don't agree that this has the same UX - docs and meta are very distinct concepts, stored differently in our current database implementation, and are used differently in the Scenario Explorer. So I think that having distinct functions for {get, set, delete}_meta
and {get, set, delete}_docs
is a feature, not a problem.
cdc43f6
to
99404d1
Compare
This PR:
This approach:
.get_codes()
andbackend.CodeList
to make explicit the commonality between different lists of 'codes' (string IDs).Some things that could be improved, now or after this is merged into the branch for #314: