René's URL Explorer Experiment


Title: fix: Improve error handling in blob operations by shuoweil · Pull Request #2194 · googleapis/python-bigquery-dataframes · GitHub

Open Graph Title: fix: Improve error handling in blob operations by shuoweil · Pull Request #2194 · googleapis/python-bigquery-dataframes

X Title: fix: Improve error handling in blob operations by shuoweil · Pull Request #2194 · googleapis/python-bigquery-dataframes

Description: This pull request refactors the blob processing functionalities to introduce comprehensive, two-layer error handling, enhancing robustness and providing clearer feedback on failures. Key Changes: Remote Function Error Handling (bigframes/blob/_functions.py): Wrapped the core logic of all image and PDF processing remote functions (exif_func, image_blur_func, image_resize_func, image_normalize_func, and their _to_bytes variants) in try...excet blocks. These functions now catch all exceptions and return a structured JSON response containing a status field with the error message, preventing remote function crashes. Added validation for image decoding and encoding steps to gracefully handle corrupted or unsupported file formats. Caller-Side Error Handling (bigframes/operations/blob.py): Updated the public-facing blob methods (exif, image_blur, image_resize, image_normalize, pdf_extract, pdf_chunk) to handle potential failures from the remote UDFs. Added try...except blocks around the UDF execution calls (_df_apply_udf) to catch and re-raise exceptions with more contex. Implemented None checks to ensure that UDFs do not return empty results without raising an error. Corrected JSON parsing logic to properly handle both verbose=True (struct-like JSON) and verbose=False (raw content) responses, fixing TypeError issues when accessing fields. Updated all relevant docstrings to include a Raises section, documenting the RuntimeError that can now be expected on processig failures. This two-layer approach ensures that errors are handled gracefully at both the remote execution layer and the user-facing API layer, making the blob operations more resilient and easier to debug. Fixes #<454752361> 🦕

Open Graph Description: This pull request refactors the blob processing functionalities to introduce comprehensive, two-layer error handling, enhancing robustness and providing clearer feedback on failures. Key Changes:...

X Description: This pull request refactors the blob processing functionalities to introduce comprehensive, two-layer error handling, enhancing robustness and providing clearer feedback on failures. Key Changes:...

Opengraph URL: https://github.com/googleapis/python-bigquery-dataframes/pull/2194

X: @github

direct link

Domain: github.com

