Closed pawamoy closed 4 days ago
I see this warning in Post Setup uv:
Warning: Path Validation Error: Path(s) specified in the action for caching do(es) not exist, hence no cache is being saved.
hm this is annoying because it totally worked for me – I specifically looked at this: https://github.com/hynek/setup-cached-uv/actions/runs/10108588847/job/27954818080#step:7:5
this is the same opaque error I got when I couldn’t access the cache path before moving it to /tmp
. I suppose /tmp
is not allowlisted on Windows either (now?) and we’ll have to look for another path?
Happy to try any idea you get!
Hail Mary… @webknjaz any idea what would be the best practice here?
I think, this might be happening because @pawamoy uses a different shell value than you @hynek have:
- shell: C:\Program Files\PowerShell\7\pwsh.EXE -command ". '{0}'"
+ shell: C:\Program Files\Git\bin\bash.EXE --noprofile --norc -e -o pipefail {0}
*(https://github.com/hynek/setup-cached-uv/actions/runs/10108588847/job/27954818080#step:4:4 vs. https://github.com/pawamoy/yore/actions/runs/10237910335/job/28321784155#step:5:3)
This action is running the uv install under Powershell: https://github.com/pawamoy/yore/actions/runs/10237910335/job/28321784155#step:4:19.
@pawamoy's workflow sets bash
globally: https://github.com/pawamoy/yore/actions/runs/10237910335/workflow#L11. But that doesn't influence what the action does internally.
Not sure what can be done to mitigate this. Perhaps, there could be an input that helps the action decide whether to use some other bootstrap script…
P.S. I remember that bash under Windows also had quirks (as in, they might have two versions of it), forcing me to resort to despicable hacks: https://github.com/re-actors/checkout-python-sdist/blob/1f86110/action.yml#L50-L53.
I don't even remember why I'm setting Bash as shell globally, but I'd bet it's because of the annoying operating system indeed.
OK, is there a take-away for me here? 😅
I suppose I'd consult with the uv folks or provided a way for the end-users to choose a different installation script, if that works. This might as well be a bug in uv not matching forward and back slashes..
Given #15, I think the problem is actually simpler and it’s just that I can’t access certain directories from an action in a workflow of another project. :(
I can't imagine that being the case, honestly..
How else would you explain https://github.com/omnilib/aioitertools/actions/runs/10660169548/job/29543776223?pr=193#step:12:5? I've had different behavior between an action's CI and a user's CI many times, so I wouldn't be shocked.
looks like Astral has published their own action and I don't think there's a point in competing with them so maybe check them out and see if it works over there: https://github.com/astral-sh/setup-uv
How else would you explain omnilib/aioitertools/actions/runs/10660169548/job/29543776223?pr=193#step:12:5? I've had different behavior between an action's CI and a user's CI many times, so I wouldn't be shocked.
Dunno. Restart that job in debug mode to expose what's actually happening.
looks like Astral has published their own action
Fair, wonder if it breaks for them too.
fixed by #16
Is Windows supported :relaxed:?
In the same workflow, you can check that the cache was correctly restored in both Linux and MacOS jobs.