cobrapy
cobrapy copied to clipboard
type hint changes in dictlist.py
- [ ] fix #(issue number)
- [X] description of feature/fix Changed type hints in dictlist to be TypeVar(Object), because otherwise my linter would complain about expecting a Reaction and getting Object from model.reactions.get_by_id(). Similarly for other interactions with dictlists. Doesn't change functionality.
- [ ] tests added/passed
- [X] add an entry to the next release
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 84.41%. Comparing base (
2d343e7
) to head (b33ad79
). Report is 93 commits behind head on devel.
Additional details and impacted files
@@ Coverage Diff @@
## devel #1256 +/- ##
==========================================
+ Coverage 84.31% 84.41% +0.09%
==========================================
Files 66 66
Lines 5497 5498 +1
Branches 1265 1265
==========================================
+ Hits 4635 4641 +6
+ Misses 556 551 -5
Partials 306 306
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
@cdiener - can you please review?
Not an expert in type annotations. Looks a bit hacky to me. Could it not just by the Any
type for the items in a DictList since it's a general purpose container?