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

{pre,post}-build: use actions/{upload,download}-artifact@v4 #529

Merged
merged 6 commits into from Apr 18, 2024

Conversation

ZhongRuoyu
Copy link
Member

@ZhongRuoyu ZhongRuoyu commented Apr 16, 2024

Companion to Homebrew/brew#17097.

Tested in ZhongRuoyu/homebrew-test#44.

Fixes #475.

ZhongRuoyu added a commit to Homebrew/homebrew-test-bot that referenced this pull request Apr 16, 2024
@ZhongRuoyu ZhongRuoyu changed the title {pre,post}-build: use actions/download-artifact@v4 {pre,post}-build: use actions/{upload,download}-artifact@v4 Apr 16, 2024
Copy link
Member

@Bo98 Bo98 left a comment

Choose a reason for hiding this comment

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

Looks great, thanks for this!

post-build/action.yml Outdated Show resolved Hide resolved
post-build/action.yml Outdated Show resolved Hide resolved
@Bo98
Copy link
Member

Bo98 commented Apr 16, 2024

Given the failed bottle name change: is there a concern for pr-pull glob matching existing runs? Might want to prioritise bottles over bottles-* if it exists.

@ZhongRuoyu
Copy link
Member Author

ZhongRuoyu commented Apr 16, 2024

Given the failed bottle name change: is there a concern for pr-pull glob matching existing runs? Might want to prioritise bottles over bottles-* if it exists.

Yes, was just thinking about this too. This is a real concern and we should avoid failed bottles generated from existing runs get accidentally picked up. Prioritising bottles seems to be a nice solution so that we won't have problems during migration.

@ZhongRuoyu
Copy link
Member Author

Actually, this also brings problems to the bottle cache workflow. We could probably just choose a different pattern. I'll go with bottles_* instead. Then we could still do bottles{,_*}.

with:
name: bottles
pattern: bottles{,_*}
Copy link
Member Author

Choose a reason for hiding this comment

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

Suggested change
pattern: bottles{,_*}
pattern: bottles_*

Because v4 cannot download v3 artifacts anyway, according to https://github.com/actions/download-artifact/tree/v4/#v4---whats-new.

This affects dependent testing, which means some of the ongoing CI jobs will fail when this is merged. Preferably the long timeout jobs should be at dep testing (i.e., after bottles are downloaded) when merging this.

Copy link
Member

@Bo98 Bo98 Apr 17, 2024

Choose a reason for hiding this comment

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

pr-pull uses REST API which wraps v3 and v4 that part is probably OK at least.

But yeah, for dep testing it's perhaps best to time this for when the CI queue is empty. I can also watch out for that opportunity similarly if needed.

post-build/action.yml Outdated Show resolved Hide resolved
Copy link
Member

@Bo98 Bo98 left a comment

Choose a reason for hiding this comment

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

actions/download-artifact in the homebrew-core dispatch-* workflows will also need updating after merging

post-build/action.yml Show resolved Hide resolved
Copy link
Member

@MikeMcQuaid MikeMcQuaid left a comment

Choose a reason for hiding this comment

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

Thanks again @ZhongRuoyu!

@ZhongRuoyu
Copy link
Member Author

Now seems to be a good time to merge this. Long-timeout jobs have both started dep testing.

@ZhongRuoyu ZhongRuoyu merged commit 462401a into master Apr 18, 2024
@ZhongRuoyu ZhongRuoyu deleted the artifact-actions-v4 branch April 18, 2024 15:24
@carlocab
Copy link
Member

🚢

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.

Support Actions Artifacts v2 (i.e. upload-artifact v4)
5 participants