-
-
Notifications
You must be signed in to change notification settings - Fork 18.2k
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
Fixed Value Error when doing HDFStore.Select of contiguous mixed-data #17670
Conversation
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.
looks pretty good.
doc/source/whatsnew/v0.21.0.txt
Outdated
@@ -580,6 +580,7 @@ I/O | |||
- Bug in :func:`read_html` where import check fails when run in multiple threads (:issue:`16928`) | |||
- Bug in :func:`read_csv` where automatic delimiter detection caused a ``TypeError`` to be thrown when a bad line was encountered rather than the correct error message (:issue:`13374`) | |||
- Bug in ``DataFrame.to_html()`` with ``notebook=True`` where DataFrames with named indices or non-MultiIndex indices had undesired horizontal or vertical alignment for column or row labels, respectively (:issue:`16792`) | |||
- Bug in :func:`HDFStore.select` ValueError when doing HDFStore.Select of contiguous mixed-data table ft. VLArray (:issue:`17021`) |
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.
you have an extra ValueError here.
Bug in :func:`HDFStore.selct`
when reading a contiguous mixed-data .....
pandas/tests/io/test_pytables.py
Outdated
@@ -5678,3 +5678,14 @@ def test_dst_transitions(self): | |||
store.append('df', df) | |||
result = store.select('df') | |||
assert_frame_equal(result, df) | |||
|
|||
def test_contiguous_mixed_data_table(self): |
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.
can you also add a case that uses start & stop that are not the len
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.
move this near the other selecting tests
Hello @amolkahat! Thanks for updating the PR. Cheers ! There are no PEP8 issues in this Pull Request. 🍻 Comment last updated on September 27, 2017 at 12:09 Hours UTC |
pandas/tests/io/test_pytables.py
Outdated
'b': Series(['ab', 'cd', 'ab'])}) | ||
df.to_hdf('test.h5', 'test_dataset') | ||
|
||
with pd.HDFStore('test.h5') as fd: |
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.
pls use the existing style, IOW ensure_clean_store
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.
looks good as from some style comments.
Codecov Report
@@ Coverage Diff @@
## master #17670 +/- ##
==========================================
+ Coverage 91.24% 91.25% +<.01%
==========================================
Files 163 163
Lines 49762 49761 -1
==========================================
+ Hits 45406 45408 +2
+ Misses 4356 4353 -3
Continue to review full report at Codecov.
|
Codecov Report
@@ Coverage Diff @@
## master #17670 +/- ##
==========================================
+ Coverage 91.24% 91.25% +<.01%
==========================================
Files 163 163
Lines 49762 49761 -1
==========================================
+ Hits 45406 45408 +2
+ Misses 4356 4353 -3
Continue to review full report at Codecov.
|
Codecov Report
@@ Coverage Diff @@
## master #17670 +/- ##
==========================================
+ Coverage 91.24% 91.25% +<.01%
==========================================
Files 163 163
Lines 49762 49761 -1
==========================================
+ Hits 45406 45408 +2
+ Misses 4356 4353 -3
Continue to review full report at Codecov.
|
doc/source/whatsnew/v0.21.0.txt
Outdated
@@ -580,6 +580,7 @@ I/O | |||
- Bug in :func:`read_html` where import check fails when run in multiple threads (:issue:`16928`) | |||
- Bug in :func:`read_csv` where automatic delimiter detection caused a ``TypeError`` to be thrown when a bad line was encountered rather than the correct error message (:issue:`13374`) | |||
- Bug in ``DataFrame.to_html()`` with ``notebook=True`` where DataFrames with named indices or non-MultiIndex indices had undesired horizontal or vertical alignment for column or row labels, respectively (:issue:`16792`) | |||
- Bug in :func:`HDFStore.select` when reading a contiguous mixed-data table ft. VLArray (:issue:`17021`) |
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.
can you expand ft.
pandas/tests/io/test_pytables.py
Outdated
@@ -4387,6 +4387,24 @@ def test_path_pathlib(self): | |||
lambda p: pd.read_hdf(p, 'df')) | |||
tm.assert_frame_equal(df, result) | |||
|
|||
def test_contiguous_mixed_data_table(self): |
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.
can parametrize this for start/stop, also include start=None, stop=None
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.
minor comments, ping on green.
table featuring VLArray Closes 17021 Signed-off-by: Amol Kahat <akahat@redhat.com>
thanks! |
Fixed Value Error when doing HDFStore.Select of contiguous mixed-data table ft. VLArray
Closes 17021
Signed-off-by: Amol Kahat akahat@redhat.com
git diff upstream/master -u -- "*.py" | flake8 --diff