# How do I update github actions to Node.js 20?

**URL:** https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536
**Category:** Package Management
**Tags:** question, package, github-actions
**Created:** [February 21, 2024, 6:18pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536 "2024-02-21T18:18:29Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![ctkelley](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ctkelley/32/10684_2.png) [@ctkelley](https://discourse.julialang.org/u/ctkelley)
#### Post date: [February 21, 2024, 6:18pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/1 "2024-02-21T18:18:29Z")

</div>

I got a complaint from github about Node.jl 16 actions. It tells me

```julia
Please update the following actions to use Node.js 20: actions/checkout@v3, julia-actions/setup-julia@latest. 

```

and points me to a link that does not help at all. Does anyone out there  
know what to do.

The offending lines are in a docs.yml file

```julia
      - uses: actions/checkout@v3
      - uses: julia-actions/setup-julia@latest
        with:
          version: ${{ matrix.julia-version }}

```

Thanks in advance.

---

<div class="post-metadata">

### Author: ![ranocha](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ranocha/32/35588_2.png) [@ranocha](https://discourse.julialang.org/u/ranocha)
#### Post date: [February 21, 2024, 6:42pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/2 "2024-02-21T18:42:17Z")

</div>

You should be able to just update the version of the first action to `actions/checkout@v4`. The other one requires [update to node20 by ranocha · Pull Request #209 · julia-actions/setup-julia · GitHub](https://github.com/julia-actions/setup-julia/pull/209)

To get updates like the first one, you should consider adding a Dependabot configuration to your repository as in [Trixi.jl/.github/dependabot.yml at main · trixi-framework/Trixi.jl · GitHub](https://github.com/trixi-framework/Trixi.jl/blob/main/.github%2Fdependabot.yml)

---

<div class="post-metadata">

### Author: ![ctkelley](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ctkelley/32/10684_2.png) [@ctkelley](https://discourse.julialang.org/u/ctkelley)
#### Post date: [February 21, 2024, 7:08pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/3 "2024-02-21T19:08:16Z")

</div>

'preciate it

---

<div class="post-metadata">

### Author: ![giordano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/giordano/32/2166_2.png) [@giordano](https://discourse.julialang.org/u/giordano)
#### Post date: [February 21, 2024, 7:15pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/4 "2024-02-21T19:15:32Z")

</div>

> [@ranocha](#):
>
> To get updates like the first one, you should consider adding a Dependabot configuration to your repository as in [Trixi.jl/.github/dependabot.yml at main · trixi-framework/Trixi.jl · GitHub](https://github.com/trixi-framework/Trixi.jl/blob/main/.github%2Fdependabot.yml)

Even better, add the depedabot file to the `.github` repo of the organisation, so that it applies to all repositories within the org, instead of scattering dozens of identicalt files across all repos (and have fun later updating them).

---

<div class="post-metadata">

### Author: ![ctkelley](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ctkelley/32/10684_2.png) [@ctkelley](https://discourse.julialang.org/u/ctkelley)
#### Post date: [February 21, 2024, 7:50pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/5 "2024-02-21T19:50:52Z")

</div>

I put the dependabot.yml file in .github and it sent me two PRs that I did not understand. What are those PRs for?

---

<div class="post-metadata">

### Author: ![vettert](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/vettert/32/30599_2.png) [@vettert](https://discourse.julialang.org/u/vettert)
#### Post date: [February 22, 2024, 4:39am UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/6 "2024-02-22T04:39:49Z")

</div>

Can you provide a link to the repo in question?

---

<div class="post-metadata">

### Author: ![ranocha](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ranocha/32/35588_2.png) [@ranocha](https://discourse.julialang.org/u/ranocha)
#### Post date: [February 22, 2024, 5:35am UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/7 "2024-02-22T05:35:30Z")

</div>

I would expect that those PRs update the versions of some GitHub actions like from `actions/checkout@v3` to `actions/checkout@v4`. But I would need to have a lonk to the PRs to tell you more

---

<div class="post-metadata">

### Author: ![ctkelley](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ctkelley/32/10684_2.png) [@ctkelley](https://discourse.julialang.org/u/ctkelley)
#### Post date: [February 22, 2024, 10:25am UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/8 "2024-02-22T10:25:00Z")

</div>

The repo is [here](https://github.com/ctkelley/MultiPrecisionArrays.jl). I deleted the branches with the PRs and did the updates manually. github is not complaining any more, so I think I am done.

I left the dependabot.yml in .github and will see if I get more PRs.

Thanks to all of you for the help.

---

<div class="post-metadata">

### Author: ![Niall](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/niall/32/22517_2.png) [@Niall](https://discourse.julialang.org/u/Niall)
#### Post date: [March 7, 2024, 12:45pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/9 "2024-03-07T12:45:34Z")

</div>

I’m dealing with the same problem, and not getting anywhere. I have to confess to having no understanding of GitHub actions. I thought I could maybe solve my problem by specifying node-version [20], but clearly I’m wrong. Can anyone help? These lines are in CI.yml:

```julia
jobs:
  test:
    name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        node-version: [20]
        version:
          - '1'
          - 'nightly'
        os:
          - ubuntu-latest
        arch:
          - x64
    steps:
      - uses: actions/checkout@v4
      - uses: julia-actions/setup-julia@v1
        with:
          version: ${{ matrix.version }}
          arch: ${{ matrix.arch }}
      - uses: julia-actions/cache@v1
      - uses: julia-actions/julia-buildpkg@v1
      - uses: julia-actions/julia-runtest@v1

```

---

<div class="post-metadata">

### Author: ![ctkelley](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ctkelley/32/10684_2.png) [@ctkelley](https://discourse.julialang.org/u/ctkelley)
#### Post date: [March 7, 2024, 1:03pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/10 "2024-03-07T13:03:19Z")

</div>

I got things to work by copying from other packages. My stuff in

```julia
/.github/workflows/

```

from [SIAMFANLEquations.jl](https://github.com/ctkelley/SIAMFANLEquations.jl)  
is doing the job for me. Feel free to use my ci.yml and anything else in there.

Be aware that using other peoples’ .yml files, which I do all the time, can bite you. Take [this issue](https://github.com/JuliaDocs/Documenter.jl/issues/2474), please.

---

<div class="post-metadata">

### Author: ![Niall](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/niall/32/22517_2.png) [@Niall](https://discourse.julialang.org/u/Niall)
#### Post date: [March 7, 2024, 2:34pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/11 "2024-03-07T14:34:46Z")

</div>

Thanks a lot. It still isn’t working, and I’m wondering if the problem doesn’t lie in my code. The errors I get back refer to these entries:

```julia
julia-actions/setup-julia@latest
actions/cache@4d4ae6ae148a43d0fd1eda1800170683e9882738
pyTooling/Actions/with-post-step@adef08d3bdef092282614f3b683897cefae82ee3

```

But the last two I don’t even mention. Could it be that the last two are referenced by the first?

---

<div class="post-metadata">

### Author: ![ctkelley](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ctkelley/32/10684_2.png) [@ctkelley](https://discourse.julialang.org/u/ctkelley)
#### Post date: [March 7, 2024, 3:58pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/12 "2024-03-07T15:58:16Z")

</div>

You have exceeded my skill level. I’m stumped.

---

<div class="post-metadata">

### Author: ![Niall](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/niall/32/22517_2.png) [@Niall](https://discourse.julialang.org/u/Niall)
#### Post date: [March 7, 2024, 4:21pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/13 "2024-03-07T16:21:09Z")

</div>

😂 Well, the skill level of my problem, anyway - I don’t think I can claim that level for myself! Thanks for your time.

---

<div class="post-metadata">

### Author: ![giordano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/giordano/32/2166_2.png) [@giordano](https://discourse.julialang.org/u/giordano)
#### Post date: [March 8, 2024, 3:18pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/14 "2024-03-08T15:18:36Z")

</div>

Can you please explain what problem you’re trying to solve exactly?

---

<div class="post-metadata">

### Author: ![Niall](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/niall/32/22517_2.png) [@Niall](https://discourse.julialang.org/u/Niall)
#### Post date: [March 8, 2024, 6:46pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/15 "2024-03-08T18:46:45Z")

</div>

I’ll try, but as I say, I’m a little unsure whether I’m understanding correctly. I wrote an updat to my julia package a couple of days ago, and the nightly ubuntu-latest test run failed. The message is currently:

```julia
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: julia-actions/setup-julia@latest, actions/cache@4d4ae6ae148a43d0fd1eda1800170683e9882738, pyTooling/Actions/with-post-step@adef08d3bdef092282614f3b683897cefae82ee3.

```

This message is the response to my latest changes to CI.yml, which currently reads:

```julia
jobs:
  test:
    name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        version:
          - '1'
          - 'nightly'
        os:
          - ubuntu-latest
        arch:
          - x64
    steps:
      - uses: actions/checkout@v4
      - uses: julia-actions/setup-julia@latest
        with:
          version: ${{ matrix.version }}
          arch: ${{ matrix.arch }}
      - uses: julia-actions/cache@v1
      - uses: julia-actions/julia-buildpkg@latest
      - uses: julia-actions/julia-runtest@latest

```

At the moment I’ve come to a standstill - can you help?  
(Btw, I’m driving from Germany to Britain over the next two days, so my responses may be slow)

---

<div class="post-metadata">

### Author: ![giordano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/giordano/32/2166_2.png) [@giordano](https://discourse.julialang.org/u/giordano)
#### Post date: [March 9, 2024, 8:32pm UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/16 "2024-03-09T20:32:15Z")

</div>

So, to be clear, unless you’re creating a github actions workflow yourself which uses the Node runtime (and you aren’t) you don’t control the Node runtime, each step is using whatever Node runtime was chosen by the external workflows you’re using (or their own dependencies). The warnings you shared are because of

> <https://github.com/julia-actions/cache/issues/109>
>
> Node 16 is deprecated
> https://github.com/julia-actions/cache/blob/b1b004ffca7da…8ece08fe42c9ee0ec4fc2cc5ca5/action.yml#L118
> https://github.com/julia-actions/cache/blob/b1b004ffca7da8ece08fe42c9ee0ec4fc2cc5ca5/action.yml#L139
> https://github.com/julia-actions/cache/blob/b1b004ffca7da8ece08fe42c9ee0ec4fc2cc5ca5/action.yml#L150
> https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/

> <https://github.com/julia-actions/setup-julia/issues/208>
>
> Node 16 is deprecated
> https://github.com/julia-actions/setup-julia/blob/ffd1649…f9b2d4d2608b754e0f5e24407f01d1960/action.yml#L26
> https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/

So you can’t really do much about it until those issues are addressed.

---

<div class="post-metadata">

### Author: ![Niall](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/niall/32/22517_2.png) [@Niall](https://discourse.julialang.org/u/Niall)
#### Post date: [March 12, 2024, 9:10am UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/17 "2024-03-12T09:10:02Z")

</div>

OK, thank you. I’m unsure how exactly this affects me as a package owner. Can I just continue life as usual, even though my package fails all the tests? That seems a little risky, but my students are starting a new semester and need my changes by Friday.

---

<div class="post-metadata">

### Author: ![giordano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/giordano/32/2166_2.png) [@giordano](https://discourse.julialang.org/u/giordano)
#### Post date: [March 12, 2024, 9:32am UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/18 "2024-03-12T09:32:16Z")

</div>

> [@Niall](#):
>
> Can I just continue life as usual, even though my package fails all the tests?

Wait, what tests are failing? Above we’ve been talking about warnings about the node version used by github actions workflows, which, _at the moment_, is not compromising your ability to run CI test. If your tests are failing you probably want to fix that, but it’s unrelated to the Node version.

---

<div class="post-metadata">

### Author: ![Niall](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/niall/32/22517_2.png) [@Niall](https://discourse.julialang.org/u/Niall)
#### Post date: [March 12, 2024, 9:44am UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/19 "2024-03-12T09:44:04Z")

</div>

I’m confused - I thought that was what we’d been talking about. After I submit a change to my code, normally the package server performs three runs: julia 1, ubuntu-latest and ubuntu-latest-nightly. The last two of these are failing after like 17 minutes with the messages I quoted above.

---

<div class="post-metadata">

### Author: ![giordano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/giordano/32/2166_2.png) [@giordano](https://discourse.julialang.org/u/giordano)
#### Post date: [March 12, 2024, 11:57am UTC](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536/20 "2024-03-12T11:57:35Z")

</div>

> [@Niall](#):
>
> I thought that was what we’d been talking about.

You thought that, no one says that 🙂 Also, I don’t think you shared any link to your repository, we can’t possibly guess what’s happening for you.

> [@Niall](#):
>
> The last two of these are failing after like 17 minutes with the messages I quoted above.

Those are _ **warnings** _, unlikely to be the actual culprit of your failures. If you seek help, you may want to start a new thread with detailed information (and links…) about your errors.

[Next page](https://discourse.julialang.org/t/how-do-i-update-github-actions-to-node-js-20/110536.md?page=2)
