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: validate secrets before action resolution #6822

Merged
merged 26 commits into from
Feb 6, 2025

Conversation

vvagaytsev
Copy link
Collaborator

What this PR does / why we need it:

Validate missing secrets when instantiating a ResolveActionTask , rather than when adding configs.
This would ensure we only get the error when missing secrets would actually cause a failure for the given command, while still failing relatively early even if the action happens to use another action’s outputs.

Which issue(s) this PR fixes:

Fixes #

Special notes for your reviewer:

 Validate missing secrets when instantiating a `ResolveActionTask` , rather than when adding configs.
 This would ensure we only get the error when missing secrets would actually cause a failure for the given command, while still failing relatively early even if the action happens to use another action’s outputs.
…r if action references missing secrets when user is not logged in
…erences missing secrets

The missing secrets check was moved to `ResolveActionTask` constructor.
…erences missing secrets

The missing secrets check was moved to `ResolveActionTask` constructor.
Copy link
Member

@stefreak stefreak left a comment

Choose a reason for hiding this comment

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

Great work! 👍 I had a preliminary look and already sharing some things that I noticed

@vvagaytsev vvagaytsev requested review from eysi09 and stefreak February 6, 2025 10:05
@vvagaytsev vvagaytsev marked this pull request as ready for review February 6, 2025 10:05
stefreak
stefreak previously approved these changes Feb 6, 2025
Copy link
Member

@stefreak stefreak 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 amazing! Thank you for looking into this.

I have additional suggestions regarding the error messages, those are totally fine as follow-up or in this PR as well, as you wish!

@vvagaytsev vvagaytsev requested a review from stefreak February 6, 2025 13:49
@vvagaytsev vvagaytsev enabled auto-merge February 6, 2025 13:49
Copy link
Member

@stefreak stefreak left a comment

Choose a reason for hiding this comment

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

Super Awesome!

@vvagaytsev vvagaytsev added this pull request to the merge queue Feb 6, 2025
Merged via the queue into main with commit 55e7308 Feb 6, 2025
40 checks passed
@vvagaytsev vvagaytsev deleted the fix/missing-secrets-validation branch February 6, 2025 15:41
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