mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-16 00:37:10 +08:00
mypy_primer: don't fail silently on comment failure (#5002)
Co-authored-by: hauntsaninja <>
This commit is contained in:
18
.github/workflows/mypy_primer_comment.yml
vendored
18
.github/workflows/mypy_primer_comment.yml
vendored
@@ -89,15 +89,11 @@ jobs:
|
||||
|
||||
console.log("Diff from mypy_primer:")
|
||||
console.log(data)
|
||||
try {
|
||||
if (data.trim()) {
|
||||
await github.issues.createComment({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
body: 'Diff from [mypy_primer](https://github.com/hauntsaninja/mypy_primer), showing the effect of this PR on open source code:\n```diff\n' + data + '```'
|
||||
})
|
||||
}
|
||||
} catch (error) {
|
||||
console.log(error)
|
||||
if (data.trim()) {
|
||||
await github.issues.createComment({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
body: 'Diff from [mypy_primer](https://github.com/hauntsaninja/mypy_primer), showing the effect of this PR on open source code:\n```diff\n' + data + '```'
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user