Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitdf71c6f

Browse files
committed
fix + debug docs preview ci
1 parent3b62464 commitdf71c6f

File tree

2 files changed

+13
-2
lines changed

2 files changed

+13
-2
lines changed

‎.github/set_docs_preview_url.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,17 @@
2727
}
2828

2929
# now create or update a comment on the PR with the preview URL
30+
ifnotPULL_REQUEST_NUMBER:
31+
print('Pull request number not set')
32+
exit(1)
3033

3134
comments_url=f'https://api.github.com/repos/{REPOSITORY}/issues/{PULL_REQUEST_NUMBER}/comments'
3235
r=httpx.get(comments_url,headers=gh_headers)
33-
print(f'GET{comments_url}{r.status_code}')
36+
print(f'{r.request.method}{r.request.url}{r.status_code}')
37+
ifr.status_code!=200:
38+
print(f'Failed to get comments, status{r.status_code}, response:\n{r.text}')
39+
exit(1)
40+
3441
comment_update_url=None
3542

3643
forcommentinr.json():
@@ -61,5 +68,5 @@
6168
print('Creating new comment...')
6269
r=httpx.post(comments_url,headers=gh_headers,json=comment_data)
6370

64-
print(f'{r.request.method}{comments_url}{r.status_code}')
71+
print(f'{r.request.method}{r.request.url}{r.status_code}')
6572
r.raise_for_status()

‎.github/workflows/after-ci.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,10 @@ jobs:
8787
--var GIT_COMMIT_SHA:${{ github.event.workflow_run.head_sha }}
8888
--var GIT_BRANCH:${{ github.event.workflow_run.head_branch }}
8989
90+
-run:echo "$GITHUB_EVENT_JSON"
91+
env:
92+
GITHUB_EVENT_JSON:${{ toJSON(github.event) }}
93+
9094
-name:Set preview URL
9195
run:uv run --with httpx .github/set_docs_preview_url.py
9296
env:

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp