Copilot commented on code in PR #4320:
URL: https://github.com/apache/streampark/pull/4320#discussion_r2701220503


##########
.github/boring-cyborg.yml:
##########
@@ -0,0 +1,108 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# This file was completed with reference to the boring-cyborg.yml of 
https://github.com/apache/flink-connector-jdbc.
+
+labelPRBasedOnFilePath:
+  component=infrastructure:
+    - .github/**/*
+    - tools/**/*
+    - .mvn/**/*
+
+  component=dist-material:
+    - dist-material/**/*
+
+  component=docker:
+    - docker/**/*
+
+  component=streampark-common:
+    - streampark-common/**/*
+
+  component=streampark-console-service:
+    - streampark-console/streampark-console-service/**
+
+  component=streampark-console-webapp:
+    - streampark-console/streampark-console-webapp/**
+
+  component=streampark-e2e:
+    - streampark-e2e/**/*
+
+  component=streampark-flink:
+    - streampark-flink/**/*
+
+  component=streampark-shaded:
+    - streampark-shaded/**/*
+
+  component=streampark-spark:
+    - streampark-spark/**/*
+
+###### IssueLink Adder 
#################################################################################################
+# Insert Issue (Jira/Github etc) link in PR description based on the Issue ID 
in PR title.
+insertIssueLinkInPrDescription:
+  # specify the placeholder for the issue link that should be present in the 
description
+  descriptionIssuePlaceholderRegexp: "^Issue link: (.*)$"
+  matchers:
+    # you can have several matches - for different types of issues
+    # only the first matching entry is replaced
+    jiraIssueMatch:
+      # specify the regexp of issue id that you can find in the title of the PR
+      # the match groups can be used to build the issue id (${1}, ${2}, etc.).
+      titleIssueIdRegexp: \[(ISSUE-[0-9]+)\]
+      # the issue link to be added. ${1}, ${2} ... are replaced with the match 
groups from the
+      # title match (remember to use quotes)
+      descriptionIssueLink: 
"[${1}](https://github.com/apache/streampark/issues/${1})"
+    defaultIssueMatch:
+      titleIssueIdRegexp: \[hotfix\]
+      descriptionIssueLink: "`No issue is linked to this PR yet`"
+
+###### Title Validator 
#################################################################################################
+# Verifies if commit/PR titles match the regexp specified
+verifyTitles:
+  # Regular expression that should be matched by titles of commits or PR
+  titleRegexp: ^\[ISSUE-[0-9]+\].*$|^\[ISSUE-XXXXX\].*$|^\[hotfix].*$

Review Comment:
   The regex pattern is missing a closing bracket for the character class. The 
pattern `^\[hotfix].*$` should be `^\[hotfix\].*$` to properly match the 
literal closing bracket.
   ```suggestion
     titleRegexp: ^\[ISSUE-[0-9]+\].*$|^\[ISSUE-XXXXX\].*$|^\[hotfix\].*$
   ```



##########
.github/boring-cyborg.yml:
##########
@@ -0,0 +1,108 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# This file was completed with reference to the boring-cyborg.yml of 
https://github.com/apache/flink-connector-jdbc.
+
+labelPRBasedOnFilePath:
+  component=infrastructure:
+    - .github/**/*
+    - tools/**/*
+    - .mvn/**/*
+
+  component=dist-material:
+    - dist-material/**/*
+
+  component=docker:
+    - docker/**/*
+
+  component=streampark-common:
+    - streampark-common/**/*
+
+  component=streampark-console-service:
+    - streampark-console/streampark-console-service/**
+
+  component=streampark-console-webapp:
+    - streampark-console/streampark-console-webapp/**

Review Comment:
   The path pattern is inconsistent with other entries. Lines 35 and 38 use 
`/**` (two asterisks) without the trailing `/*`, while all other component 
paths use `/**/*` (two asterisks followed by slash and one asterisk). For 
consistency, these should also use `/**/*` pattern.
   ```suggestion
       - streampark-console/streampark-console-service/**/*
   
     component=streampark-console-webapp:
       - streampark-console/streampark-console-webapp/**/*
   ```



##########
.github/boring-cyborg.yml:
##########
@@ -0,0 +1,108 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# This file was completed with reference to the boring-cyborg.yml of 
https://github.com/apache/flink-connector-jdbc.
+
+labelPRBasedOnFilePath:
+  component=infrastructure:
+    - .github/**/*
+    - tools/**/*
+    - .mvn/**/*
+
+  component=dist-material:
+    - dist-material/**/*
+
+  component=docker:
+    - docker/**/*
+
+  component=streampark-common:
+    - streampark-common/**/*
+
+  component=streampark-console-service:
+    - streampark-console/streampark-console-service/**
+
+  component=streampark-console-webapp:
+    - streampark-console/streampark-console-webapp/**
+
+  component=streampark-e2e:
+    - streampark-e2e/**/*
+
+  component=streampark-flink:
+    - streampark-flink/**/*
+
+  component=streampark-shaded:
+    - streampark-shaded/**/*
+
+  component=streampark-spark:
+    - streampark-spark/**/*
+
+###### IssueLink Adder 
#################################################################################################
+# Insert Issue (Jira/Github etc) link in PR description based on the Issue ID 
in PR title.
+insertIssueLinkInPrDescription:
+  # specify the placeholder for the issue link that should be present in the 
description
+  descriptionIssuePlaceholderRegexp: "^Issue link: (.*)$"
+  matchers:
+    # you can have several matches - for different types of issues
+    # only the first matching entry is replaced
+    jiraIssueMatch:
+      # specify the regexp of issue id that you can find in the title of the PR
+      # the match groups can be used to build the issue id (${1}, ${2}, etc.).
+      titleIssueIdRegexp: \[(ISSUE-[0-9]+)\]
+      # the issue link to be added. ${1}, ${2} ... are replaced with the match 
groups from the
+      # title match (remember to use quotes)
+      descriptionIssueLink: 
"[${1}](https://github.com/apache/streampark/issues/${1})"

Review Comment:
   The issue link URL may be incorrect. The pattern captures "ISSUE-[0-9]+" 
(e.g., "ISSUE-4319") and uses it directly in the GitHub issues URL. However, 
GitHub issue URLs typically use just the numeric ID (e.g., "/issues/4319" not 
"/issues/ISSUE-4319"). The captured group should extract only the numeric part, 
or the URL pattern should strip the "ISSUE-" prefix.
   ```suggestion
         titleIssueIdRegexp: \[ISSUE-([0-9]+)\]
         # the issue link to be added. ${1}, ${2} ... are replaced with the 
match groups from the
         # title match (remember to use quotes)
         descriptionIssueLink: 
"[ISSUE-${1}](https://github.com/apache/streampark/issues/${1})"
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to