Skip to content

Fix flaky bundle generate pipeline_and_deploy test: unique pipeline name#5376

Merged
pietern merged 1 commit into
mainfrom
bundle-generate-robust
May 29, 2026
Merged

Fix flaky bundle generate pipeline_and_deploy test: unique pipeline name#5376
pietern merged 1 commit into
mainfrom
bundle-generate-robust

Conversation

@pietern
Copy link
Copy Markdown
Contributor

@pietern pietern commented May 29, 2026

The bundle/generate/pipeline_and_deploy acceptance test set the pipeline name to "test-pipeline-${UNIQUE_NAME}" inside a single-quoted JSON block. Bash doesn't expand ${...} within single quotes, so every run created a pipeline with the identical literal name test-pipeline-${UNIQUE_NAME}. On the cloud variant the Pipelines API rejects duplicate names, so the test failed intermittently with The pipeline name 'test-pipeline-${UNIQUE_NAME}' is already used by another pipeline whenever the direct and terraform variants ran against the same workspace or a prior run's pipeline lingered.

The fix breaks out of the single quotes so $UNIQUE_NAME is interpolated, matching the script's existing '${CURRENT_USER_NAME}' convention and giving each run a distinct pipeline name. Local output is unchanged: the name is never printed, and UNIQUE_NAME is normalized to [UNIQUE_NAME] by the replacer regardless.

I scanned the other bundle/ acceptance scripts that embed variables in single-quoted JSON; this was the only one with the bug. The rest already use the break-out form.

This pull request and its description were written by Isaac.

The pipeline name was set to "test-pipeline-${UNIQUE_NAME}" inside a
single-quoted JSON block, so bash never expanded ${UNIQUE_NAME} and every
run created a pipeline with the identical literal name. On the cloud variant
the Pipelines API rejects duplicate names, causing intermittent failures
when variants ran concurrently or a prior run's pipeline lingered.

Break out of the single quotes so $UNIQUE_NAME is interpolated, matching the
existing '${CURRENT_USER_NAME}' convention in the same script.

Co-authored-by: Isaac
@pietern pietern temporarily deployed to test-trigger-is May 29, 2026 12:05 — with GitHub Actions Inactive
@pietern pietern temporarily deployed to test-trigger-is May 29, 2026 12:05 — with GitHub Actions Inactive
@pietern pietern requested a review from andrewnester May 29, 2026 12:09
@eng-dev-ecosystem-bot
Copy link
Copy Markdown
Collaborator

Commit: e0fdac0

Run: 26636247778

@pietern pietern added this pull request to the merge queue May 29, 2026
Merged via the queue into main with commit eb3fb12 May 29, 2026
25 checks passed
@pietern pietern deleted the bundle-generate-robust branch May 29, 2026 13:29
@eng-dev-ecosystem-bot
Copy link
Copy Markdown
Collaborator

Commit: eb3fb12

Run: 26640098774

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants