Fix bug when reading scalar datasets#124
Conversation
Simplify - Expecting input to be array or int, never None
|
Thank you for contributing!!! Looks reasonable to me. Looks like we don't have workflow enabling tests to run for PRs from forks, let me fix that. I was going to ask to add a test, but it seems currently there is no way to write a scalar dataset (with shape that is a scalar value) using this project (Is that a significant limitation?). For now, if you are ok adding |
|
Even if you are not able to add a test, could you please do a dummy commit to trigger the tests workflow on the PR? Thanks! |
|
I can add a test. Being able to write scalar datasets is out of scope at the moment, we will first work against full support for read |
|
Sounds good, thanks! Yes, sorry, didn't meant to imply you have to work on writing scalar datasets, just thinking if that's something we should look into in the future. |
krisfed
left a comment
There was a problem hiding this comment.
Looks good to me!
As mentioned - would be nice to have a test though, and to make sure existing tests run fine.
Thanks for contributing!
|
@krisfed I finally got around to add the unit test. Sorry for the delay |
|
Hi @krisfed! Friendly reminder on this. Sorry it sat on my side for a while, but test is in and so I just wanted to check if you have a chance to take another look. Anything else needed from me? For context on why I'm keen: I maintain MatNWB, the MATLAB API for Neurodata Without Borders, and we're building Zarr v2 read support on top of this library. That leads to a planning question I'd value your honest read on: what does your review/maintenance bandwidth look like going forward, and would you be open to larger contributions? I have further changes staged in a fork to cover what NWB needs, and I'd much rather upstream them and stay aligned with your roadmap than maintain a long-term fork — but I need to understand whether that's realistic before committing either way. Happy to keep PRs small and reviewable and discuss design up front. Thanks for maintaining this — it's been useful to build on. |
jhughes-dev
left a comment
There was a problem hiding this comment.
Very sorry, I didn't notice I was added for review.
You can get by with a much shorter test, but otherwise this looks great.
Thanks for doing this.
jhughes-mw
left a comment
There was a problem hiding this comment.
See comment on jhughes-dev. Was logged into the wrong account.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #124 +/- ##
=======================================
Coverage 95.81% 95.81%
=======================================
Files 8 8
Lines 263 263
=======================================
Hits 252 252
Misses 11 11 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
krisfed
left a comment
There was a problem hiding this comment.
Looks great, thank you for adding the test! Sorry for delay!
Thank you for this question and transparency, it is exciting to hear that this has been useful! |
Fix issue #120
Add a check in
ZarrPy/readZarrfor whetherstarts,endsorstridesare integers, and wrap them in alistif true.Some alternatives:
arrayto ensure type is same as what is received from MATLAB when these are non-scalar?