Skip to content

fix(ci): render empty tuple SDK defaults - #157183

Merged
freeqaz-openai merged 1 commit into
mainfrom
freeqaz-openai/ci-sdk-renderer-20260924
Sep 24, 2026
Merged

freeqaz-openai merged 1 commit into
mainfrom
freeqaz-openai/ci-sdk-renderer-20260924

Conversation

@freeqaz-openai

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes the Plugin SDK API report crashing when a public function has a generic type parameter whose default is an empty tuple, including buildGroupEntrySchema.

User Impact

The SDK report can render these valid public signatures and continue detecting API changes. There is no runtime behavior, dependency, or public API change.

Why This Change Was Made

TypeScript's native signature builder needs AllowEmptyTuple to represent this default. Add that flag only to the function-signature call, preserving the existing compiler rendering and failure checks.

Evidence

  • The compiler-backed re-export regression fails with the original DataView error and passes with the fix. All 27 API-baseline tests pass; the new case takes about 0.7 seconds.
  • The full renderer fails before the fix and completes afterward in 147.5 seconds: 158 modules and 10,867 declaration sections on Node 24.19.0 / TypeScript 7.0.2.
  • All 35 pinned changed-file checks pass, including core/extension typechecks, deadcode, lint, and architecture guards. The deadcode cache-path failure was preserved and recovered with task-owned pnpm cache/state.
  • Independent autoreview found no actionable issues. Hosted qualification remains for the published head.

@clawsweeper

clawsweeper Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@clawsweeper

clawsweeper Bot commented Sep 24, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed September 24, 2026, 5:35 AM ET / 09:35 UTC.

ClawSweeper review

What this changes

The branch lets the Plugin SDK API report render public function signatures with empty tuple generic defaults and tests a re-exported function with that signature.

Merge readiness

✅ Ready for maintainer review

Keep open. Current main still uses the compiler flags that the reported SDK API render cannot handle, and this focused PR addresses that path with a regression test and a measured full-report run.

Priority: P2
Reviewed head: 28e574d78090a9c349c45440d547fa9f9fe0d182

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The repair is focused, the regression covers the report path, and the PR records a measured full-render result.
Proof confidence 🐚 platinum hermit (4/6) Sufficient (live_output): The PR body records a before-fix failure and an after-fix full Plugin SDK report render through the changed declaration printer, with environment, duration, and output counts; the compiler-backed regression is supplemental. No stored-data contract changes.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (live_output): The PR body records a before-fix failure and an after-fix full Plugin SDK report render through the changed declaration printer, with environment, duration, and output counts; the compiler-backed regression is supplemental. No stored-data contract changes.
Evidence reviewed 7 items Introduced repair: The pinned PR delta adds AllowEmptyTuple only to function-signature rendering; the verified test merge carries the same two-file change.
Current main still needs the repair: The current-main function-signature call passes DECLARATION_TYPE_FORMAT_FLAGS without AllowEmptyTuple.
Regression boundary: The new compiler-backed fixture renders an aliased public function whose generic default is an empty tuple and checks the resulting declaration.
Findings None None.
Security None None.

How this fits together

The Plugin SDK API report reads public SDK entrypoints through TypeScript and renders their declarations for API change checks. Its output feeds tooling checks; this change does not alter plugin runtime behavior.

flowchart LR
  A[Public SDK entrypoints] --> B[TypeScript project]
  B --> C[Function signature rendering]
  C --> D[SDK API report]
  D --> E[API change check]
Loading

Before merge

None.

Agent review details

Security

None.

PR surface

Source +1, Tests +17. Total +18 across 2 files.

View PR surface stats
Area Files Added Removed Net
Source 1 2 1 +1
Tests 1 17 0 +17
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 2 19 1 +18

Review metrics

None.

Technical review

Best possible solution:

Keep the compiler-backed SDK API report able to render valid declarations while preserving its API change detection.

Do we have a high-confidence way to reproduce the issue?

Yes, at the source level: current main reaches the function-signature printer without the empty-tuple flag, and the PR supplies a focused fixture and a reported pre-fix full-render failure. This read-only review did not execute the renderer.

Is this the best way to solve the issue?

Yes. Adding the compiler flag at the function-signature call is a narrow repair, and the fixture tests the public report path.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 6e008165e1e8.

Labels

Label changes:

  • add P2: The SDK API report failure affects development checks, with a narrow repair and no demonstrated user runtime outage.
  • add proof: sufficient: Contributor real behavior proof is sufficient. The PR body records a before-fix failure and an after-fix full Plugin SDK report render through the changed declaration printer, with environment, duration, and output counts; the compiler-backed regression is supplemental. No stored-data contract changes.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.

Label justifications:

  • P2: The SDK API report failure affects development checks, with a narrow repair and no demonstrated user runtime outage.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.
  • proof: sufficient: Contributor real behavior proof is sufficient. The PR body records a before-fix failure and an after-fix full Plugin SDK report render through the changed declaration printer, with environment, duration, and output counts; the compiler-backed regression is supplemental. No stored-data contract changes.

Evidence

What I checked:

  • Introduced repair: The pinned PR delta adds AllowEmptyTuple only to function-signature rendering; the verified test merge carries the same two-file change. (src/plugin-sdk/api-baseline-declaration-print.ts:265, 28e574d78090)
  • Current main still needs the repair: The current-main function-signature call passes DECLARATION_TYPE_FORMAT_FLAGS without AllowEmptyTuple. (src/plugin-sdk/api-baseline-declaration-print.ts:264, 6e008165e1e8)
  • Regression boundary: The new compiler-backed fixture renders an aliased public function whose generic default is an empty tuple and checks the resulting declaration. (src/plugin-sdk/api-baseline.test.ts:290, 28e574d78090)
  • Production report path: The API diff owner calls the SDK baseline renderer, which passes each public function declaration to the changed printer. (src/plugin-sdk/api-diff.ts:97, 28e574d78090)
  • Contributor behavior proof: The captured PR body reports that the full renderer failed before the change and completed afterward in 147.5 seconds, producing 158 modules and 10,867 declaration sections on Node 24.19.0 and TypeScript 7.0.2. It also reports a pre-fix failure and post-fix pass for the regression test; these run results were not independently replayed in this read-only review. (28e574d78090)
  • Area history: Current-main history shows a recent TypeScript tooling refactor and earlier SDK API-baseline work on the renderer. This establishes routing context, not which commit introduced the reported failure. (src/plugin-sdk/api-baseline-declaration-print.ts:260, c8eab360206b)

Likely related people:

  • Peter Steinberger: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • Vincent Koc: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@freeqaz-openai
freeqaz-openai enabled auto-merge (squash) September 24, 2026 09:38
@freeqaz-openai
freeqaz-openai merged commit d4748c6 into main Sep 24, 2026
165 of 166 checks passed
@freeqaz-openai
freeqaz-openai deleted the freeqaz-openai/ci-sdk-renderer-20260924 branch September 24, 2026 09:39
@freeqaz-openai

Copy link
Copy Markdown
Contributor Author

Merged via squash auto-merge.

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.

1 participant