Skip to content

Commit 4cff9e7

Browse files
committed
PR feedback: UnexpectedException
1 parent 8a9028f commit 4cff9e7

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

src/FSharpLint.Client/FSharpLintToolLocator.fs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ let private startProcess (ps: ProcessStartInfo) : Result<Process, ProcessStartEr
5454
win32ex.Message
5555
)
5656
)
57-
| ex -> Error(ProcessStartError.UnExpectedException(ps.FileName, ps.Arguments, ex.Message))
57+
| ex -> Error(ProcessStartError.UnexpectedException(ps.FileName, ps.Arguments, ex.Message))
5858

5959
let private runToolListCmd (workingDir: Folder) (globalFlag: bool) : Result<string list, DotNetToolListError> =
6060
let ps = ProcessStartInfo("dotnet")
@@ -166,7 +166,7 @@ let private fsharpLintVersionOnPath () : (FSharpLintExecutableFile * FSharpLintV
166166
else
167167
None)
168168
| Error(ProcessStartError.ExecutableFileNotFound _)
169-
| Error(ProcessStartError.UnExpectedException _) -> None)
169+
| Error(ProcessStartError.UnexpectedException _) -> None)
170170

171171
let findFSharpLintTool (workingDir: Folder) : Result<FSharpLintToolFound, FSharpLintToolError> =
172172
// First try and find a local tool for the folder.
@@ -248,5 +248,5 @@ let createFor (startInfo: FSharpLintToolStartInfo) : Result<RunningFSharpLintToo
248248
else
249249
ex.Message
250250

251-
Error(ProcessStartError.UnExpectedException(processStart.FileName, processStart.Arguments, error))
251+
Error(ProcessStartError.UnexpectedException(processStart.FileName, processStart.Arguments, error))
252252
| Error err -> Error err

src/FSharpLint.Client/LSPFSharpLintService.fs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,10 +192,10 @@ let private daemonNotFoundResponse filePath (error: GetDaemonError) : Task<FShar
192192
error)) ->
193193
$"FSharpLint.Client tried to run `%s{executableFile} %s{arguments}` inside working directory \"{workingDirectory}\" but could not find \"%s{executableFile}\" on the PATH (%s{pathEnvironmentVariable}). Error: %s{error}",
194194
FSharpLintResponseCode.ErrDaemonCreationFailed
195-
| GetDaemonError.DotNetToolListError(DotNetToolListError.ProcessStartError(ProcessStartError.UnExpectedException(executableFile,
195+
| GetDaemonError.DotNetToolListError(DotNetToolListError.ProcessStartError(ProcessStartError.UnexpectedException(executableFile,
196196
arguments,
197197
error)))
198-
| GetDaemonError.FSharpLintProcessStart(ProcessStartError.UnExpectedException(executableFile, arguments, error)) ->
198+
| GetDaemonError.FSharpLintProcessStart(ProcessStartError.UnexpectedException(executableFile, arguments, error)) ->
199199
$"FSharpLint.Client tried to run `%s{executableFile} %s{arguments}` but failed with \"%s{error}\"",
200200
FSharpLintResponseCode.ErrDaemonCreationFailed
201201
| GetDaemonError.DotNetToolListError(DotNetToolListError.ExitCodeNonZero(executableFile,

src/FSharpLint.Client/LSPFSharpLintServiceTypes.fs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ type ProcessStartError =
5555
workingDirectory: string *
5656
pathEnvironmentVariable: string *
5757
error: string
58-
| UnExpectedException of executableFile: string * arguments: string * error: string
58+
| UnexpectedException of executableFile: string * arguments: string * error: string
5959

6060
[<RequireQualifiedAccess>]
6161
type DotNetToolListError =

src/FSharpLint.Client/LSPFSharpLintServiceTypes.fsi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ type ProcessStartError =
3838
workingDirectory: string *
3939
pathEnvironmentVariable: string *
4040
error: string
41-
| UnExpectedException of executableFile: string * arguments: string * error: string
41+
| UnexpectedException of executableFile: string * arguments: string * error: string
4242

4343
[<RequireQualifiedAccess>]
4444
type DotNetToolListError =

0 commit comments

Comments
 (0)