Hi, I'm trying to run a pipeline with a step that uses the files from the saved artifacts of a previous step.
This was all working as intended, then one day after updating my windows runner, I started getting this error on the last step:
Remove-Item: C:\Users\admin\bitbucket\runner3\temp\1587c5ad-d391-509f-ac50-f899b6047962\1690309415217\tmp\setupArtifacts16333458990794472818.ps1:19
Line |19 | Remove-Item -Recurse -Force "C:\Users\admin\bitbucket\runner3\runner\ .
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| The system cannot find the path specified.
Where C:\Users\admin\bitbucket\runner3\runner\ is the location of the runner bin folder. I'm not sure why it's trying to run this incomplete command. The result is that only some of the artifacted folders are present in the step's working directory (I used `ls` to confirm this in the step's script), even though it says all the artifacts were successfully downloaded and extracted. Why am I getting this error and seeing this behavior?
Hello @Gabe Klavans and thank you for reaching out to Community!
Looks like the error is occurring when the runner is trying to remove the artifacts from the temporary folder where they are put after being downloaded and copied to the local build folder.
I was not able to reproduce the same error when using Windows runners with artifacts in the step, so I would suggest the following steps to try troubleshooting the issue :
Invoke-WebRequest -Uri https://product-downloads.atlassian.com/software/bitbucket/pipelines/atlassian-bitbucket-pipelines-runner-1.490.zip -OutFile .\atlassian-bitbucket-pipelines-runner.zip
Expand-Archive .\atlassian-bitbucket-pipelines-runner.zip
cd .\atlassian-bitbucket-pipelines-runner\bin
.\start.ps1 -accountUuid <rest of arguments of the predefined command you received when creating the runner>
Let me know in case you have any questions.
Thank you, @Gabe Klavans !
Patrik S
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.