-
-
Notifications
You must be signed in to change notification settings - Fork 3
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
Add input type validation #16
Conversation
I'm still unsure how the |
It is used by custom maven repo proxies to generate bindings on the fly, so no, it is not run on any consumer. In a kotlin script, you add a maven repo from where you resolve actions as if they were packages, and the repo will try to generate bindings if missing, by using the metadata here. |
This makes even less likely to apply the PR at this moment. |
The action types YAML is simply an emerging standard to clearly document the types of inputs and outputs of GitHub actions in a standardized way that can be consumed by other projects. Normal users of your action are not affected in any significant way, except that they can manually read this type definition. One of the consumers of these typings is the project https://github.com/typesafegithub/github-workflows-kt, a Kotlin DSL to write GitHub Action workflows. It uses the typings to generate more type-safe binding classes and thus makes using such actions more convenient. The (optional) action just validates that the typings file is in the proper format and consistent with the action YAML. With having such typings, you action would also be in good company, like e.g. my https://github.com/Vampire/setup-wsl or also Microsoft's https://github.com/microsoft/setup-msbuild. Also "regular" users can benefit from this clear and formalized typing definition, seeing exactly what values are valid. When accepting this PR and in the future maintaining the typing yourself, |
If it's an emerging standard I'll wait for an official announcement from GitHub as well as an action provided by GitHub to validate the types. Software supply chain attacks are on the rise. This feature is closer to the infrastructure used to run actions and as such should be provided by the owners/makers and not a 3rd party IMHO. |
I did not say it is a standard driven by GitHub. 🙈 |
I'm actually not sure what you mean with supply-chain attacks in this context. |
If it's not a standard driven by GitHub then it makes no sense to apply this PR at this moment for the security and provenance reasons mentioned before. I'll wait for GitHub to provide such feature, if ever. @desiderantes thank you for taking the time to send this PR but I'll close without merging for now. |
Please don't get me wrong, it is fully ok not to merge it, thus I'm not trying to convince you from anything. But I'm really just curious which "security and provenance reasons" you see not to add one YAML file where you document types in a defined way. Maybe there is something I'm just not aware of and should myself stop providing this text file for my action. |
This change add a simple validation for input types, fixes the doc for one of the inputs, and allows projects using typesafe github actions to use this action.