Pandas outputs warning when calling dataframe.append in flux_csv_parser._prepare_data_frame
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 68/100
Research direction
Start in influxdb_client/client/flux_csv_parser.py around lines 243-256, where query_data_frame builds the dataframe, and reproduce the warning with query_api.query_data_frame(query). Compare the behavior with the pandas concatenation change described in pandas issue 39122. Done means the query executes without the reported FutureWarning.
Written by the indexing model from the issue text.
Description
Specifications
- Client Version: 1.36.0
- InfluxDB Version: 2.7
Code sample to reproduce problem
query_api.query_data_frame(query)
Expected behavior
The query should be executed without warnings.
Actual behavior
Pandas outputs a FutureWarning:
/usr/local/lib/python3.11/site-packages/influxdb_client/client/flux_csv_parser.py:256: FutureWarning:
The behavior of array concatenation with empty entries is deprecated. In a future version, this will no longer exclude empty items when determining the result dtype. To retain the old behavior, exclude the empty entries before the concat operation.
This is related to the this code snippet:
Additional info
In the recent pandas version handling of concatenation of empty dataframes changed, see https://github.com/pandas-dev/pandas/issues/39122. This should be handled else wise to reflect the changes in pandas.
- Dominant language
- Python
- Stars
- 792
- Forks
- 186
- Avg merge
- 3h 2m
- Merged PRs (30d)
- 1
Contributor guide
No contributing guide indexed for this repository
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.
More from influxdata/influxdb-client-python
-
Difficulty 3/5 1-2 days Newbie friendliness 45/100
influxdata/influxdb-client-python#694 · 6 reactions ·
-
bug
Difficulty 3/5 1-2 days Newbie friendliness 30/100
influxdata/influxdb-client-python#693 · 2 comments · 1 reaction ·
-
Socks proxy support Open
Difficulty 4/5 3-5 days Newbie friendliness 35/100
-
bug
Difficulty 5/5 Over a week Newbie friendliness 25/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 45/100
All issues in influxdata/influxdb-client-python
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100