Skip to content

Conversation

@amd-anclark
Copy link
Collaborator

Proposed changes

  • Added two new patterns to detect Docker login and sccache failures.
  • Slightly modified two existing patterns to not use regex capture groups.

How was this tested

I added a temporary test function to log failure messages and force the pipeline to fail. Once failed I verified that the test logs were captured and alerts were sent.

Copy link
Collaborator

@AviralGoelAMD AviralGoelAMD left a comment

Choose a reason for hiding this comment

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

LGTM

@afagaj afagaj requested a review from Copilot January 28, 2026 17:19
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR enhances failure detection in Jenkins pipelines by adding new error patterns and refining existing ones. The changes improve the monitoring and alerting capabilities for Docker authentication issues and sccache startup failures.

Changes:

  • Added two new failure patterns to detect Docker Personal Access Token authentication failures and sccache server startup errors
  • Simplified two existing regex patterns by removing unnecessary capture groups

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

def failurePatterns = [
[pattern: /login attempt to .* failed with status: 401 Unauthorized/, description: "Docker registry authentication failed"],
[pattern: /(.*)docker login failed(.*)/, description: "Docker login failed"],
[pattern: /.*docker login failed.*/, description: "Docker login failed"],
Copy link

Copilot AI Jan 28, 2026

Choose a reason for hiding this comment

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

This pattern is too generic and will match the more specific Docker authentication patterns on lines 41 and 47. Consider either removing this pattern since it's now redundant, or making it more specific to catch different Docker login failure scenarios not covered by the other patterns.

Suggested change
[pattern: /.*docker login failed.*/, description: "Docker login failed"],
[pattern: /^.*docker login failed(?!.*(status: 401 Unauthorized|unauthorized: your account must log in with a Personal Access Token)).*$/, description: "Docker login failed"],

Copilot uses AI. Check for mistakes.
[pattern: /.*GPU not found.*/, description: "GPU not found"],
[pattern: /Could not connect to Redis at .* Connection timed out/, description: "Redis connection timed out"],
[pattern: /.*unauthorized: your account must log in with a Personal Access Token.*/, description: "Docker login failed"],
[pattern: /.*sccache: error: Server startup failed: Address in use.*/, description: "Sccache Error"]
Copy link

Copilot AI Jan 28, 2026

Choose a reason for hiding this comment

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

The description 'Sccache Error' is inconsistent with the capitalization and naming style of other error descriptions in this list. Consider renaming to 'sccache server startup failed' to match the pattern of descriptive, lowercase error messages used elsewhere (e.g., 'Docker registry authentication failed', 'Redis connection timed out').

Suggested change
[pattern: /.*sccache: error: Server startup failed: Address in use.*/, description: "Sccache Error"]
[pattern: /.*sccache: error: Server startup failed: Address in use.*/, description: "sccache server startup failed"]

Copilot uses AI. Check for mistakes.
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