Skip to content

Build: Fix bench-packages BigQuery BOOL/STRING type error#35100

Merged
Sidnioulz merged 1 commit into
nextfrom
chunk/fix-bench-packages-basebranch-bool
Jun 9, 2026
Merged

Build: Fix bench-packages BigQuery BOOL/STRING type error#35100
Sidnioulz merged 1 commit into
nextfrom
chunk/fix-bench-packages-basebranch-bool

Conversation

@circleci-app

@circleci-app circleci-app Bot commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Fixes job benchmark-packages (1579617) failing with No matching signature for operator = for argument types: STRING, BOOL
  • When --base-branch is passed without a value, Commander.js sets options.baseBranch = true (boolean). This happens when << pipeline.parameters.ghBaseBranch >> expands to an empty string in CI, making the shell see --base-branch --pull-request ... — Commander then has no string value to consume and falls back to boolean true.
  • The bare if (options.baseBranch) guard passes for truthy booleans, so compareResults was called with baseBranch = true, which the @google-cloud/bigquery client serialised as a BOOL parameter — crashing against the STRING branch column.
  • Fix: use typeof options.baseBranch === 'string', consistent with the existing typeof options.baseBranch === 'string' guard already present a few lines above for the GCP_CREDENTIALS check.

Manual testing

Must pass benchmark-packages after pushing to next. Can't be tested beforehand in real conditions

Test plan

  • CI benchmark-packages job passes on next push to next

https://app.circleci.com/agents/gh/storybookjs/chat/a7320ab8-4f8a-4178-9e08-f13ca4a22e26

When `--base-branch` is passed without a value (e.g. because
`ghBaseBranch` pipeline parameter expands to empty string), Commander.js
sets `options.baseBranch = true` (boolean). The truthiness guard
`if (options.baseBranch)` passes, and the boolean is sent as a BigQuery
parameter of type BOOL, causing:

  No matching signature for operator = for argument types: STRING, BOOL

Use `typeof options.baseBranch === 'string'` — already the pattern for
the GCP_CREDENTIALS guard just above — so a boolean `true` correctly
skips the comparison instead of crashing.

AI-Generated: true
@Sidnioulz Sidnioulz closed this Jun 9, 2026
@Sidnioulz Sidnioulz reopened this Jun 9, 2026
@Sidnioulz Sidnioulz changed the title Fix bench-packages BigQuery BOOL/STRING type error Build: Fix bench-packages BigQuery BOOL/STRING type error Jun 9, 2026
@Sidnioulz Sidnioulz added build Internal-facing build tooling & test updates ci:normal Run our default set of CI jobs (choose this for most PRs). qa:skip Pull Requests that do not need any QA. labels Jun 9, 2026
@Sidnioulz Sidnioulz self-assigned this Jun 9, 2026
@Sidnioulz

Copy link
Copy Markdown
Contributor

This is fixing a symptom, not the root issue, but aligns with prior symptom fixes and might help get the CI job from failing to non-failing.

@Sidnioulz Sidnioulz moved this to In Progress in Core Team Projects Jun 9, 2026
@Sidnioulz Sidnioulz merged commit b0c55cf into next Jun 9, 2026
156 of 162 checks passed
@Sidnioulz Sidnioulz deleted the chunk/fix-bench-packages-basebranch-bool branch June 9, 2026 10:21
@github-project-automation github-project-automation Bot moved this from In Progress to Done in Core Team Projects Jun 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

build Internal-facing build tooling & test updates ci:normal Run our default set of CI jobs (choose this for most PRs). qa:skip Pull Requests that do not need any QA.

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant