Skip to content

build.yml: case() expression for vcpkg_commit missing input fallback on PR triggers #1512

@rustyconover

Description

@rustyconover

Bug

The COMMUNITY_EXTENSION_VCPKG_COMMIT output in the prepare job of build.yml uses inputs.duckdb_version directly in the case() expression:

COMMUNITY_EXTENSION_VCPKG_COMMIT: ${{ case(inputs.duckdb_version == 'v1.5.0', steps.parse.outputs.COMMUNITY_EXTENSION_VCPKG_COMMIT == '' && '84bab45d415d22042bd0b9081aea57f362da3f35' || steps.parse.outputs.COMMUNITY_EXTENSION_VCPKG_COMMIT, steps.parse.outputs.COMMUNITY_EXTENSION_VCPKG_COMMIT == '' && 'ce613c41372b23b1f51333815feb3edd87ef8a8b' || steps.parse.outputs.COMMUNITY_EXTENSION_VCPKG_COMMIT) }}

However, inputs.duckdb_version is a workflow_dispatch input. On pull_request triggers it is empty/null, so inputs.duckdb_version == 'v1.5.0' evaluates to false.

Compare with how DUCKDB_VERSION is set a few lines below, which correctly applies a fallback:

DUCKDB_VERSION: ${{ inputs.duckdb_version || 'v1.5.0' }}

Impact

On pull request builds, the case() condition is always false, so the default (third argument) is returned: ce613c41372b23b1f51333815feb3edd87ef8a8b — which provides Arrow 19.0.1 instead of the intended 84bab45d415d22042bd0b9081aea57f362da3f35 which provides Arrow 21.0.0.

This causes build failures for extensions that depend on Arrow 21 APIs (e.g., arrow::ToStatus).

Example: #1492

Suggested fix

Add the || 'v1.5.0' fallback to match the pattern used elsewhere:

COMMUNITY_EXTENSION_VCPKG_COMMIT: ${{ case((inputs.duckdb_version || 'v1.5.0') == 'v1.5.0', ...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions