Skip to content

Commit fdf29c4

Browse files
wpfleger96npub1mn7jgtj4w2pd0g0zeuhxsa6jy6p0rewxz4kujt98my82ahfmp72sxjexk7
andauthored
fix(ci): restore E2E flakiness fixes for pgschema, docker-pull, and spec timing (#1396)
Signed-off-by: Will Pfleger <[email protected]> Co-authored-by: npub1mn7jgtj4w2pd0g0zeuhxsa6jy6p0rewxz4kujt98my82ahfmp72sxjexk7 <dcfd242e557282d7a1e2cf2e6877522682f1e5c6156dc92ca7d90eaedd3b0f95@sprout-oss.stage.blox.sqprod.co>
1 parent a7e1202 commit fdf29c4

2 files changed

Lines changed: 46 additions & 7 deletions

File tree

‎.github/workflows/ci.yml‎

Lines changed: 38 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -305,7 +305,18 @@ jobs:
305305
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6
306306
- uses: cashapp/activate-hermit@e49f5cb4dd64ff0b0b659d1d8df499595451155a # v1
307307
- name: Start integration services
308-
run: docker compose up -d postgres redis minio minio-init
308+
run: |
309+
for attempt in 1 2 3; do
310+
if docker compose up -d postgres redis minio minio-init; then
311+
break
312+
fi
313+
if [ "$attempt" -eq 3 ]; then
314+
echo "docker compose up failed after 3 attempts" >&2
315+
exit 1
316+
fi
317+
echo "docker compose up failed (attempt $attempt), retrying in $((attempt * 5))s..." >&2
318+
sleep $((attempt * 5))
319+
done
309320
- name: Get pnpm store directory
310321
id: pnpm-cache
311322
run: echo "STORE_PATH=$(pnpm store path --silent)" >> "$GITHUB_OUTPUT"
@@ -380,6 +391,13 @@ jobs:
380391
PGUSER: buzz
381392
PGPASSWORD: buzz_dev
382393
PGDATABASE: buzz
394+
# Use the already-running docker postgres for desired-state planning instead of
395+
# downloading an embedded Postgres from Maven Central (transient-fetch flake source).
396+
PGSCHEMA_PLAN_HOST: localhost
397+
PGSCHEMA_PLAN_PORT: "5432"
398+
PGSCHEMA_PLAN_DB: buzz
399+
PGSCHEMA_PLAN_USER: buzz
400+
PGSCHEMA_PLAN_PASSWORD: buzz_dev
383401
run: |
384402
./bin/pgschema apply --file schema/schema.sql --auto-approve
385403
docker exec -i -e PGPASSWORD=buzz_dev buzz-postgres \
@@ -471,7 +489,18 @@ jobs:
471489
with:
472490
save-if: ${{ github.event_name != 'pull_request' }}
473491
- name: Start integration services
474-
run: docker compose up -d postgres redis minio minio-init
492+
run: |
493+
for attempt in 1 2 3; do
494+
if docker compose up -d postgres redis minio minio-init; then
495+
break
496+
fi
497+
if [ "$attempt" -eq 3 ]; then
498+
echo "docker compose up failed after 3 attempts" >&2
499+
exit 1
500+
fi
501+
echo "docker compose up failed (attempt $attempt), retrying in $((attempt * 5))s..." >&2
502+
sleep $((attempt * 5))
503+
done
475504
- name: Wait for integration services
476505
run: |
477506
wait_healthy() {
@@ -513,6 +542,13 @@ jobs:
513542
PGUSER: buzz
514543
PGPASSWORD: buzz_dev
515544
PGDATABASE: buzz
545+
# Use the already-running docker postgres for desired-state planning instead of
546+
# downloading an embedded Postgres from Maven Central (transient-fetch flake source).
547+
PGSCHEMA_PLAN_HOST: localhost
548+
PGSCHEMA_PLAN_PORT: "5432"
549+
PGSCHEMA_PLAN_DB: buzz
550+
PGSCHEMA_PLAN_USER: buzz
551+
PGSCHEMA_PLAN_PASSWORD: buzz_dev
516552
run: |
517553
./bin/pgschema apply --file schema/schema.sql --auto-approve
518554
docker exec -i -e PGPASSWORD=buzz_dev buzz-postgres \

‎desktop/tests/e2e/persona-env-vars.spec.ts‎

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -331,11 +331,14 @@ test("persona model options follow the selected LLM provider", async ({
331331

332332
// Switch to Default (no explicit provider) — model resets to "Default model".
333333
await llmProvider.click();
334-
const llmProviderMenu = page.getByRole("menu").filter({
335-
has: page.getByRole("menuitemradio", { name: "OpenAI", exact: true }),
336-
});
337-
await llmProviderMenu
338-
.last()
334+
// Wait for Radix menu animations to settle before locating the menu item.
335+
// The prior approach held a filtered locator across the open→animate boundary
336+
// and clicked a node that Radix was still re-mounting, producing
337+
// "element is not stable" / "element was detached from the DOM" failures.
338+
// Matching the OpenAI/Anthropic steps above: wait for animations, then
339+
// locate fresh at click-time so no stale reference crosses the re-render.
340+
await waitForAnimations(page);
341+
await page
339342
.getByRole("menuitemradio", { name: "Default", exact: true })
340343
.click();
341344
await expect(model).toBeVisible();

0 commit comments

Comments
 (0)