Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions .github/workflows/release_docker_after_merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ jobs:
id: message-preparation
run: |
url=$SERVER_URL/$REPO/actions/runs/$RUN_ID

if [ $STATUS == 'success' ]
if [ "$STATUS" == 'success' ]
then
msg="The Docker image for the latest release has been successfully built and pushed to DockerHub."
else
Expand All @@ -73,4 +72,4 @@ jobs:
REPO: ${{ github.repository }}
RUN_ID: ${{ github.run_id }}
WEBHOOK_URL: ${{ secrets.LARK_NOTIFICATION_WEBHOOK_URL }}
STATUS: ${{ steps.docker-push.outcome }}
STATUS: ${{ needs.release.result }}
6 changes: 3 additions & 3 deletions .github/workflows/release_pypi_after_merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:

notify:
name: Notify Lark via webhook
needs: release
needs: build-n-publish
runs-on: ubuntu-latest
if: ${{ always() }}
steps:
Expand All @@ -52,7 +52,7 @@ jobs:
run: |
url=$SERVER_URL/$REPO/actions/runs/$RUN_ID

if [ $STATUS == 'success' ]
if [ "$STATUS" == 'success' ]
then
msg="The Colossal-AI latest version has been successfully released to PyPI."
else
Expand All @@ -65,4 +65,4 @@ jobs:
REPO: ${{ github.repository }}
RUN_ID: ${{ github.run_id }}
WEBHOOK_URL: ${{ secrets.LARK_NOTIFICATION_WEBHOOK_URL }}
STATUS: ${{ steps.publish.outcome }}
STATUS: ${{ needs.build-n-publish.result }}
12 changes: 10 additions & 2 deletions .github/workflows/scripts/generate_release_draft.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,12 @@ def collate_release_info(commit_info_list):

for commit_info in commit_info_list:
author = commit_info['commit']['author']['name']
author_url = commit_info['author']['url']

try:
author_url = commit_info['author']['url']
except:
# author can be None
author_url = None
msg = commit_info['commit']['message']
match = re.search(pattern, msg)

Expand Down Expand Up @@ -86,7 +91,10 @@ def generate_release_post_markdown(current_version, last_version, release_info):
# only keep the first line
msg = msg.split('\n')[0]

item = f'{msg} by [{author}]({author_url})\n'
if author_url:
item = f'{msg} by [{author}]({author_url})\n'
else:
item = f'{msg} by {author}\n'
text.append(f'- {item}')

text.append('\n')
Expand Down