-
Notifications
You must be signed in to change notification settings - Fork 7
VSTS Hosted VS2017 Agent can't find fsi.exe #27
Description
Description
I'm trying to use the "Execute F# Script" task on a Hosted VS2017 agent, but it gives me the following error: "The system cannot find the path specified.". This is because the task it trying to run fsi.exe from the C:\Program Files (x86)\Microsoft SDKs\F#\4.1\Framework\v4.0\ folder. This used to work, but fsi.exe can now be found in the dotnet core sdk (i.e. C:\Program Files\dotnet\sdk\2.1.400\FSharp).
Maybe I'm missing something and this can be fixed easily by my side, but I just can't figure it out.
Repro steps
-
Create a build pipeline
-
Set Agent Pool to Hosted VS2017
-
Add "Execute F# Script" task and select the fsx
-
Queue the build
Expected behavior
fsx script gets executed
Actual behavior
error: "The system cannot find the path specified."
Details
2018-09-18T09:47:14.7799699Z ##[debug]Evaluating condition for step: 'Deploy Plugins'
2018-09-18T09:47:14.7800261Z ##[debug]Evaluating: succeeded()
2018-09-18T09:47:14.7800455Z ##[debug]Evaluating succeeded:
2018-09-18T09:47:14.7800694Z ##[debug]=> True
2018-09-18T09:47:14.7800952Z ##[debug]Result: True
2018-09-18T09:47:14.7801281Z ##[section]Starting: Deploy Plugins
2018-09-18T09:47:14.7858892Z ==============================================================================
2018-09-18T09:47:14.7859029Z Task : Execute F# Script
2018-09-18T09:47:14.7859124Z Description : Executes an F# .fsx script file
2018-09-18T09:47:14.7859211Z Version : 0.4.1
2018-09-18T09:47:14.7859301Z Author : Isaac Abraham
2018-09-18T09:47:14.7859566Z Help : This task executes an arbitrary .fsx file.
2018-09-18T09:47:14.7859672Z ==============================================================================
2018-09-18T09:47:14.7949577Z ##[debug]Working directory: 'D:\a_tasks\FSharpScript_1ba72b0a-f476-4a91-90a0-b8e7a0cc4337\0.4.1\DefaultTaskWorkingDirectory'
2018-09-18T09:47:14.7951772Z ##[debug]Fail on standard error: 'True'
2018-09-18T09:47:14.7951906Z ##[debug]Modify environment: 'False'
2018-09-18T09:47:14.7952065Z ##[debug]C:\Windows\system32\cmd.exe /c ""C:\Program Files (x86)\Microsoft SDKs\F#\4.1\Framework\v4.0\fsi.exe" "D:\a\1\s\AOMetalektro.CRM\Scripts\Daxif\PluginSyncDev.fsx" "
2018-09-18T09:47:14.7952285Z ##[command]"C:\Program Files (x86)\Microsoft SDKs\F#\4.1\Framework\v4.0\fsi.exe" "D:\a\1\s\AOMetalektro.CRM\Scripts\Daxif\PluginSyncDev.fsx"
2018-09-18T09:47:14.8188366Z ##[error]The system cannot find the path specified.
2018-09-18T09:47:14.8209493Z ##[error]Process completed with exit code 1 and had 1 error(s) written to the error stream.
2018-09-18T09:47:14.8219076Z ##[debug]System.Exception: Process completed with exit code 1 and had 1 error(s) written to the error stream.
at Microsoft.VisualStudio.Services.Agent.Worker.Handlers.ProcessHandler.d__10.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.VisualStudio.Services.Agent.Worker.TaskRunner.d__24.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.VisualStudio.Services.Agent.Worker.StepsRunner.d__1.MoveNext()
2018-09-18T09:47:14.8221045Z ##[section]Finishing: Deploy Plugins
Known workarounds
I might be able to run the F# script using powershell, but that would be without using this task entirely.