Skip to content

bk convert and validate are out of sync #914

Description

@as-buildkite

Contact Details

No response

What happened?

Bug: bk pipeline convert (github vendor) emits an invalid matrix step key; pipeline upload rejects it and bk pipeline validate doesn't catch it
bk version: 3.42.0 (macOS)
What happened
Converting a GitHub Actions workflow with a matrix job produces a matrix step whose key interpolates the matrix value. For a GHA test job with strategy.matrix.python-version: [3.11, 3.12], the converter emits:

  • label: ":pytest: Test py{{matrix.python_version}}"
    key: "testpy{{matrix.python_version}}"
    matrix:
    setup:
    python_version: ["3.11", "3.12"]
    ...
  • label: ":jest: Jest Tests"
    key: "jest"
    depends_on:
    • "testpy3.11"
    • "testpy3.12"Two related problems:

A matrix step has asinglekey— Buildkite fans it out internally. Interpolating{{matrix.python_version}}intokeyis the wrong shape, and it expands totestpy3.11/testpy3.12, where the.(from the version string) is not a legal key character.
depends_on: [testpy3.11, testpy3.12]references those per-value expansions, which aren't valid keys — it should depend on the single matrix step key.
Upload result

failed to upload and process pipeline: pipeline upload rejected: One of the steps you provided was invalid: may only contain alphanumeric characters, underscores, dashes and colonsThe validate gap
bk pipeline validate --file .buildkite/pipeline.yml reports ✅ "Pipeline file is valid". It passes schema validation but doesn't check step-key character rules or expand matrix keys, so it gives false confidence right before an upload that then fails server-side.
Expected
• Converter: give the matrix step one static, valid key (e.g. key: "testpy"), keep the {{matrix...}} interpolation only in label/command, and emit depends_on that points at that single key.
• bk pipeline validate: ideally flag invalid step-key characters (including matrix-expanded keys) so this is caught locally, not only at upload.

Version

3.42.0

What environment are you seeing the problem on?

CI

Relevant log output

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions