-
Notifications
You must be signed in to change notification settings - Fork 318
fix: empty record dtypes #2147
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
fix: empty record dtypes #2147
Changes from all commits
37dab9d
78151f1
a27b392
d6ce8c1
ffd6e42
9f2b0ef
bb8cd0b
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,7 +21,7 @@ opentelemetry-api==1.1.0 | |
opentelemetry-instrumentation==0.20b0 | ||
opentelemetry-sdk==1.1.0 | ||
packaging==24.2.0 | ||
pandas==1.1.4 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I confirmed that
and There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks for updating the constraint file! |
||
pandas==1.3.0 | ||
pandas-gbq==0.26.1 | ||
proto-plus==1.22.3 | ||
protobuf==3.20.2 | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1222,12 +1222,7 @@ def test_list_rows_nullable_scalars_extreme_dtypes_w_custom_dtype( | |
|
||
# These pandas dtypes are handled by the custom dtypes. | ||
assert df.dtypes["bool_col"].name == "boolean" | ||
# Result is dependent upon which version of pandas is being used. | ||
# Float64 was not introduced until pandas version 1.4. | ||
if PANDAS_INSTALLED_VERSION >= "1.4": | ||
assert df.dtypes["float64_col"].name == "Float64" | ||
else: | ||
assert df.dtypes["float64_col"].name == "string" | ||
Comment on lines
-1225
to
-1230
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
assert df.dtypes["float64_col"].name == "Float64" | ||
assert df.dtypes["int64_col"].name == "Int64" | ||
assert df.dtypes["string_col"].name == "string" | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pandas-dev/pandas#41052 has released with pandas 1.3.0 (as mentioned in above issue: pandas-dev/pandas#41241 (comment))
So if we can increase minimum pandas version to 1.3.0, we don't need this workaround
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should really come up with a consistent policy across all Google packages:
CC @chalmerlowe @Linchin @shollyman @parthea
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed, moving to a monorepo might help make the dependencies more consistent, ideally we might want any overlapped dependencies among the handwritten BigQuery projects to be consistent.
But just for the purpose of this PR, I think it's reasonable to increase the minimum pandas version to 1.3.0, as long as it's not breaking anything.