astral-sh / ruff-action

A GitHub Action to run Ruff
Apache License 2.0
39 stars 2 forks source link

"unable to find version `v1`" when using example from readme #8

Closed jimgar closed 2 weeks ago

jimgar commented 2 weeks ago

Hi there

I have a fresh repo. I put the example from the astral-sh/ruff-action readme into my repo's .github/workflows/ruff.yml

On push I get the following error when the workflow attempts to run:

Error: Unable to resolve action `astral-sh/ruff-action@v1`, unable to find version `v1`

Do you think this is simply because the action has only just gone on marketplace, is being verified, something like that? Or something else - possibly that I've done wrong!?

Thank you!

jimgar commented 2 weeks ago

Today I learned: The version needs to come from marketplace, which for latest is uses: astral-sh/ruff-action@v1.1.0

Happy to raise a PR that updates README.md to reflect this in the examples. Also understand if you prefer to do it yourselves :)

DavidJFelix commented 2 weeks ago

Shoot. I saw that when updating the README and almost corrected it. I was under the impression that github actions had some magic semver that would pick the latest v1 version, but I think this is just a common practice that folks publish a tag for major versions and update it to the latest minor. @charliermarsh do you think we should set up alias tags like v1 and v2 that map to the latest minor version in the v1.x.x and v2.x.x releases, respectively?

DavidJFelix commented 2 weeks ago

image screenshot from chartboost releases page

DavidJFelix commented 2 weeks ago

@jimgar I'm sure a PR would be welcome but this might be something worth fixing in the tag release process for folks who don't want to pin minor versions.

jimgar commented 2 weeks ago

@jimgar I'm sure a PR would be welcome but this might be something worth fixing in the tag release process for folks who don't want to pin minor versions.

Absolutely, makes sense. Will leave it with you 🙏🏻

zanieb commented 2 weeks ago

Yeah we should have aliases here

charliermarsh commented 2 weeks ago

So there’s supposed to be a v1 tag that’s mutable and constantly updated to point to the latest tagged patch release?

zanieb commented 2 weeks ago

Should be resolved now

jimgar commented 2 weeks ago

Confirmed, thanks so much peeps!