Closed dennisbrookner closed 2 years ago
Merging #136 (ea26024) into main (aca17c9) will increase coverage by
0.00%
. The diff coverage is100.00%
.
@@ Coverage Diff @@
## main #136 +/- ##
=======================================
Coverage 98.67% 98.67%
=======================================
Files 41 41
Lines 1583 1590 +7
=======================================
+ Hits 1562 1569 +7
Misses 21 21
Flag | Coverage Δ | |
---|---|---|
unittests | 98.67% <100.00%> (+<0.01%) |
:arrow_up: |
Flags with carried forward coverage won't be shown. Click here to find out more.
Impacted Files | Coverage Δ | |
---|---|---|
reciprocalspaceship/io/precognition.py | 100.00% <100.00%> (ø) |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update aca17c9...ea26024. Read the comment docs.
Jack will reply later, but imo type checks should live in the cellify decorator which is called by the setter.
Jack will reply later, but imo type checks should live in the cellify decorator which is called by the setter.
Yeah, Jack slacked me about this as well. Makes sense, I'll take that out.
As mentioned above, the setter methods for DataSet.cell
and DataSet.spacegroup
implicitly handle all the type checking and coercion to gemmi
objects. These use the @spacegroupify
and @cellify
decorators to ensure that all the relevant type-checking is handled in one place. This change was made in #94.
As such, this looks good -- when the DataSet
attributes are set any necessary checks/conversion to gemmi
objects will be done.
Accomplished all of the changes mentioned in #135 . Two outstanding thoughts:
.ii
files are allowed, I didn't want to change the name of thehklfile
argument for fear of breaking backwards compatibility. That said, I know this function hasn't really seen a lot of daylight, so I'm happy to be overruled there.ValueError
for when acell
argument is provided but doesn't have length 6. Previously, the function checked for this length, but then just silently ignored an argument with the wrong length. I didn't add a test for this behavior, thinking that was overkill, but I could add that if desired.Also, as best I can tell, this is the first "warning" in
reciprocalspaceship
. If some mechanism other than the built-inwarnings
module is preferable, let me know.