mitodl / ocw-studio

Open Source Courseware authoring tool
BSD 3-Clause "New" or "Revised" License
7 stars 3 forks source link

Update actions: checkout, setup-python, setup-node, node-version #2146

Closed ibrahimjaved12 closed 2 months ago

ibrahimjaved12 commented 2 months ago

What are the relevant tickets?

None, but there are Renovate PRs: https://github.com/mitodl/ocw-studio/pull/2143 https://github.com/mitodl/ocw-studio/pull/2144 https://github.com/mitodl/ocw-studio/pull/2145

Description (What does it do?)

This PR updates versions of actions checkout, setup-node, setup-python and also updates node-version. I have added them all in one place for easier testing via runner logs of workflow runs. I upgraded node-version from 16.15.0 to 20. The reason for this is yarn v4 uses >=18.12.0. So we would be able to update yarn later .

How can this be tested?

Check out the runner logs of PR's workflow runs, and you can compare it with any other PR's workflow runs to make sure everything is good.

Here are two runs of this PR: https://github.com/mitodl/ocw-studio/actions/runs/8750466425 https://github.com/mitodl/ocw-studio/actions/runs/8751107510

ibrahimjaved12 commented 2 months ago

@HussainTaj-arbisoft At first I was inclined towards using tag numbers for same reason. But then I noticed that the commit hash Renovate uses, it is in fact the latest commit. So even if we go for a tag number right now, when there is another patch version, it will auto-merge it:

Example: https://github.com/mitodl/ocw-studio/blob/master/.github/workflows/production.yml#L22

So either way, it will be the same in some time -- so I think we can go with Renovate's approach instead since we are locked in it anyway.