René's URL Explorer Experiment


Title: catch pyarrow.lib.ArrowTypeError for augment_schema · Issue #15698 · googleapis/google-cloud-python · GitHub

Open Graph Title: catch pyarrow.lib.ArrowTypeError for augment_schema · Issue #15698 · googleapis/google-cloud-python

X Title: catch pyarrow.lib.ArrowTypeError for augment_schema · Issue #15698 · googleapis/google-cloud-python

Description: Is your feature request related to a problem? Please describe. The problematic field name is not returned in the error for the augment_schema function like it is elsewhere. This can then show up in places like load_table_from_dataframe s...

Open Graph Description: Is your feature request related to a problem? Please describe. The problematic field name is not returned in the error for the augment_schema function like it is elsewhere. This can then show up in...

X Description: Is your feature request related to a problem? Please describe. The problematic field name is not returned in the error for the augment_schema function like it is elsewhere. This can then show up in...

Opengraph URL: https://github.com/googleapis/google-cloud-python/issues/15698

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"catch pyarrow.lib.ArrowTypeError for augment_schema","articleBody":" **Is your feature request related to a problem? Please describe.**\nThe problematic field name is not returned in the error for the `augment_schema` function like it is elsewhere. This can then show up in places like `load_table_from_dataframe` since `augment_schema` is called.\n\n```\npyarrow.lib.ArrowTypeError: Expected bytes, got a 'float' object\n\n  File \"...\", line 57, in load_table_bq\n    job = client.load_table_from_dataframe(\n          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"/.../.venv/lib/python3.12/site-packages/google/cloud/bigquery/client.py\", line 2781, in load_table_from_dataframe\n    new_job_config.schema = _pandas_helpers.dataframe_to_bq_schema(\n                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"/.../.venv/lib/python3.12/site-packages/google/cloud/bigquery/_pandas_helpers.py\", line 491, in dataframe_to_bq_schema\n    bq_schema_out = augment_schema(dataframe, bq_schema_out)\n                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"/.../.venv/lib/python3.12/site-packages/google/cloud/bigquery/_pandas_helpers.py\", line 520, in augment_schema\n    arrow_table = pyarrow.array(dataframe.reset_index()[field.name])\n                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"pyarrow/array.pxi\", line 360, in pyarrow.lib.array\n  File \"pyarrow/array.pxi\", line 87, in pyarrow.lib._ndarray_to_array\n  File \"pyarrow/error.pxi\", line 92, in pyarrow.lib.check_status\n```\n\n **Describe the solution you'd like**\nFix could be similar to googleapis/python-bigquery#1836 \n\n```python\ndef augment_schema(dataframe, current_bq_schema):\n    ...\n    for field in current_bq_schema:\n        if field.field_type is not None:\n            augmented_schema.append(field)\n            continue\n        try:\n            arrow_table = pyarrow.array(dataframe.reset_index()[field.name])\n        except ArrowTypeError:\n            msg = f\"\"\"Error converting Pandas column with name: \"{field.name}\" and datatype: \"{field.dtype}\" to an appropriate pyarrow datatype: ...\"\"\"\n        _LOGGER.error(msg)\n        raise ArrowTypeError(msg)\n```\n\nHappy to submit a PR if this would be approved?","author":{"url":"https://github.com/j-blackwell","@type":"Person","name":"j-blackwell"},"datePublished":"2025-02-11T13:57:37Z","url":"https://github.com/googleapis/google-cloud-python/issues/15698"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:64d0e0d7-003b-7cf0-a086-3a5a413e6574
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idC788:398D8A:BBDCA8:F7322F:6AFE8AB2
html-safe-nonce5da69bc8803dae9386be6e495d7e63bb875acda83f5f6f5af1cf82e8d268396f
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDNzg4OjM5OEQ4QTpCQkRDQTg6RjczMjJGOjZBRkU4QUIyIiwidmlzaXRvcl9pZCI6IjE2NjM4ODkzMjg5MDU4MTY3NTQiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmacfd85832fc5fe629ed124bffb04411bfd73ca4b6dd66eb4733244f777158bfbfe
hovercard-subject-tagissue:4011478261
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/googleapis/google-cloud-python/15698/issue_layout
twitter:imagehttps://opengraph.githubassets.com/393904541c8ae6a4cc3037d4b387206f1a35572d1527aeb5b9fe7ae0ea564b66/googleapis/google-cloud-python/issues/15698
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/393904541c8ae6a4cc3037d4b387206f1a35572d1527aeb5b9fe7ae0ea564b66/googleapis/google-cloud-python/issues/15698
og:image:altIs your feature request related to a problem? Please describe. The problematic field name is not returned in the error for the augment_schema function like it is elsewhere. This can then show up in...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamej-blackwell
hostnamegithub.com
expected-hostnamegithub.com
Noneb3c0f155eafc27e60db6e254d1ffff0e072e9ab3b4018a5ee518797c19d89f86
turbo-cache-controlno-preview
go-importgithub.com/googleapis/google-cloud-python git https://github.com/googleapis/google-cloud-python.git
octolytics-dimension-user_id16785467
octolytics-dimension-user_logingoogleapis
octolytics-dimension-repository_id16316451
octolytics-dimension-repository_nwogoogleapis/google-cloud-python
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id16316451
octolytics-dimension-repository_network_root_nwogoogleapis/google-cloud-python
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release4a10310af51a1bfffbedc4fd81cb582acf0cb0ff
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/googleapis/google-cloud-python/issues/15698#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fissues%2F15698
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fissues%2F15698
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=googleapis%2Fgoogle-cloud-python
Reloadhttps://github.com/googleapis/google-cloud-python/issues/15698
Reloadhttps://github.com/googleapis/google-cloud-python/issues/15698
Reloadhttps://github.com/googleapis/google-cloud-python/issues/15698
googleapishttps://github.com/googleapis
google-cloud-pythonhttps://github.com/googleapis/google-cloud-python
Codehttps://github.com/googleapis/google-cloud-python
Issues450 (450)https://github.com/googleapis/google-cloud-python/issues
Pull requests202 (202)https://github.com/googleapis/google-cloud-python/pulls
Discussionshttps://github.com/googleapis/google-cloud-python/discussions
Actionshttps://github.com/googleapis/google-cloud-python/actions
Projectshttps://github.com/googleapis/google-cloud-python/projects
Security and qualityhttps://github.com/googleapis/google-cloud-python/security
Insightshttps://github.com/googleapis/google-cloud-python/insights
https://github.com/googleapis/google-cloud-python
New issuehttps://github.com/login?return_to=https://github.com/googleapis/google-cloud-python/issues/15698
New issuehttps://github.com/login?return_to=https://github.com/googleapis/google-cloud-python/issues/15698
catch pyarrow.lib.ArrowTypeError for augment_schemahttps://github.com/googleapis/google-cloud-python/issues/15698#top
api: bigqueryIssues related to the BigQuery API.https://github.com/googleapis/google-cloud-python/issues?q=state%3Aopen%20label%3A%22api%3A%20bigquery%22
https://github.com/j-blackwell
j-blackwellhttps://github.com/j-blackwell
on Feb 11, 2025https://github.com/googleapis/google-cloud-python/issues/15698#issue-4011478261
googleapis/python-bigquery#1836https://github.com/googleapis/python-bigquery/pull/1836
product-auto-labelhttps://github.com/apps/product-auto-label
api: bigqueryIssues related to the BigQuery API.https://github.com/googleapis/google-cloud-python/issues?q=state%3Aopen%20label%3A%22api%3A%20bigquery%22
on Feb 11, 2025https://github.com/googleapis/google-cloud-python/issues/15698#event-23194385252
blunderbuss-gcfhttps://github.com/apps/blunderbuss-gcf
shollymanhttps://github.com/shollyman
on Feb 11, 2025https://github.com/googleapis/google-cloud-python/issues/15698#event-23194385276
shollymanhttps://github.com/shollyman
Linchinhttps://github.com/Linchin
shollymanhttps://github.com/shollyman
on Feb 11, 2025https://github.com/googleapis/google-cloud-python/issues/15698#event-23194385297
https://github.com/tswast
tswasthttps://github.com/tswast
on Feb 18, 2025https://github.com/googleapis/google-cloud-python/issues/15698#issuecomment-3984622276
googleapis/python-bigquery#2095https://github.com/googleapis/python-bigquery/pull/2095
https://github.com/j-blackwell
j-blackwellhttps://github.com/j-blackwell
on Mar 3, 2025https://github.com/googleapis/google-cloud-python/issues/15698#issuecomment-3984622301
https://github.com/parthea
partheahttps://github.com/parthea
on Jan 12, 2026https://github.com/googleapis/google-cloud-python/issues/15698#issuecomment-3984622326
partheahttps://github.com/parthea
googleapis/python-bigqueryhttps://github.com/googleapis/python-bigquery
on Jan 12, 2026https://github.com/googleapis/google-cloud-python/issues/15698#event-23194385359
https://github.com/parthea
partheahttps://github.com/parthea
on Jan 12, 2026https://github.com/googleapis/google-cloud-python/issues/15698#issuecomment-3984622353
partheahttps://github.com/parthea
googleapis/google-cloud-pythonhttps://github.com/googleapis/google-cloud-python
on Jan 12, 2026https://github.com/googleapis/google-cloud-python/issues/15698#event-23194385388
https://github.com/chalmerlowe
chalmerlowehttps://github.com/chalmerlowe
on Mar 2, 2026https://github.com/googleapis/google-cloud-python/issues/15698#issuecomment-3984622373
chalmerlowehttps://github.com/chalmerlowe
googleapis/python-bigqueryhttps://github.com/googleapis/python-bigquery
on Mar 2, 2026https://github.com/googleapis/google-cloud-python/issues/15698#event-23194386226
Linchinhttps://github.com/Linchin
on Mar 27, 2026https://github.com/googleapis/google-cloud-python/issues/15698#event-23980067648
https://github.com/daniel-sanche
daniel-sanchehttps://github.com/daniel-sanche
on May 28, 2026https://github.com/googleapis/google-cloud-python/issues/15698#issuecomment-4560198831
daniel-sanchehttps://github.com/daniel-sanche
not plannedhttps://github.com/googleapis/google-cloud-python/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Anot-planned
on May 28, 2026https://github.com/googleapis/google-cloud-python/issues/15698#event-26042573422
Sign up for freehttps://github.com/signup?return_to=https://github.com/googleapis/google-cloud-python/issues/15698
Sign in to commenthttps://github.com/login?return_to=https://github.com/googleapis/google-cloud-python/issues/15698
api: bigqueryIssues related to the BigQuery API.https://github.com/googleapis/google-cloud-python/issues?q=state%3Aopen%20label%3A%22api%3A%20bigquery%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.