Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: don't break with multiple specs, add ARTIFACT_NAME option #180

Merged
merged 3 commits into from
Apr 16, 2024

Conversation

oliverdunk
Copy link
Member

@oliverdunk oliverdunk commented Apr 16, 2024

In v2.11.0, actions/upload-artifact was updated to v4 which started to cause issues in the WebExtensions Community Group repository. In particular, v4 requires each invocation to have a unique artifact name (this was a breaking change) and that does not hold true when using spec-prod since there is no way to configure the name.

Configuration / Example failure

To resolve this, add a new input option to allow the name to be changed. After playing around for a bit this seemed like the simplest solution that would work for everyone :)


Preview | Diff

From v4, actions/upload-artifact requires each invocation to have
a unique artifact name. Add a new input option to allow the name
to be changed so spec-prod can be invoked multiple times.
action.yml Outdated Show resolved Hide resolved
docs/examples.md Outdated Show resolved Hide resolved
Copy link
Member

@sidvishnoi sidvishnoi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great @oliverdunk! Can you also add docs to docs/options.md, perhaps at the end of document?

@sidvishnoi sidvishnoi changed the title Add ARTIFACT_NAME option fix: don't break when building multiple specs, add ARTIFACT_NAME option Apr 16, 2024
action.yml Show resolved Hide resolved
@sidvishnoi sidvishnoi changed the title fix: don't break when building multiple specs, add ARTIFACT_NAME option fix: don't break with multiple specs, add ARTIFACT_NAME option Apr 16, 2024
@sidvishnoi
Copy link
Member

@oliverdunk Can you also verify it works fine by using it in a PR (perhaps for w3c/webextensions#596) before I merge this PR?
You'd need to replace uses: w3c/spec-prod@v2 with uses: oliverdunk/spec-prod@artifact-matrix-fix

@oliverdunk
Copy link
Member Author

This is great @oliverdunk! Can you also add docs to docs/options.md, perhaps at the end of document?

Good call, done! I added it in the middle to be consistent with the ordering in the YML but feel free to move.

@oliverdunk
Copy link
Member Author

Can you also verify it works fine by using it in a PR (perhaps for w3c/webextensions#596) before I merge this PR?

I tested it here which is hopefully a good enough dry run: https://github.com/oliverdunk/webextensions/actions/runs/8706490856/job/23879164260

If you'd really like to see it run in the main repository, let me know and happy to do that.

@sidvishnoi
Copy link
Member

Brilliant! That dry run is more than enough. Thanks for the PR @oliverdunk!

@sidvishnoi sidvishnoi merged commit 5cf6473 into w3c:main Apr 16, 2024
2 checks passed
github-actions bot added a commit that referenced this pull request Apr 16, 2024
SHA: 5cf6473
Reason: push, by sidvishnoi

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@oliverdunk oliverdunk deleted the artifact-matrix-fix branch April 16, 2024 14:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants