Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

github: automation: fixed rules for commit scope check #2286

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

vpirogov
Copy link
Member

This PR updates commit checker to avoid false positives in #2279 (job link), #2276, and #2272.

As : can be used in commit message itself there's no good way to reliably identify cases with multi-level scope.

@vpirogov vpirogov requested a review from a team as a code owner December 18, 2024 18:06
@github-actions github-actions bot added the devops Github automation label Dec 18, 2024
@@ -79,7 +67,7 @@ def main():
is_ok = is_ok and result

if is_ok:
Copy link
Contributor

Choose a reason for hiding this comment

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

Casually switching to snake_case halfway through the file that started with camelCase..

Copy link
Member Author

@vpirogov vpirogov Dec 18, 2024

Choose a reason for hiding this comment

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

Looks like argparse package has set the tone for main()...

@theComputeKid
Copy link
Contributor

This means that e.g. Removing: from doc would be a valid commit title, since there is no validation of the initial tag.

@vpirogov vpirogov force-pushed the vpirogov/checker-fix branch from 1a93cc3 to 6a82eeb Compare December 18, 2024 20:11
.github/automation/commit-msg-check.py Outdated Show resolved Hide resolved
@vpirogov vpirogov force-pushed the vpirogov/checker-fix branch from 6a82eeb to bceedb3 Compare December 18, 2024 20:48
@vpirogov
Copy link
Member Author

This means that e.g. Removing: from doc would be a valid commit title, since there is no validation of the initial tag.

No, this one will fails because of capital 'R' :). Anything that follows the format of <scope>: <description> or <scope1>, <scope2>: <description> will fly. Testing on commits since oneDNN v3.5 release indicates that nothing really ugly passes and less than 3% of commits fail.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
devops Github automation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants