-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
allow path parameter to be a YAML list #510
Comments
This issue is stale because it has been open for 365 days with no activity. Leave a comment to avoid closing this issue in 5 days. |
Bad bot, this is not stale. |
This also hit me before I realized the cache wasn't working... I found this comment in #44. |
Otherwise, those comments are interpreted as part of the path and the cache doesn't work. See actions/cache#510
This issue is stale because it has been open for 200 days with no activity. Leave a comment to avoid closing this issue in 5 days. |
This issue is NOT stale. I would really appreciate it if your bot stopped pestering me every year. I would very much prefer to get any response from the maintainers, of course. |
It troubled me greatly when I wrote a tutorial about utilizing the action cache. In a tutorial, it's inevitable to use line comments. I'm surprised the string is treated in such a simple way. I agree with the comment above that it is a bug. |
This issue is stale because it has been open for 200 days with no activity. Leave a comment to avoid closing this issue in 5 days. |
Again NOT STALE. |
The README example shows how
with.path
is meant to be specified - as a multi-line YAML string:This correlates with what we can see in the code:
cache/src/utils/actionUtils.ts
Lines 56 to 65 in 3543324
Unfortunately, this format is rather unfriendly to humans. It does not allow inline comments, for example, which would be really useful to document why certain paths are being cached. Worse even, attempting to use YAML-like comments results in silently broken caching; see mvdan/github-actions-golang#16.
I assume this is rooted at how action inputs are strings. At an internal level, that makes sense. However, at the user-facing YAML level, I think this action should take a YAML list, not a list-encoded-in-newline-separated-strings multiline string. Internally, the Actions software could turn the YAML list into the newline-separated string, and that could be entirely transparent to the user:
I realise this is probably an issue that cannot be fixed in this repository alone, but I still think it belongs in this repository as it is a very clear example that's making actions/cache harder to use properly. I'm completely fine with this issue being moved elsewhere, but please don't close it as "not a bug in this repository" :)
The text was updated successfully, but these errors were encountered: