Issue with Powershell task hanging at the end of execution

Issue #41 open
daniel ramazani created an issue

We noticed one particular Bamboo Build Plan cannot use the Powershell Task anymore.

Even when we add a very simple Powershell Task with one line, it always displays “Access Denied”

Example:

simple 23-Aug-2023 16:53:07 Starting task 'PowerShell Task' of type 'com.stellarity.bamboo.powershell-task:powerShellTask'
simple 23-Aug-2023 16:53:07 Loading the current user profile: NO
simple 23-Aug-2023 16:53:07 Requested bitness: ANY
command 23-Aug-2023 16:53:07 Beginning to execute external process for build 'AD0000 - AD0000_MOPS_CORE_v31 - feature-resolve-assigned-sonarcube-warnings - Nexus #42 (AD0000-AD0000MOPSCOREV31256-NEX-42)'\n ... running command line: \nC:\Users\svc.svc.toolsbuild\AppData\Local\Temp\AD0000-AD0000MOPSCOREV31256-NEX-42-PowerShellTask-14470045279956507.cmd\n ... in: D:\builds\1\AD0000-AD0000MOPSCOREV31256-NEX\nbamboo_planRepository_1_branch=feature/BA...... [PRUNED DELIBERATELY]
error 23-Aug-2023 16:53:08 Access is denied.
simple 23-Aug-2023 16:53:08 Failing task since return code of [C:\Users\svc.svc.toolsbuild\AppData\Local\Temp\AD0000-AD0000MOPSCOREV31256-NEX-42-PowerShellTask-14470045279956507.cmd] was 1 while expected 0
simple 23-Aug-2023 16:53:08 Finished task 'PowerShell Task' with result: Failed

We were able to workaround the issue by cloning the plan exactly how it was before which now works fine, but we’re curious if there’s another way to deal with this problem.

We don’t think its exactly linked to the Build Agent, because we ran the job on other build agents including agents that had never run this job before.

Plugin version: 1.2.9

Bamboo Version: 9.2.3

Comments (2)

  1. Log in to comment