posit-dev / posit-dev/pointblank
col_summary_tbl() does not accept `ibis.expr.types.relations.Table`
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 490
- Forks
- 32
- Avg merge
- 14h 24m
- Merged PRs (30d)
- 2
Description
Prework
- Read and agree to the code of conduct and contributing guidelines.
- If there is already a relevant issue, whether open or closed, comment on the existing thread instead of posting a new issue.
Description
Describe the bug clearly and concisely.
Putting an ibis.expr.types.relations.Table object into col_summary_tbl() returns TypeError: Expected pandas-like dataframe, Polars dataframe, or Polars lazyframe, got: <class 'pyarrow.lib.RecordBatchReader'> even though documentation states that Ibis's Table objects should be acceptable. I have checked the type of the input into the function.
Reproducible example
- Post a minimal reproducible example (MRE) so the maintainer can troubleshoot the problems you identify. A reproducible example is:
- Runnable: post enough code and data so any onlooker can create the error on their own computer.
- Minimal: reduce runtime wherever possible and remove complicated details that are irrelevant to the issue at hand.
- Readable: format your code according to the Style Guide for Python Code.
salesforce_contacts.zip (uncompress this zip file)
import pointblank as pb
import ibis
ibis.options.interactive = True
ibis_database_table_object = ibis.duckdb.connect("salesforce_contacts.duckdb").table("all_contacts")
print(f"ibis_database_table_object's type is: {type(ibis_database_table_object)}")
pb.col_summary_tbl(data=ibis_database_table_object)
Expected result
I would expect to be able to get a summary of the table.
Development environment
- Operating System: Windows 11
- pointblank version 0.13.4
- ibis version 10.8.0
Additional context
Add any other context about the problem here.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running the provided Ibis and DuckDB reproducible example with pointblank 0.13.4, using col_summary_tbl() as the entry point. Trace how the Ibis Table becomes a pyarrow RecordBatchReader and compare that path with the accepted dataframe inputs; done means the example returns a table summary instead of raising TypeError.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100