Skip to content

Commit ac13b65

Browse files
committed
ci: fix benchmark compare to work with fork pull requests (angular#50758)
The checkout action always assumes the main repository, but the branch name/SHA of the pull request will be from a fork. We fix this by using an updated action that exposes the branch repo owner and name, so that we can check out the actual PR branch/SHA. PR Close angular#50758
1 parent d5736d7 commit ac13b65

2 files changed

Lines changed: 18 additions & 4 deletions

File tree

.github/workflows/benchmark-compare.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,13 @@ jobs:
2727
token: '${{secrets.GITHUB_TOKEN}}'
2828
reactions: 'rocket'
2929

30-
- uses: xt0rted/pull-request-comment-branch@d97294d304604fa98a2600a6e2f916a84b596dc7 # v2
30+
- uses: alessbell/pull-request-comment-branch@v1.1
3131
id: comment-branch
3232

3333
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3
3434
with:
35+
# Specify repository as the PR branch might be from a fork.
36+
repository: ${{steps.comment-branch.outputs.head_owner}}/${{steps.comment-branch.outputs.head_repo}}
3537
# Checkout the pull request and assume it being trusted given we've checked
3638
# that the action was triggered by a team member.
3739
ref: ${{steps.comment-branch.outputs.head_ref}}

yarn.lock

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7063,7 +7063,7 @@ decompress-response@^6.0.0:
70637063
dependencies:
70647064
mimic-response "^3.1.0"
70657065

7066-
decompress-tar@^4.0.0, decompress-tar@^4.1.1:
7066+
decompress-tar@^4.0.0, decompress-tar@^4.1.0, decompress-tar@^4.1.1:
70677067
version "4.1.1"
70687068
resolved "https://registry.yarnpkg.com/decompress-tar/-/decompress-tar-4.1.1.tgz#718cbd3fcb16209716e70a26b84e7ba4592e5af1"
70697069
integrity sha512-JdJMaCrGpB5fESVyxwpCx4Jdj2AagLmv3y58Qy4GE6HMVjWz1FeVQk1Ct4Kye7PftcdOo/7U7UKzYBJgqnGeUQ==
@@ -8421,6 +8421,11 @@ file-type@^5.2.0:
84218421
resolved "https://registry.yarnpkg.com/file-type/-/file-type-5.2.0.tgz#2ddbea7c73ffe36368dfae49dc338c058c2b8ad6"
84228422
integrity sha512-Iq1nJ6D2+yIO4c8HHg4fyVb8mAJieo1Oloy1mLLaB2PvezNedhBVm+QU7g0qM42aiMbRXTxKKwGD17rjKNJYVQ==
84238423

8424+
file-type@^6.1.0:
8425+
version "6.2.0"
8426+
resolved "https://registry.yarnpkg.com/file-type/-/file-type-6.2.0.tgz#e50cd75d356ffed4e306dc4f5bcf52a79903a919"
8427+
integrity sha512-YPcTBDV+2Tm0VqjybVd32MHdlEGAtuxS3VAYsumFokDSMG+ROT5wawGlnHDoz7bfMcMDt9hxuXvXwoKUx2fkOg==
8428+
84248429
84258430
version "1.0.0"
84268431
resolved "https://registry.yarnpkg.com/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz#553a7b8446ff6f684359c445f1e37a05dacc33dd"
@@ -14440,7 +14445,7 @@ safe-stable-stringify@^2.3.1:
1444014445
resolved "https://registry.yarnpkg.com/safe-stable-stringify/-/safe-stable-stringify-2.4.3.tgz#138c84b6f6edb3db5f8ef3ef7115b8f55ccbf886"
1444114446
integrity sha512-e2bDA2WJT0wxseVd4lsDP4+3ONX6HpMXQa1ZhFQ7SU+GjvORCmShbCMltrtIDfkYhVHrOcPtj+KhmDBdPdZD1g==
1444214447

14443-
"safer-buffer@>= 2.1.2 < 3", "safer-buffer@>= 2.1.2 < 3.0.0", safer-buffer@^2.0.2, safer-buffer@~2.1.0:
14448+
"safer-buffer@>= 2.1.2 < 3", "safer-buffer@>= 2.1.2 < 3.0.0", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0:
1444414449
version "2.1.2"
1444514450
resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a"
1444614451
integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==
@@ -14529,6 +14534,13 @@ [email protected]:
1452914534
resolved "https://registry.yarnpkg.com/secure-compare/-/secure-compare-3.0.1.tgz#f1a0329b308b221fae37b9974f3d578d0ca999e3"
1453014535
integrity sha512-AckIIV90rPDcBcglUwXPF3kg0P0qmPsPXAj6BBEENQE1p5yA1xfmDJzfi1Tappj37Pv2mVbKpL3Z1T+Nn7k1Qw==
1453114536

14537+
seek-bzip@^1.0.5:
14538+
version "1.0.6"
14539+
resolved "https://registry.yarnpkg.com/seek-bzip/-/seek-bzip-1.0.6.tgz#35c4171f55a680916b52a07859ecf3b5857f21c4"
14540+
integrity sha512-e1QtP3YL5tWww8uKaOCQ18UxIT2laNBXHjV/S2WYCiK4udiv8lkG89KRIoCjUagnAmCBurjF4zEVX2ByBbnCjQ==
14541+
dependencies:
14542+
commander "^2.8.1"
14543+
1453214544
seek-bzip@^2.0.0:
1453314545
version "2.0.0"
1453414546
resolved "https://registry.yarnpkg.com/seek-bzip/-/seek-bzip-2.0.0.tgz#f0478ab6acd0ac72345d18dc7525dd84d3c706a2"
@@ -16142,7 +16154,7 @@ uglify-js@^3.1.4, uglify-js@^3.7.7:
1614216154
resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.17.4.tgz#61678cf5fa3f5b7eb789bb345df29afb8257c22c"
1614316155
integrity sha512-T9q82TJI9e/C1TAxYvfb16xO120tMVFZrGA3f9/P4424DNu6ypK103y0GPFVa17yotwSyZW5iYXgjYHkGrJW/g==
1614416156

16145-
[email protected], unbzip2-stream@^1.3.3:
16157+
[email protected], unbzip2-stream@^1.0.9, unbzip2-stream@^1.3.3:
1614616158
version "1.4.3"
1614716159
resolved "https://registry.yarnpkg.com/unbzip2-stream/-/unbzip2-stream-1.4.3.tgz#b0da04c4371311df771cdc215e87f2130991ace7"
1614816160
integrity sha512-mlExGW4w71ebDJviH16lQLtZS32VKqsSfk80GCfUlwT/4/hNRFsoscrF/c++9xinkMzECL1uL9DDwXqFWkruPg==

0 commit comments

Comments
 (0)