Skip to content

Commit 1b6c428

Browse files
authored
fix: increase start delay for ASGI conformance tests to address flaky failures (#391)
The ASGI conformance tests are failing sporadically with connection refused errors, where the server appears to not be ready when the test client attempts to connect. Hypothesis: The default 1-second start delay may be insufficient for Uvicorn/ASGI server startup in CI environments. This change increases startDelay to 5 seconds to match the buildpack integration tests, which have been running reliably. Note: The GitHub Action expects startDelay (camelCase) as an input parameter, which it then passes to the conformance test client as -start-delay flag. This is an attempt to diagnose and fix the intermittent failures - further investigation may be needed if the issue persists.
1 parent 9e625c9 commit 1b6c428

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

.github/workflows/conformance-asgi.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ jobs:
5454
useBuildpacks: false
5555
validateMapping: false
5656
cmd: "'functions-framework --source tests/conformance/async_main.py --target write_http --signature-type http --asgi'"
57+
startDelay: 5
5758

5859
- name: Run CloudEvents conformance tests
5960
uses: GoogleCloudPlatform/functions-framework-conformance/action@c7b9c8798fb35e454f76da185a40547ee55c784e # v1.8.7
@@ -62,6 +63,7 @@ jobs:
6263
useBuildpacks: false
6364
validateMapping: false
6465
cmd: "'functions-framework --source tests/conformance/async_main.py --target write_cloud_event --signature-type cloudevent --asgi'"
66+
startDelay: 5
6567

6668
- name: Run HTTP conformance tests declarative
6769
uses: GoogleCloudPlatform/functions-framework-conformance/action@c7b9c8798fb35e454f76da185a40547ee55c784e # v1.8.7
@@ -70,6 +72,7 @@ jobs:
7072
useBuildpacks: false
7173
validateMapping: false
7274
cmd: "'functions-framework --source tests/conformance/async_main.py --target write_http_declarative --asgi'"
75+
startDelay: 5
7376

7477
- name: Run CloudEvents conformance tests declarative
7578
uses: GoogleCloudPlatform/functions-framework-conformance/action@c7b9c8798fb35e454f76da185a40547ee55c784e # v1.8.7
@@ -78,6 +81,7 @@ jobs:
7881
useBuildpacks: false
7982
validateMapping: false
8083
cmd: "'functions-framework --source tests/conformance/async_main.py --target write_cloud_event_declarative --asgi'"
84+
startDelay: 5
8185

8286
- name: Run HTTP concurrency tests declarative
8387
uses: GoogleCloudPlatform/functions-framework-conformance/action@c7b9c8798fb35e454f76da185a40547ee55c784e # v1.8.7
@@ -86,6 +90,7 @@ jobs:
8690
useBuildpacks: false
8791
validateConcurrency: true
8892
cmd: "'functions-framework --source tests/conformance/async_main.py --target write_http_declarative_concurrent --asgi'"
93+
startDelay: 5
8994

9095
# Note: Event (legacy) and Typed tests are not supported in ASGI mode
9196
# Note: validateMapping is set to false for CloudEvent tests because ASGI mode

0 commit comments

Comments
 (0)