Ionide-vscode-fsharp: Include FSI in package

Created on 18 Nov 2015  路  8Comments  路  Source: ionide/ionide-vscode-fsharp

Getting an exception when I try to eval let x = ""

[Plugin Host] This socket is closed.
workbench.main.js:1602 [Plugin Host] Object {}
workbench.main.js:1602 [Plugin Host] {"Kind":"error","Data":"File 'C:\\3' not parsed"}
workbench.main.js:1602 [Plugin Host] unhandled rejected promise Object {}(anonymous function) @ workbench.main.js:1602emitTwo @ events.js:87emit @ events.js:172handleMessage @ internal/child_process.js:685channel.onread @ internal/child_process.js:440
workbench.main.js:1626 errore.onUnexpectedError @ workbench.main.js:1626(anonymous function) @ workbench.main.js:1626e.onUnexpectedError @ workbench.main.js:1548u @ workbench.main.js:1547e.onUnexpectedPluginHostError @ workbench.main.js:1604e.handle @ workbench.main.js:1588a @ workbench.main.js:1576h.handle @ workbench.main.js:1576(anonymous function) @ workbench.main.js:1602(anonymous function) @ workbench.main.js:1602emitTwo @ events.js:87emit @ events.js:172handleMessage @ internal/child_process.js:685channel.onread @ internal/child_process.js:440
workbench.main.js:1602 [Plugin Host] [E] 2015-11-18T21:26:55.9116471Z: request failed [Suave.Web.defaultErrorHandler] exn:
Microsoft.FSharp.Compiler.ErrorLogger+WrappedError: Exception of type 'Microsoft.FSharp.Compiler.ErrorLogger+WrappedError' was thrown.
   at Microsoft.FSharp.Compiler.Lexhelp.reusingLexbufForParsing[a](LexBuffer`1 lexbuf, FSharpFunc`2 f)
   at Microsoft.FSharp.Compiler.Lexhelp.usingLexbufForParsing[a](LexBuffer`1 lexbuf, String filename, FSharpFunc`2 f)
   at Microsoft.FSharp.Compiler.SourceCodeServices.Parser.ParseOneFile(String source, Boolean matchBracesOnly, Boolean reportErrors, String mainInputFileName, FSharpList`1 projectSourceFiles, TcConfig tcConfig)
   at <StartupCode$FSharp-Compiler-Service>[email protected](CancellationToken _ct)
   at <StartupCode$FSharp-Compiler-Service>[email protected](Unit unitVar0)

enhancement

Most helpful comment

fsi (or fsharpi on Mac) needs to be in PATH. For windows it's usually C:\Program Files (x86)\Microsoft SDKs\F#\4.0\Framework\v4.0

All 8 comments

fsi (or fsharpi on Mac) needs to be in PATH. For windows it's usually C:\Program Files (x86)\Microsoft SDKs\F#\4.0\Framework\v4.0

Would it be possible to check a few common locations for fsi? Seems a bad experience for noobs to have to go edit there path variable to use one of the coolest parts of fsharp.

have the same problem. would be cool if fsi gets setup in the background...

Got the following Error-message:
Running the contributed command:'fsi.SendSelection' failed.

+1 on having this handled automatically instead of us having to search for this on the web

@nesteruk Absolutely - I almost wrote off using F# interactive in VS Code due to this. I thought my F# skills were failing me!

It would be great to find the default install location and also support a configuration setting. Here's the place where fsi.exe is being spawned:

https://github.com/ionide/ionide-vscode-fsharp/blob/2aad7e294d8a3c0da2106d36c7d9c6f12a8ef0b7/src/Components/Fsi.fs#L25

Possibly the ionide package could also include an fsi.exe

Also, fsi.exe is 32-bit, by default it's probably better to run fsiAnyCpu.exe

In last couple of weeks we've added both auto-detecting FSI installation path (checking some usual places), added setting for F# tools dir, and setting for FSI executable name (so users can switch between AnyCPU/32/64 bits versions).

I guess that's good enough for now.

Added settings:

     // The directory containing the F# tools (Checking usual places if empty)
    "FSharp.toolsDirPath": "",

    // The path to Mono executable
    "FSharp.monoPath": "mono",

    // The path to the F# Interactive tool used by Ionide-FSharp (AnyCPU if empty)
    "FSharp.fsiFilePath": "",
Was this page helpful?
0 / 5 - 0 ratings

Related issues

cartermp picture cartermp  路  4Comments

isaacabraham picture isaacabraham  路  4Comments

MikaelUmaN picture MikaelUmaN  路  5Comments

vasily-kirichenko picture vasily-kirichenko  路  6Comments

sergey-tihon picture sergey-tihon  路  6Comments