mongodb-labs / mongo-arrow

MongoDB integrations for Apache Arrow. Export MongoDB documents to numpy array, parquet files, and pandas dataframes in one line of code.
https://mongo-arrow.readthedocs.io
Apache License 2.0
92 stars 14 forks source link

ARROW-241: Checking list-types in schema support raises an error #223

Closed lazargugleta closed 5 months ago

lazargugleta commented 5 months ago

JIRA TICKET

Jibola commented 5 months ago

Thanks for supplying this fix @lazargugleta!

One last thing we'd need is for you to add a test case for this function. This ensures that we will not see this error again.

lazargugleta commented 5 months ago

@Jibola Hey, thanks for the quick reply, I added the test Hopefully in the correct place. Let me know If there is anything else needed.

ShaneHarvey commented 5 months ago

LGTM, scheduling the tests.

ShaneHarvey commented 5 months ago

Why remove test_py_empty_list_raises?

lazargugleta commented 5 months ago

Why remove test_py_empty_list_raises?

It tests the same case. Only good thing about leaving it in is that is shows intended behaviour. Should I leave it in?

ShaneHarvey commented 5 months ago

Yeah could you add it back? It's nice to have as an extra regression test. Also our pre-commit checks are failing. You will need to install and run:

pip install pre-commit
pre-commit run --all-files
lazargugleta commented 5 months ago

Yeah could you add it back?

Thanks, test added back + reformatted code according to formating