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

Added support for constructing empty Dataset types #1355

Merged
merged 1 commit into from Apr 23, 2017

Conversation

Projects
None yet
2 participants
@philippjfr
Member

philippjfr commented Apr 23, 2017

All Dataset interfaces except the deprecated NdElement interface now support constructing an empty dataset of the right shape when given an empty list. If you can think of another specification that should also mean empty that would be trivial to add. I think this capability is important when working with streams because often your selection, streamed data or whatever else is empty to begin with and constructing an empty Element can often be a pain.

@jlstevens

This comment has been minimized.

Member

jlstevens commented Apr 23, 2017

Looks good.

I would like unit tests for all possible empty constructors though (i.e across data types).

@philippjfr

This comment has been minimized.

Member

philippjfr commented Apr 23, 2017

I would like unit tests for all possible empty constructors though (i.e across data types).

That's the beauty of Dataset tests, you get a unit test per data type for every one you write.

@jlstevens

This comment has been minimized.

Member

jlstevens commented Apr 23, 2017

Great! Happy to merge if you think it is ready and the tests go green.

@philippjfr

This comment has been minimized.

Member

philippjfr commented Apr 23, 2017

Ready to merge.

@jlstevens jlstevens merged commit 0214f41 into master Apr 23, 2017

4 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
coverage/coveralls Coverage increased (+0.2%) to 79.166%
Details
s3-reference-data-cache Test data is cached.
Details

@jlstevens jlstevens deleted the empty_dataset_support branch Apr 26, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment