[PATCH] D116762: workflows: Make issue-subscriber more robust for labels with special characters

Tom Stellard via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 6 23:04:07 PST 2022


tstellar marked 2 inline comments as done.
tstellar added inline comments.


================
Comment at: .github/workflows/issue-subscriber.yml:15
+      run:  |
+        curl -O -L https://raw.githubusercontent.com/$GITHUB_REPOSITORY/$GITHUB_SHA/llvm/utils/git/github-automation.py
+        chmod a+x github-automation.py
----------------
kwk wrote:
> I suspect that checking out the repo is not an option here? 
> 
> But anyways, if you absolutely need curl to download the script, then be aware of some issues with this approach. I noticed that curl sometimes queries an older version of the content than currently is on github. The solution could be this:
> 
> ```
> curl \
>    --compressed \
>    -s \
>    -H 'Cache-Control: no-cache' \
>    https://raw.githubusercontent.com/$GITHUB_REPOSITORY/$GITHUB_SHA/llvm/utils/git/github-automation.py?$(uuidgen)
> ```
> 
> You might wonder about the `--compressed` and caching options or even about
> the UUID being attached to the URL at the very end. These are all ways to
>  ensure we get the freshest of all versions of the file on github. I got the inspiration for this from here:
> https://stackoverflow.com/questions/31653271/how-to-call-curl-without-using-server-side-cache?noredirect=1&lq=1
I don't think any older content exists, because we are pulling a specific version of the file : GITHUB_SHA.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D116762/new/

https://reviews.llvm.org/D116762



More information about the llvm-commits mailing list