route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:15ad465e-6a6e-dd27-6329-7699f5ce08e6
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-id86F0:305E50:4EF5758:6F2F8D4:6A56FD46
html-safe-nonceb08fe437d6a016e3c6c09a07661d79b107436953d5db7a507eb1197f79705f8b
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4NkYwOjMwNUU1MDo0RUY1NzU4OjZGMkY4RDQ6NkE1NkZENDYiLCJ2aXNpdG9yX2lkIjoiNjk2NDEzMjMyMzY4OTY5MjQ4NiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmacedcb943694696231342b8a46e36ab720e6e30c34938c659b2c3bb30496d28d52
hovercard-subject-tagpull_request:2942850524
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/googleapis/python-bigquery-dataframes/pull/2194/files
twitter:imagehttps://avatars.githubusercontent.com/u/189301813?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/189301813?s=400&v=4
og:image:altThis pull request refactors the blob processing functionalities to introduce comprehensive, two-layer error handling, enhancing robustness and providing clearer feedback on failures. Key Changes:...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None4eb29e5f807bd95e41196adfbc6d28f9af12d89830d8b684f3e871774ddff2fc
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/googleapis/python-bigquery-dataframes git https://github.com/googleapis/python-bigquery-dataframes.git
octolytics-dimension-user_id16785467
octolytics-dimension-user_logingoogleapis
octolytics-dimension-repository_id667598363
octolytics-dimension-repository_nwogoogleapis/python-bigquery-dataframes
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id667598363
octolytics-dimension-repository_network_root_nwogoogleapis/python-bigquery-dataframes
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releaseb056788a129fb0194b61f2ebb4c43f6a9f4dfd27
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/googleapis/python-bigquery-dataframes/pull/2194/files#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fpython-bigquery-dataframes%2Fpull%2F2194%2Ffiles
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
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
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://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
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fpython-bigquery-dataframes%2Fpull%2F2194%2Ffiles
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=googleapis%2Fpython-bigquery-dataframes
Reloadhttps://github.com/googleapis/python-bigquery-dataframes/pull/2194/files
Reloadhttps://github.com/googleapis/python-bigquery-dataframes/pull/2194/files
Reloadhttps://github.com/googleapis/python-bigquery-dataframes/pull/2194/files
Please reload this pagehttps://github.com/googleapis/python-bigquery-dataframes/pull/2194/files
googleapis https://github.com/googleapis
python-bigquery-dataframeshttps://github.com/googleapis/python-bigquery-dataframes
Notifications https://github.com/login?return_to=%2Fgoogleapis%2Fpython-bigquery-dataframes
Fork 68 https://github.com/login?return_to=%2Fgoogleapis%2Fpython-bigquery-dataframes
Star 289 https://github.com/login?return_to=%2Fgoogleapis%2Fpython-bigquery-dataframes
Code https://github.com/googleapis/python-bigquery-dataframes
Issues 0 https://github.com/googleapis/python-bigquery-dataframes/issues
Pull requests 0 https://github.com/googleapis/python-bigquery-dataframes/pulls
Actions https://github.com/googleapis/python-bigquery-dataframes/actions
Projects https://github.com/googleapis/python-bigquery-dataframes/projects
Security and quality 0 https://github.com/googleapis/python-bigquery-dataframes/security
Insights https://github.com/googleapis/python-bigquery-dataframes/pulse
Code https://github.com/googleapis/python-bigquery-dataframes
Issues https://github.com/googleapis/python-bigquery-dataframes/issues
Pull requests https://github.com/googleapis/python-bigquery-dataframes/pulls
Actions https://github.com/googleapis/python-bigquery-dataframes/actions
Projects https://github.com/googleapis/python-bigquery-dataframes/projects
Security and quality https://github.com/googleapis/python-bigquery-dataframes/security
Insights https://github.com/googleapis/python-bigquery-dataframes/pulse
shuoweilhttps://github.com/shuoweil
mainhttps://github.com/googleapis/python-bigquery-dataframes/tree/main
shuowei-blob-nullhttps://github.com/googleapis/python-bigquery-dataframes/tree/shuowei-blob-null
Conversation 10 https://github.com/googleapis/python-bigquery-dataframes/pull/2194
Commits 11 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/commits
Checks 15 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/checks
Files changed https://github.com/googleapis/python-bigquery-dataframes/pull/2194/files
Please reload this pagehttps://github.com/googleapis/python-bigquery-dataframes/pull/2194/files
fix: Improve error handling in blob operations https://github.com/googleapis/python-bigquery-dataframes/pull/2194/files#top
Show all changes 11 commits https://github.com/googleapis/python-bigquery-dataframes/pull/2194/files
fe774c2 add error handling for audio_transcribe shuoweil Oct 23, 2025 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/commits/fe774c273761d47cfbe42bba1f5965db23474c4a
8b31c8a add error handling for pdf functions shuoweil Oct 23, 2025 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/commits/8b31c8a8ed1dc5d80d0525839d23596a2ed0983c
6a37c18 add eror handling for image functions shuoweil Oct 24, 2025 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/commits/6a37c1870b0d1c18fc49b363a2d5ba62cf55da36
2d66362 final touch shuoweil Oct 24, 2025 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/commits/2d66362d8de1fde34ff50e8e14afcd6c4c3993a0
052bf81 restore rename shuoweil Oct 24, 2025 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/commits/052bf814d263d1a0d24a5295dd1ce294b498d70b
313f04a update notebook to better reflect our new code change shuoweil Oct 24, 2025 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/commits/313f04a5de169ade6b9b0e49257ee9bc5b4fab31
639c0a5 return None on error with verbose=False for image functions shuoweil Oct 27, 2025 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/commits/639c0a500ac3c2f06f3a3b5d9aa3b30d6426710d
526ab6e define typing module in udf shuoweil Oct 27, 2025 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/commits/526ab6e4945fad2a53b9cb2247ff316254d7615d
ebc9aee only use local variable shuoweil Oct 27, 2025 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/commits/ebc9aeec3edee2d6e810502034b24fb604609c17
810122a Merge branch 'main' into shuowei-blob-null shuoweil Oct 29, 2025 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/commits/810122a4fb410f4be68310b0bea3b7b375283262
f14cf55 Refactor code shuoweil Oct 29, 2025 https://github.com/googleapis/python-bigquery-dataframes/pull/2194/commits/f14cf555925f4efdb422be895ed24e1bbe81d47f
Clear filters https://github.com/googleapis/python-bigquery-dataframes/pull/2194/files
Please reload this pagehttps://github.com/googleapis/python-bigquery-dataframes/pull/2194/files
Please reload this pagehttps://github.com/googleapis/python-bigquery-dataframes/pull/2194/files
_functions.py https://github.com/googleapis/python-bigquery-dataframes/pull/2194/files#diff-10ce97a5ed8176babfba41487879226a2f5ed73a4097f46d8d29f3d7865b59fa
blob.py https://github.com/googleapis/python-bigquery-dataframes/pull/2194/files#diff-bdaf7007f2db59f42a2fbc8e3ec62e919eb1527762ba61d8f7945d81b04159c3
multimodal_dataframe.ipynb https://github.com/googleapis/python-bigquery-dataframes/pull/2194/files#diff-be7049f2b7331ad5f1c02b02a937c8c1319eb13586436344272a92df1c274446
Please reload this pagehttps://github.com/googleapis/python-bigquery-dataframes/pull/2194/files
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.