ComputeLabs Research

BigQuery now supports structured Python user-defined-function logging directly into Cloud Logging, without external plugins or custom connectors.

· ComputeLabs Research · from the October 19, 2026 edition

Google Cloud announced that Python user-defined functions (UDFs) in BigQuery can now use Python’s standard logging library to emit structured logs into Cloud Logging. The feature is described as available, with no external plugin or custom connector required.

Google’s example captures row-level diagnostic information during query execution in an e-commerce event-ingestion pipeline. A Python UDF parses incoming JSON, passes valid records onward, and logs errors for corrupted or non-compliant records while returning `NULL` to avoid failing the entire query.

The example then uses a Cloud Monitoring log-based metric to notify operators when error rates exceed service-level thresholds. Engineers can query quarantined payloads through the linked `_AllLogs` view using SQL, diagnose problems, and re-ingest recovered data.

The supplied code example specifies a Python 3.11 runtime, checks required fields, and logs a warning for empty payloads. Google also states that Python-based logging and validation can be incorporated into pipelines whose transformations are performed in SQL.

  • BigQuery
  • Python
  • Cloud Logging

All 20 stories from October 19, 2026