Skip to content

ci(bigquery): add temporary diagnostics to the cloud test job - #6243

Merged
mday-io merged 1 commit into
SQLMesh:mainfrom
mday-io:ci/bigquery-runner-diagnostics
Nov 23, 2026
Merged

mday-io merged 1 commit into
SQLMesh:mainfrom
mday-io:ci/bigquery-runner-diagnostics

Conversation

@mday-io

@mday-io mday-io commented Nov 23, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

engine-tests-cloud (bigquery) has failed on every completed main run since 2026-10-31. The last pass was f6527ffbd on 10-21, and the first failure was a8e3405fc. Each failure has the same shape: 40–75 seconds after pytest -n auto -m "bigquery" starts, make is Terminated, and the runner logs "The runner has received a shutdown signal". There is no test output, because pytest's stdout is block-buffered when it isn't a terminal. On the last passing run the session header itself only appeared about 50 seconds in.

That window has too many suspects to tell apart from the existing logs:

  • Feat: Add optional execution observations #6051, the only commit in it, which has no BigQuery-specific code
  • about 50 dependency bumps, including google-cloud-bigquery 3.46.2→3.47.0, grpcio 1.84→1.85.1 and pytest 9.2.0
  • a runner image update from 20261012 to 20261025

test-vscode-e2e has shown the same runner shutdown since 11-20, after No ptyHost heartbeat warnings, which suggests the runner is running out of resources.

Change

This affects the BigQuery matrix entry only. Every other engine runs exactly as before.

  • PYTHONUNBUFFERED=1 and PYTEST_ADDOPTS=-v, so each test result streams to the log as it finishes.
  • A background loop that logs memory, swap, disk and the top processes by memory every 5 seconds. A trap stops it when the step exits, and the step's exit status still comes from make.

The cloud jobs only run on main, so the first main run after merge will produce the evidence. This is temporary, and I'll revert it once the cause is found.

Summary by CodeRabbit

  • Tests
    • BigQuery test runs now provide unbuffered, more detailed output and periodic system resource logs, including memory, swap, disk, and top-process usage. Other engine test runs are unchanged.

Since 2026-10-31 engine-tests-cloud (bigquery) fails on every main run
with "The runner has received a shutdown signal" 40-75s after pytest
starts. pytest output is block-buffered, so the logs show nothing about
which tests were running or why the runner went down.

For the bigquery matrix entry only:
- PYTHONUNBUFFERED=1 and PYTEST_ADDOPTS=-v so test results stream live
- a background loop logging memory, swap, disk and the top RSS
  processes every 5s, stopped when the step exits

Other engines are unchanged. Revert once the cause is found.

Signed-off-by: mday-io <mdaytn@gmail.com>
@coderabbitai

coderabbitai Bot commented Nov 23, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The cloud-engine test step adds unbuffered Python output, verbose pytest options, and a background resource monitor for BigQuery. Other engines skip the monitor and receive empty values for the two output settings.

Changes: Cloud Test Diagnostics

Layer / File(s) Summary
BigQuery test output and monitoring
.github/workflows/pr.yaml
For BigQuery, the test step enables unbuffered Python output and verbose pytest output. It logs memory, swap, disk, and top-process RSS every five seconds, then stops the monitor on exit. Other engines skip the monitor.

Estimated code review effort: 2 (Simple) | ~8 minutes

Change: Other

Suggested reviewers: stuffbyyuki, cmgoffena13

Merge Risk: Minimal · up to f9a88

This change only adds temporary logging to the BigQuery cloud test job and leaves other engines unchanged. I see no merge-blocking risk. The diagnostics are meant to be reverted once the cause of the runner shutdown is found.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the change: temporary diagnostics for the BigQuery entry of the cloud test job. The raw summary confirms the workflow change adds unbuffered Python output, verbose pytest options, and …
Description check Passed The description covers the problem, the change, and the rationale. It explains the BigQuery-only scope, the revert plan, and the evidence path. It omits the template's Test Plan section and the Checkl…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the change: temporary diagnostics for the BigQuery entry of the cloud test job. The raw summary confirms the workflow change adds unbuffered Python output, verbose pytest options, and a memory/disk/process monitor only for BigQuery. The title is specific and concise, and it matches the main change.

Full details: Description check

Explanation

The description covers the problem, the change, and the rationale. It explains the BigQuery-only scope, the revert plan, and the evidence path. It omits the template's Test Plan section and the Checklist section. The template's Test Plan asks how the changes were tested, and the author does not say. The checklist items (make style, tests, DCO sign-off) are also absent. These gaps are minor for a temporary CI diagnostic change, so the check passes.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 600af1a1-8aa1-42db-a926-f3011d59fb96
Commits

Reviewing files that changed from the base of the PR and between c4d7513 and f9a8875.

Files selected for processing: 1

  • .github/workflows/pr.yaml

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 6 remain after this review.

@mday-io
mday-io merged commit aede423 into SQLMesh:main Nov 23, 2026
37 checks passed
@mday-io mday-io added the ci label Nov 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants