Skip to content

Commit

Permalink
Release issue status (#21887)
Browse files Browse the repository at this point in the history
* release_iseus_status_auto_reply

* issue_aoto_close_revert

* Update main.py

* Update main.py

* Update update_issue_body.py

* Update reply_generator.py

* Update reply_generator.py

* Update update_issue_body.py

* Update main.py

* Update update_issue_body.py

* Update update_issue_body.py

* Update main.py

* Update reply_generator.py

* Update main.py

* Update update_issue_body.py

* Update main.py

* Update scripts/release_issue_status/update_issue_body.py

* Update update_issue_body.py

* Update main.py

* Update reply_generator.py

* Update update_issue_body.py

* Update main.py

* Update scripts/release_issue_status/main.py

* Update main.py

* Update scripts/release_issue_status/main.py

* Update scripts/release_issue_status/main.py

* Update scripts/release_issue_status/main.py

* Update scripts/release_issue_status/update_issue_body.py

* Update scripts/release_issue_status/main.py

* Update scripts/release_issue_status/update_issue_body.py

* Update reply_generator.py

* Update main.py

* Update scripts/release_issue_status/update_issue_body.py

Co-authored-by: msyyc <[email protected]>

* Update scripts/release_issue_status/update_issue_body.py

Co-authored-by: msyyc <[email protected]>

* Update reply_generator.py

* Update update_issue_body.py

* Update main.py

* Update main.py

* Update update_issue_body.py

* Update main.py

* Update scripts/release_issue_status/main.py

* Update main.py

* Update reply_generator.py

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update update_issue_body.py

* Update main.py

* Update update_issue_body.py

* Update reply_generator.py

* Update update_issue_body.py

* Update main.py

* Update update_issue_body.py

* Update update_issue_body.py

* Update update_issue_body.py

* Update update_issue_body.py

* Update update_issue_body.py

* Update main.py

* Update main.py

* Update release_issue_status.yml for Azure Pipelines

* Update main.py

* Update reply_generator.py

* Add files via upload

* Update reply_generator.py

* Update update_issue_body.py

* Update reply_generator.py

* Update auto_pipeline_run.py

* Update auto_pipeline_run.py

* add auto-close

* Update release_issue_status.yml for Azure Pipelines

* Update auto_close.py

* Update main.py

* Update release_issue_status.yml for Azure Pipelines

* Update auto_pipeline_run.py

* fix bug

* Update main.py

* Update auto_close.py

* Update auto_close.py

* Update main.py

* Update reply_generator.py

* Update main.py

* Update main.py

* Update auto_close.py

* Update main.py

* Update auto-close

* Update auto_pipeline_run.py

* Update update_issue_body.py

* Update auto_pipeline_run.py

* Update release_issue_status.yml for Azure Pipelines

* Update auto_pipeline_run.py

* Update release_issue_status.yml for Azure Pipelines

* Update auto_pipeline_run.py

* Update auto_pipeline_run.py

* Add pipeline link

* Update pipeline link

* Update auto_pipeline_run.py

* Update release_issue_status.yml for Azure Pipelines

* Update auto_pipeline_run.py

* Update requirement.txt

* Update auto_pipeline_run.py

* Add get_python_pipeline

* Update auto_pipeline_run.py

* test

* test

* add outputfolder

* add label

* Update main.py

* Update get_python_pipeline.py

* Update main.py

* Update auto_pipeline_run.py

* Add utils

* Update main.py

* Update main.py

* Delete old py

* Update reply_generator.py

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update utils.py

* Update utils.py

* Update main.py

* Update main.py

* Update reply_generator.py

* Update utils.py

* Add get_changelog function

* Update utils.py

* Update reply_generator.py

* Update main.py

* Update reply_generator.py

* Update function

* del useless code

* Update utils.py

* Update main.py

* Update reply_generator.py

* Update main.py

* Update utils.py

* Update utils.py

* Update utils.py

* Update utils.py

* Update reply_generator.py

* Update main.py

* Update main.py

* Update main.py

* Update release_issue_status.yml for Azure Pipelines

* Update main.py

* Update release_issue_status.yml for Azure Pipelines

* Update release_issue_status.yml for Azure Pipelines

* Update main.py

* Update utils.py

* Update auto-close

* Update release_issue_status.yml for Azure Pipelines

* Update utils.py

* Update utils.py

* Fix auto-close bug

* Update utils.py

* Update utils.py

* Update utils.py

* Update utils.py

* Update utils.py

* Update release_issue_status.yml for Azure Pipelines

* Add assign

* Update reply_generator.py

* Update reply_generator.py

* Update assignee

* Update assignee

* Update main.py

* Update main.py

* Update main.py

* update md

* update md

* update md

* update md

* update md

* update md

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update main.py

* Update utils.py

* Update main.py

* Update main.py

* Update release_issue_status.yml for Azure Pipelines

* Update release_issue_status.yml for Azure Pipelines

* Update release_issue_status.yml for Azure Pipelines

* Update release_issue_status.yml for Azure Pipelines

* Update release_issue_status.yml for Azure Pipelines

* Update release_issue_status.yml for Azure Pipelines

* Update release_issue_status.yml for Azure Pipelines

* Update release_issue_status.yml for Azure Pipelines

* Update release_issue_status.yml for Azure Pipelines

* Update release_issue_status.yml for Azure Pipelines

* Update release_issue_status.yml

* Update reply_generator.py

* Update reply_generator.py

* Update reply_generator.py

* Update reply_generator.py

Co-authored-by: Jiefeng Chen <[email protected]>
Co-authored-by: msyyc <[email protected]>
Co-authored-by: BigCat20196 <[email protected]>
Co-authored-by: Yuchao Yan <[email protected]>
  • Loading branch information
5 people authored Nov 26, 2021
1 parent d885768 commit 4fa744a
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
9 changes: 8 additions & 1 deletion scripts/release_issue_status/release_issue_status.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@ trigger:
exclude:
- '*'

schedules:
- cron: "0,30 1-9 * * *"
displayName: Daily release
branches:
include:
- main
always: true

jobs:
- job: ReleaseIssueStatus
Expand Down Expand Up @@ -53,4 +60,4 @@ jobs:
git checkout release-issue-status
# run
python $script_path/main.py
python $script_path/main.py
9 changes: 5 additions & 4 deletions scripts/release_issue_status/reply_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,15 +59,16 @@ def reply_owner(assigner_issue, reply_content):



def get_reply_and_sdk_number_from_readme(rest_repo, link_dict):
def get_reply_and_sdk_number_from_readme(rest_repo, link_dict, item):
commits = rest_repo.get_commits(path=link_dict['resource_manager'])
latest_commit = commits[0]
check_run_id = latest_commit.get_check_runs(check_name='SDK azure-sdk-for-python-track2')[0].id
latest_pr_number = latest_commit.get_pulls()[0].number
details = rest_repo.get_check_run(check_run_id).output.text
sdk_link_number = re.findall(r'/azure-sdk-for-python/pull/(\d*)">Release SDK Changes</a>', details)[0]
changelog = '<details open><summary><b> python-track2</b></summary> track2_azure-mgmt-{} </details>'.format(
details.split('</code><b>track2_azure-mgmt-')[-1])
changelog = '<details open><summary><b> python-track2</b>' + \
re.search(rf'</code><b>track2_{item.package}(.)+?</pre></li>', details, re.DOTALL).group() \
+ '</details>'
info_model = 'hi @{} Please check the package whether works well and the changelog info ' \
'is as below:\n{}\n' \
'\n* (The version of the package is only a temporary version for testing)\n' \
Expand All @@ -84,7 +85,7 @@ def begin_reply_generate(item, rest_repo, readme_link, sdk_repo, pipeline_url, a
whether_change_readme = readme_comparison(rest_repo, link_dict, labels)

if not whether_change_readme:
reply_content, sdk_link_number = get_reply_and_sdk_number_from_readme(rest_repo, link_dict)
reply_content, sdk_link_number = get_reply_and_sdk_number_from_readme(rest_repo, link_dict, item)
res_run = run_pipeline(issue_link=issue_object_rg.html_url,
sdk_issue_object=sdk_repo.get_pull(int(sdk_link_number)),
pipeline_url=pipeline_url
Expand Down

0 comments on commit 4fa744a

Please sign in to comment.