Skip to content

SRVOCF-1048: Ignore Konflux bot commits in commitlint - #147

Merged
openshift-merge-bot[bot] merged 1 commit into
openshift:masterfrom
twoGiants:SRVOCF-1048-commitlint-fails-on-konflux-bot-commits-due-to-long-signedoffby-trailer
Aug 21, 2026
Merged

SRVOCF-1048: Ignore Konflux bot commits in commitlint#147
openshift-merge-bot[bot] merged 1 commit into
openshift:masterfrom
twoGiants:SRVOCF-1048-commitlint-fails-on-konflux-bot-commits-due-to-long-signedoffby-trailer

Conversation

@twoGiants

Copy link
Copy Markdown

Summary

  • 🐛 Ignore Konflux bot commits in commitlint (Signed-off-by trailer exceeds 100-char footer limit)
  • 🔧 Log the commit message on validation failure so users can recover their text

Fixes SRVOCF-1048

Checklist

  • Updated docs/ARCHITECTURE.md (if there are relevant changes to our layered architecture)

The Konflux bot's Signed-off-by trailer exceeds 100 chars,
failing the footer-max-line-length rule. Add an ignore for
commits containing 'red-hat-konflux'.

Also log the commit message on validation failure so users
can recover their text.

Issue SRVOCF-1048

Co-Authored-By: Claude <noreply@anthropic.com>
@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Aug 20, 2026
@openshift-ci-robot

openshift-ci-robot commented Aug 20, 2026

Copy link
Copy Markdown

@twoGiants: This pull request references SRVOCF-1048 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 "5.1.0" version, but no target version was set.

Details

In response to this:

Summary

  • 🐛 Ignore Konflux bot commits in commitlint (Signed-off-by trailer exceeds 100-char footer limit)
  • 🔧 Log the commit message on validation failure so users can recover their text

Fixes SRVOCF-1048

Checklist

  • Updated docs/ARCHITECTURE.md (if there are relevant changes to our layered architecture)

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.

@twoGiants
twoGiants requested review from pmeida and a lite review from Copilot August 20, 2026 15:56
@openshift-ci
openshift-ci Bot requested review from Cragsmann and matejvasek August 20, 2026 15:56
@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 20, 2026
@twoGiants twoGiants removed the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 20, 2026

Copilot AI left a comment

Copy link
Copy Markdown

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 updates the repository’s commit-message validation flow to reduce friction from Konflux-generated commits and to help developers recover their commit text when validation fails.

Changes:

  • Adjust commitlint ignore logic to skip Konflux-related commits.
  • Enhance the Husky commit-msg hook to print the commit message when commitlint fails, so the user can easily copy it back.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
commitlint.config.mjs Updates commitlint ignore predicate to bypass linting for Konflux-related commit messages.
.husky/commit-msg Adds a helper to print the commit message on validation failure to improve recovery UX.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread .husky/commit-msg
Comment on lines +6 to +12
logMsg() {
echo ""
echo "--- Your commit message ---"
echo "$1"
echo "---"
echo ""
}
Comment thread commitlint.config.mjs
Comment on lines 3 to 5
ignores: [
(message) => message.startsWith('Red Hat Konflux'),
(message) => message.includes('red-hat-konflux'),
(message) => message.startsWith('Merge commit'),
@pmeida

pmeida commented Aug 21, 2026

Copy link
Copy Markdown

/lgtm

the message is echoed twice, but thats fine by me. The last one makes it more clear:

[commit-msg] Validating commit message...
⧗   --- input ---
hey
✖   subject may not be empty [subject-empty]
✖   type may not be empty [type-empty]

✖   found 2 problems, 0 warnings
ⓘ   Get help: https://github.com/conventional-changelog/commitlint/#what-is-commitlint


--- Your commit message ---
hey
---

@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Aug 21, 2026
@pmeida

pmeida commented Aug 21, 2026

Copy link
Copy Markdown

/approve

@openshift-ci

openshift-ci Bot commented Aug 21, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: pmeida, twoGiants

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 21, 2026
@openshift-ci

openshift-ci Bot commented Aug 21, 2026

Copy link
Copy Markdown

@twoGiants: all tests passed!

Full PR test history. Your PR dashboard.

Details

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. I understand the commands that are listed here.

@openshift-merge-bot
openshift-merge-bot Bot merged commit 4d69691 into openshift:master Aug 21, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants