HYPERFLEET-625: fix integration test job hanging on test failure#74635
HYPERFLEET-625: fix integration test job hanging on test failure#74635openshift-merge-bot[bot] merged 1 commit intoopenshift:mainfrom
Conversation
Replace linear podman cleanup with trap EXIT to ensure the podman system service is always stopped when the script exits. Without this, if make test-integration hangs (e.g. due to a test panic leaving the Go process in teardown), the kill $PODMAN_PID line is never reached and the podman service keeps the pod alive indefinitely.
|
@rafabene: This pull request references HYPERFLEET-625 which is a valid jira issue. Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the bug to target the "4.22.0" version, but no target version was set. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository. |
|
[REHEARSALNOTIFIER]
Prior to this PR being merged, you will need to either run and acknowledge or opt to skip these rehearsals. Interacting with pj-rehearseComment: Once you are satisfied with the results of the rehearsals, comment: |
|
/lgtm |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: rafabene, rh-amarin The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
/retest |
|
/pj-rehearse |
|
@rafabene: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel. |
|
/retest |
1 similar comment
|
/retest |
|
/test release-controller-config |
|
/override release-controller-config |
|
@rafabene: rafabene unauthorized: /override is restricted to Repo administrators, approvers in top level OWNERS file, and the following github teams:openshift: openshift-release-oversight openshift-staff-engineers openshift-sustaining-engineers. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
Waiting #74642 to be merged and fix ci/prow/release-controller-config job |
|
/test release-controller-config |
|
/pj-rehearse ack |
|
@rafabene: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel. |
|
@rafabene: all tests passed! Full PR test history. Your PR dashboard. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
Summary
trap EXITin the hyperfleet-api integration test jobpodman system servicebackground process is always killed when the script exits, even ifmake test-integrationhangs due to a test panicProblem
When a Go integration test panics, the test process can hang during teardown (e.g., waiting for testcontainer cleanup, HTTP server shutdown). This prevents
make test-integrationfrom exiting, which means the script never reaches thekill $PODMAN_PIDcleanup line. The podman system service continues running indefinitely, keeping the Prow pod in "pending" state and never reporting the failure back to GitHub.Fix
Add a bash
trap EXIThandler immediately after starting the podman service. The EXIT trap fires automatically when the shell process terminates for any reason (normal exit, error, signal), guaranteeing the podman service is always cleaned up.Before
After
Test plan