Skip to content

Share one execute query with plan capture idiom - #2395

Merged
joeharris76 merged 3 commits into
developfrom
fix/consolidate-execute-query
Oct 1, 2026
Merged

joeharris76 merged 3 commits into
developfrom
fix/consolidate-execute-query

Conversation

@joeharris76

@joeharris76 joeharris76 commented Sep 26, 2026 •

Copy link
Copy Markdown
Collaborator

Firebolt, Presto/Trino, PostgreSQL, SingleStore, and Doris duplicate the same parent-execution and plan-capture sequence. Move that sequence into the existing result capture mixin and delegate the five thin overrides to it. Preserve strict plan-capture errors, validation and stream arguments, isolated capture, and result identity. Adapters with different execution semantics retain their own paths.

Validation: 728 focused adapter and plan-capture tests passed. The required local preflight passed, including 2,125 medium-tier tests. Ruff passed; the type checker exited successfully with existing optional-SDK import warnings.

Soundness review:

External reviewer: muse
Review output: #2395 (comment)
All Critical/High findings resolved.

Firebolt, Presto/Trino, PostgreSQL, SingleStore, and Doris each wrapped
the shared cursor execution with the same delegate-then-merge lines. Add
execute_query_with_plan_capture to the result capture mixin that already
owns the merge step, and point all five thin overrides at it. Each
adapter keeps its override and platform docstring; adapters with
different semantics (Redshift's failure guard, pg_mooncake's retry,
QuestDB's rewriter) keep their bespoke paths.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 26, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-26T03:36:11.399109Z aa8e85b PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@joeharris76
joeharris76 added this pull request to the merge queue Sep 26, 2026
@joeharris76
joeharris76 removed this pull request from the merge queue due to a manual request Sep 26, 2026
@github-actions github-actions Bot added the awaiting-owner Green, gated on owner review, parked >24h (see docs/operations/soundness-drain.md) label Sep 27, 2026
@joeharris76

Copy link
Copy Markdown
Collaborator Author

Status (Sep 27): no bot review threads on this PR; CI CLEAN. Note: touches benchbox/platforms/base/result_capture.py, a soundness path — withholding auto-enqueue for owner review and manual merge per the soundness gate.

@joeharris76

Copy link
Copy Markdown
Collaborator Author

Maintainer review: verified the diff directly. The shared execute_query_with_plan_capture owns the delegate-then-SUCCESS-guarded-merge idiom; all five call-site conversions are mechanical (same args, comments preserved, bespoke overrides like Redshift/QuestDB untouched). New unit tests cover the shared helper. Zero open threads, required checks green. Enqueuing.

@joeharris76
joeharris76 added this pull request to the merge queue Sep 28, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Sep 28, 2026
@joeharris76
joeharris76 added this pull request to the merge queue Sep 28, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Sep 28, 2026
@joeharris76
joeharris76 added this pull request to the merge queue Sep 28, 2026
@joeharris76
joeharris76 removed this pull request from the merge queue due to the queue being cleared Sep 28, 2026
@joeharris76

Copy link
Copy Markdown
Collaborator Author

Independent external Muse review of a29ec31: SHIP. No Critical or Required findings.

The five adapters retain their parent execution and platform contracts. The shared helper forwards validation and stream arguments, returns the same result, and runs the existing plan merge afterward. Strict PlanCaptureError propagation and isolated post-measurement capture remain intact. Redshift, pg_mooncake, and QuestDB keep their distinct paths. Optional suggestions were a helper-level strict-error test and a more detailed bound-callable annotation.

@joeharris76
joeharris76 added this pull request to the merge queue Oct 1, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Oct 1, 2026
@joeharris76
joeharris76 added this pull request to the merge queue Oct 1, 2026
Merged via the queue into develop with commit e19be23 Oct 1, 2026
40 checks passed
@joeharris76
joeharris76 deleted the fix/consolidate-execute-query branch October 1, 2026 13:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting-owner Green, gated on owner review, parked >24h (see docs/operations/soundness-drain.md)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant