Skip to content
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

3 Testing Failures on Local #52

Open
paradise-runner opened this issue Dec 2, 2020 · 2 comments
Open

3 Testing Failures on Local #52

paradise-runner opened this issue Dec 2, 2020 · 2 comments

Comments

@paradise-runner
Copy link
Contributor

When running tests locally on a fresh master build, 3 tests fail without any changes to code.

  1. 2 of the failures occur on test_it_detects_file_metadata where basic.csv and xlsx_with_zip_mimetype.xlsx produce incorrect mimetypes. Confirmed occurring on macos and ubuntu per @thomasjohns.
  • application/csv for the csv when it should be text/plain
  • application/vnd.openxmlformats-officedocument.spreadsheetml.sheet for the xlsx file when it should be application/zip
  1. test_node_stream_property_returns_at_byte_0_after_parse fails when the node._stream returns the byte position at 12 instead of 0. After some initial testing this seems to be occurring in the pd.read_csv in fables/parse.py/parse_csv
@bk521234
Copy link
Contributor

bk521234 commented Dec 6, 2020

I think I found the culprit for 2.

Python 3.8.5 (default, Jul 28 2020, 12:59:40) 
[GCC 9.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import io
>>> import pandas as pd
>>> 
>>> stream = io.BytesIO(b"a,b\n1,2\n3,4\n")
>>> df = pd.read_csv(stream)
>>> df
   a  b
0  1  2
1  3  4
>>> stream.tell()
12
>>>

pandas version

$ pip freeze | grep pandas
pandas==1.0.1

@bk521234
Copy link
Contributor

bk521234 commented Dec 6, 2020

put out a fix for list item 2. #53

tests in 1 are still broken for me locally on fresh pull from master branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants