Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Nov 12, 2025. It is now read-only.
This repository was archived by the owner on Nov 12, 2025. It is now read-only.

ValueError: No objects to concatenate in to_dataframe method #27

@jurasan

Description

@jurasan

If you have a small query result set and many streams, then often one of the reading streams doesn't get any pages to read (probably other streams get to read all the data before ??)

Pandas doesn't allow concat on empty list. return pandas.concat(frames)

In this case the following exception occurs

File "***/lib/python3.7/site-packages/google/cloud/bigquery_storage_v1/reader.py", line 236, in to_dataframe
    return self.rows(read_session).to_dataframe(dtypes=dtypes)

File "***/lib/python3.7/site-packages/google/cloud/bigquery_storage_v1/reader.py", line 336, in to_dataframe
    return pandas.concat(frames)

File "***/lib/python3.7/site-packages/pandas/core/reshape/concat.py", line 255, in concat
    sort=sort,

File "***/lib/python3.7/site-packages/pandas/core/reshape/concat.py", line 304, in __init__
    raise ValueError("No objects to concatenate")

ValueError: No objects to concatenate

Metadata

Metadata

Assignees

Labels

api: bigqueryIssues related to the BigQuery API.priority: p2Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions