Skip to content

ci: test the Jenkins build workflow, same-repo branch (do not merge) - #253

Open
venkatesan-krishnamoorthy wants to merge 4 commits into
v4.4.0-build-test-tifrom
v4.4.0-build-test-pr-ti
Open

venkatesan-krishnamoorthy wants to merge 4 commits into
v4.4.0-build-test-tifrom
v4.4.0-build-test-pr-ti

Conversation

@venkatesan-krishnamoorthy

Copy link
Copy Markdown

Test PR for ti_platforms_jenkins.yaml. The head branch is in this repository, so the run gets the EPSW_JENKINS_* secrets. Empty commit. Do not merge.

Empty commit to start ti_platforms_jenkins.yaml with the repository
secrets. Do not merge.

Signed-off-by: Venkatesan Krishnamoorthy <v-krishnamoorthy@ti.com>
@qodo-code-review

qodo-code-review Bot commented Dec 2, 2026 •

Copy link
Copy Markdown

Code Review by Qodo


Action required

1. A green check can show no platform results 🐞
Description
The build step suppresses failures while fetching and extracting PLATFORM_RESULT lines, then
decides its status solely from the master build result. If the console request fails or contains no
matching lines while the master reports SUCCESS, the workflow passes without any platform results.
Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
A successful master build can yield a passing check even when its platform results cannot be read or are absent.
## Fix Focus Areas
- .github/workflows/ti_platforms_jenkins.yaml[110-120]
## Recommended Fix
Fail the build step when console retrieval or parsing fails, and require one valid result for each expected platform before returning success.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Dismiss ↗ | View ↗


View medium (3)
Remediation recommended
2. Early build failures lose their cause 🐞
Description
The workflow writes result.txt only after the master wait loop, while the comment step substitutes
not finished when that file is absent. A missing secret, rejected build request, or queue-start
timeout exits before that write, so the pull request comment no longer identifies the failure.
Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
Early exits leave no result file, causing the pull request comment to say `not finished` instead of identifying an error or timeout.
## Fix Focus Areas
- .github/workflows/ti_platforms_jenkins.yaml[51-65]
- .github/workflows/ti_platforms_jenkins.yaml[79-95]
- .github/workflows/ti_platforms_jenkins.yaml[161-169]
## Recommended Fix
Initialize an error outcome and restore an exit trap that records it; set a timeout outcome on the queue-start timeout path.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Dismiss ↗ | View ↗

3. Failed queue cancellation appears successful 🐞
Description
The new queue-cancellation request uses curl -s without checking the HTTP response before printing
its success message. If Jenkins rejects the request or the item cannot be cancelled, the workflow
can say it removed the master while Jenkins has not accepted the cancellation.
Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The new queue-cancellation path prints success for Jenkins HTTP error responses.
## Fix Focus Areas
- .github/workflows/ti_platforms_jenkins.yaml[141-145]
## Recommended Fix
Use a failing HTTP request or explicitly inspect the response status, and print success only after Jenkins accepts the cancellation; surface failures in the workflow log.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Dismiss ↗ | View ↗

4. Cancellation can leave the master running 🐞
Description
The cancellation step chooses queue cancellation from the saved queue record without checking
whether that item has become an executable build. If Jenkins starts the master after that record is
written but before it is replaced with the build URL, cancelling the GitHub run targets the queue
item rather than the running master.
Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
A saved queue URL can refer to a master that has already started, so queue cancellation alone does not stop it.
## Fix Focus Areas
- .github/workflows/ti_platforms_jenkins.yaml[84-95]
- .github/workflows/ti_platforms_jenkins.yaml[127-145]
## Recommended Fix
When cancellation finds a queue record, query the item for its executable URL and stop that build if present; otherwise cancel the still-queued item.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Dismiss ↗ | View ↗


Empty commit to check that a push cancels the running Jenkins builds. Do not merge.

Signed-off-by: Venkatesan Krishnamoorthy <v-krishnamoorthy@ti.com>
@github-actions

github-actions Bot commented Dec 2, 2026 •

Copy link
Copy Markdown

Jenkins build of the TI platforms

Commit 81cb8f0f91c9

Platform Result Jenkins
all ⚠️ ABORTED -

Workflow run

@github-actions

github-actions Bot commented Dec 2, 2026 •

Copy link
Copy Markdown

⏩ Board tests skipped

Commit 3df9caac0c67

Board tests were not run because other checks on this commit failed: Compliance Checks, Run compliance checks on patch series (PR). Fix those first; the boards will run on the next push.

Workflow run

Start zsod_utils_twister_build_all, which builds the platforms in
parallel, instead of one Jenkins build per GitHub job. Cancelling the run
stops the master and the master stops its workers.

Signed-off-by: Venkatesan Krishnamoorthy <v-krishnamoorthy@ti.com>
@venkatesan-krishnamoorthy
venkatesan-krishnamoorthy requested a review from a team December 2, 2026 12:24
echo "Jenkins master result: $RESULT"

# one PLATFORM_RESULT line per platform, printed by the master
curl -sf $JOPTS "${BUILD_URL}consoleText" | grep -o 'PLATFORM_RESULT: .*' | sort -u > "$RUNNER_TEMP/platforms.txt" || true

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Action required

1. A green check can show no platform results 🐞 Bug ≡ Correctness

The build step suppresses failures while fetching and extracting PLATFORM_RESULT lines, then
decides its status solely from the master build result. If the console request fails or contains no
matching lines while the master reports SUCCESS, the workflow passes without any platform results.
Agent Prompt
## Issue description
A successful master build can yield a passing check even when its platform results cannot be read or are absent.
## Fix Focus Areas
- .github/workflows/ti_platforms_jenkins.yaml[110-120]
## Recommended Fix
Fail the build step when console retrieval or parsing fails, and require one valid result for each expected platform before returning success.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Dismiss ↗ | View ↗

ROWS+=$(printf '| %s | %s %s | [build](%sconsole) |\n' "$P" "$I" "$R" "$B")$'\n'
done < "$RUNNER_TEMP/platforms.txt"
if [[ -z "$ROWS" ]]; then
RES=$(cat "$RUNNER_TEMP/result.txt" 2>/dev/null || echo "not finished")

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remediation recommended

2. Early build failures lose their cause 🐞 Bug ◔ Observability

The workflow writes result.txt only after the master wait loop, while the comment step substitutes
not finished when that file is absent. A missing secret, rejected build request, or queue-start
timeout exits before that write, so the pull request comment no longer identifies the failure.
Agent Prompt
## Issue description
Early exits leave no result file, causing the pull request comment to say `not finished` instead of identifying an error or timeout.
## Fix Focus Areas
- .github/workflows/ti_platforms_jenkins.yaml[51-65]
- .github/workflows/ti_platforms_jenkins.yaml[79-95]
- .github/workflows/ti_platforms_jenkins.yaml[161-169]
## Recommended Fix
Initialize an error outcome and restore an exit trap that records it; set a timeout outcome on the queue-start timeout path.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Dismiss ↗ | View ↗

Comment on lines +141 to +144
else
ID=$(basename "${TARGET%/}")
curl -s $JOPTS -o /dev/null -X POST -b "$jar" ${field:+-H "$field: $crumb"} \
"${URL}/queue/cancelItem?id=${ID}" && echo "Removed the master from the queue"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remediation recommended

3. Cancellation can leave the master running 🐞 Bug ☼ Reliability

The cancellation step chooses queue cancellation from the saved queue record without checking
whether that item has become an executable build. If Jenkins starts the master after that record is
written but before it is replaced with the build URL, cancelling the GitHub run targets the queue
item rather than the running master.
Agent Prompt
## Issue description
A saved queue URL can refer to a master that has already started, so queue cancellation alone does not stop it.
## Fix Focus Areas
- .github/workflows/ti_platforms_jenkins.yaml[84-95]
- .github/workflows/ti_platforms_jenkins.yaml[127-145]
## Recommended Fix
When cancellation finds a queue record, query the item for its executable URL and stop that build if present; otherwise cancel the still-queued item.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Dismiss ↗ | View ↗

Comment on lines +143 to +144
curl -s $JOPTS -o /dev/null -X POST -b "$jar" ${field:+-H "$field: $crumb"} \
"${URL}/queue/cancelItem?id=${ID}" && echo "Removed the master from the queue"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remediation recommended

4. Failed queue cancellation appears successful 🐞 Bug ◔ Observability

The new queue-cancellation request uses curl -s without checking the HTTP response before printing
its success message. If Jenkins rejects the request or the item cannot be cancelled, the workflow
can say it removed the master while Jenkins has not accepted the cancellation.
Agent Prompt
## Issue description
The new queue-cancellation path prints success for Jenkins HTTP error responses.
## Fix Focus Areas
- .github/workflows/ti_platforms_jenkins.yaml[141-145]
## Recommended Fix
Use a failing HTTP request or explicitly inspect the response status, and print success only after Jenkins accepts the cancellation; surface failures in the workflow log.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Dismiss ↗ | View ↗

Empty commit to start the Jenkins master job from the workflow. Do not merge.

Signed-off-by: Venkatesan Krishnamoorthy <v-krishnamoorthy@ti.com>
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.

1 participant