This is an automated email from the ASF dual-hosted git repository.

dongjoon pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/orc.git


The following commit(s) were added to refs/heads/main by this push:
     new 14985e5a6 ORC-2115: Improve `create_orc_jira.py` to support the 
component parameter
14985e5a6 is described below

commit 14985e5a63911cd42d18cbc7a1d0ef17f551bde9
Author: Dongjoon Hyun <[email protected]>
AuthorDate: Wed Feb 25 13:50:32 2026 -0800

    ORC-2115: Improve `create_orc_jira.py` to support the component parameter
    
    ### What changes were proposed in this pull request?
    
    This PR aims to improve `create_orc_jira.py` to support the component 
parameter.
    
    ### Why are the changes needed?
    
    To help a developer to create JIRA issues more easily.
    
    ### How was this patch tested?
    
    Manually.
    
    ```
    $ dev/create_orc_jira.py -c 'Java' 'Improve `create_orc_jira.py` to support 
the component parameter'
    Creating JIRA issue with title: Improve `create_orc_jira.py` to support the 
component parameter
    Created JIRA issue: ORC-2115
    git checkout -b ORC-2115
    Switched to a new branch 'ORC-2115'
    Created and checked out branch: ORC-2115
    ['git', 'commit', '-a', '-m', 'ORC-2115: Improve `create_orc_jira.py` to 
support the component parameter']
    Created a commit with message: ORC-2115: Improve `create_orc_jira.py` to 
support the component parameter
    ```
    
    ### Was this patch authored or co-authored using generative AI tooling?
    
    Generated-by: `Gemini 3.1 Pro (High)` on `Antigravity`
    
    Closes #2563 from dongjoon-hyun/ORC-2115.
    
    Authored-by: Dongjoon Hyun <[email protected]>
    Signed-off-by: Dongjoon Hyun <[email protected]>
---
 dev/create_orc_jira.py | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/dev/create_orc_jira.py b/dev/create_orc_jira.py
index c25409209..4b3120bee 100755
--- a/dev/create_orc_jira.py
+++ b/dev/create_orc_jira.py
@@ -50,7 +50,7 @@ def run_cmd(cmd):
 
 import argparse
 
-def create_jira_issue(title, parent_jira_id=None, issue_type=None, 
version=None):
+def create_jira_issue(title, parent_jira_id=None, issue_type=None, 
version=None, component=None):
     asf_jira = jira.client.JIRA(
         {"server": JIRA_API_BASE},
         token_auth=JIRA_ACCESS_TOKEN,
@@ -76,6 +76,9 @@ def create_jira_issue(title, parent_jira_id=None, 
issue_type=None, version=None)
         'versions': [{'name': affected_version}],
     }
 
+    if component:
+        issue_dict['components'] = [{'name': component}]
+
     if parent_jira_id:
         issue_dict['issuetype'] = {'name': 'Sub-task'}
         issue_dict['parent'] = {'key': parent_jira_id}
@@ -117,6 +120,7 @@ def main():
     parser.add_argument("-p", "--parent", help="Parent JIRA ID for subtasks")
     parser.add_argument("-t", "--type", help="Issue type to create when no 
parent is specified (e.g. Bug). Defaults to Improvement.")
     parser.add_argument("-v", "--version", help="Version to use for the issue")
+    parser.add_argument("-c", "--component", help="Component for the issue")
     args = parser.parse_args()
 
     if args.parent:
@@ -124,7 +128,7 @@ def main():
     else:
         print("Creating JIRA issue with title: %s" % args.title)
 
-    jira_id = create_jira_issue(args.title, args.parent, args.type, 
args.version)
+    jira_id = create_jira_issue(args.title, args.parent, args.type, 
args.version, args.component)
     print("Created JIRA issue: %s" % jira_id)
 
     create_and_checkout_branch(jira_id)

Reply via email to