You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 8, 2020. It is now read-only.
I'm following the example for using node services in a non aspnet core app. I'm getting an exception when calling InvokeAsync, related to the ProjectPath:
System.AggregateException occurred
HResult=0x80131500
Message=One or more errors occurred.
Source=<Cannot evaluate the exception source>
StackTrace:
at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
at System.Threading.Tasks.Task`1.GetResultCore(Boolean waitCompletionNotification)
at NodeServices.Program.Main(String[] args) in M:\Dev\examples\test-aspnet-core-spa-template\NodeServices\NodeServices\Program.cs:line 22
Inner Exception 1:
ArgumentNullException: Value cannot be null. Parameter Path1
stack trace:
" at System.IO.Path.Combine(String path1, String path2)\r\n
at Microsoft.AspNetCore.NodeServices.HostingModels.OutOfProcessNodeInstance.PrepareNodeProcessStartInfo(String entryPointFilename, String projectPath, String commandLineArguments, IDictionary`2 environmentVars, Boolean launchWithDebugging, Int32 debuggingPort)\r\n
at Microsoft.AspNetCore.NodeServices.HostingModels.OutOfProcessNodeInstance..ctor(String entryPointScript, String projectPath, String[] watchFileExtensions, String commandLineArguments, CancellationToken applicationStoppingToken, ILogger nodeOutputLogger, IDictionary`2 environmentVars, Int32 invocationTimeoutMilliseconds, Boolean launchWithDebugging, Int32 debuggingPort)\r\n
at Microsoft.AspNetCore.NodeServices.HostingModels.HttpNodeInstance..ctor(NodeServicesOptions options, Int32 port)\r\n
at Microsoft.AspNetCore.NodeServices.HostingModels.NodeServicesOptionsExtensions.<>c__DisplayClass0_0.<UseHttpHosting>b__0()\r\n
at Microsoft.AspNetCore.NodeServices.NodeServicesImpl.CreateNewNodeInstance()\r\n
at Microsoft.AspNetCore.NodeServices.NodeServicesImpl.GetOrCreateCurrentNodeInstance()\r\n
at Microsoft.AspNetCore.NodeServices.NodeServicesImpl.<InvokeExportWithPossibleRetryAsync>d__10`1.MoveNext()"
I dont think that ProjectPath is being set to the Project root directory. When I set ProjectPath to './', everything works:
If this is truly the case, I can update the README for nodeServices to be explicit in how to use NodeServices for non aspnet core projects. For the record, the instructions for aspnet core is correct (i.e. project path is set correctly).
The text was updated successfully, but these errors were encountered:
mcMickJuice
changed the title
Process fails in non Asp.Net
Exception thrown in non aspnet core example for NodeServices
Aug 18, 2017
Thanks for reporting this. I think it's a duplicate of #1100 so I'll close this one. I think we should change the default to use the process's current working directory if no other dir was specified.
I'm following the example for using node services in a non aspnet core app. I'm getting an exception when calling InvokeAsync, related to the ProjectPath:
stack trace:
I dont think that ProjectPath is being set to the Project root directory. When I set ProjectPath to './', everything works:
If this is truly the case, I can update the README for nodeServices to be explicit in how to use NodeServices for non aspnet core projects. For the record, the instructions for aspnet core is correct (i.e. project path is set correctly).
The text was updated successfully, but these errors were encountered: