Autocompletion using c#node in Bonsai2.4

93 views
Skip to first unread message

Bruno Cruz

unread,
Jul 10, 2018, 2:53:07 PM7/10/18
to Bonsai Users
Hi,

I am trying to check out the new node in Bonsai 2.4. Just to give some background:

.I have bonsai 2.3 installed in the default directory
.I have visual studio installed (2017)
.I downloaded 2.4-preview from the repository
.The simple script works (Int -> C#node) 

Basically the problem is the fact that i cant use autocompletion on the visual studio extension. Moreover, i get the following output (not sure if it is related): 
Can i get some quick tips on how to have the 2 versions running on the same machine and how to configure the extension correctly?

Thanks,

Bruno


"Starting OmniSharp server at 7/10/2018, 7:44:04 PM
    Target: c:\Users\Bruno Cruz\Desktop\tests

OmniSharp server started
    Path: C:\Users\Bruno Cruz\.vscode\extensions\ms-vscode.csharp-1.15.2\.omnisharp\1.30.1\OmniSharp.exe
    PID: 18148

[info]: OmniSharp.Stdio.Host
        Starting OmniSharp on Windows 6.2.9200.0 (x64)
[info]: OmniSharp.MSBuild.Discovery.MSBuildLocator
        Located 1 MSBuild instance(s)
            1: StandAlone 15.0 - "C:\Users\Bruno Cruz\.vscode\extensions\ms-vscode.csharp-1.15.2\.omnisharp\1.30.1\msbuild\15.0\Bin"
[info]: OmniSharp.MSBuild.Discovery.MSBuildLocator
        MSBUILD_EXE_PATH environment variable set to 'C:\Users\Bruno Cruz\.vscode\extensions\ms-vscode.csharp-1.15.2\.omnisharp\1.30.1\msbuild\15.0\Bin\MSBuild.exe'
[info]: OmniSharp.MSBuild.Discovery.MSBuildLocator
        Registered MSBuild instance: StandAlone 15.0 - "C:\Users\Bruno Cruz\.vscode\extensions\ms-vscode.csharp-1.15.2\.omnisharp\1.30.1\msbuild\15.0\Bin"
            CscToolExe = csc.exe
            CscToolPath = C:\Users\Bruno Cruz\.vscode\extensions\ms-vscode.csharp-1.15.2\.omnisharp\1.30.1\msbuild\15.0\Bin\Roslyn
            MSBuildExtensionsPath = C:\Users\Bruno Cruz\.vscode\extensions\ms-vscode.csharp-1.15.2\.omnisharp\1.30.1\msbuild
            MSBuildToolsPath = C:\Users\Bruno Cruz\.vscode\extensions\ms-vscode.csharp-1.15.2\.omnisharp\1.30.1\msbuild\15.0\Bin
[info]: OmniSharp.Cake.CakeProjectSystem
        Detecting Cake files in 'c:\Users\Bruno Cruz\Desktop\tests'.
[info]: OmniSharp.Cake.CakeProjectSystem
        Could not find any Cake files
[info]: OmniSharp.DotNet.DotNetProjectSystem
        Initializing in c:\Users\Bruno Cruz\Desktop\tests
[info]: OmniSharp.DotNet.DotNetProjectSystem
        Auto package restore: False
[info]: OmniSharp.DotNet.DotNetProjectSystem
        Update workspace context
[info]: OmniSharp.DotNet.DotNetProjectSystem
        Resolving projects references
[info]: OmniSharp.MSBuild.ProjectSystem
        No solution files found in 'c:\Users\Bruno Cruz\Desktop\tests'
[info]: OmniSharp.MSBuild.ProjectManager
        Queue project update for 'c:\Users\Bruno Cruz\Desktop\tests\Extensions.csproj'
[info]: OmniSharp.Script.ScriptProjectSystem
        Detecting CSX files in 'c:\Users\Bruno Cruz\Desktop\tests'.
[info]: OmniSharp.Script.ScriptProjectSystem
        Could not find any CSX files
[info]: OmniSharp.Stdio.Host
        Invoking Workspace Options Provider: OmniSharp.Roslyn.CSharp.Services.CSharpWorkspaceOptionsProvider
[info]: OmniSharp.Stdio.Host
        Configuration finished.
[info]: OmniSharp.Stdio.Host
        Omnisharp server running using Stdio at location 'c:\Users\Bruno Cruz\Desktop\tests' on host 13888.
[info]: OmniSharp.MSBuild.ProjectManager
        Loading project: c:\Users\Bruno Cruz\Desktop\tests\Extensions.csproj
[fail]: OmniSharp.MSBuild.ProjectLoader
        Unable to find package Bonsai.Core with version (>= 2.4.0-preview)
  - Found 18 version(s) in nuget.org [ Nearest version: 2.3.0 ]
[warn]: OmniSharp.MSBuild.ProjectManager
        Failed to load project file 'c:\Users\Bruno Cruz\Desktop\tests\Extensions.csproj'.
c:\Users\Bruno Cruz\Desktop\tests\Extensions.csproj
c:\Users\Bruno Cruz\Desktop\tests\Extensions.csproj(0,0): Error: Unable to find package Bonsai.Core with version (>= 2.4.0-preview)
  - Found 18 version(s) in nuget.org [ Nearest version: 2.3.0 ]"

Gonçalo Lopes

unread,
Aug 14, 2018, 5:29:20 AM8/14/18
to Bruno Cruz, Bonsai Users
Hi Bruno,

Sorry for taking so long to follow-up, I somehow didn't notice this post earlier. Were you able to work around this?
Intellisense should work fine both on Visual Studio Code and Visual Studio 2017.

Try installing the latest version and let me know if you still have issues.

I will post more information about C# scripting support soon.


--
You received this message because you are subscribed to the Google Groups "Bonsai Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bonsai-users+unsubscribe@googlegroups.com.
Visit this group at https://groups.google.com/group/bonsai-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/bonsai-users/0b577cc6-0ad5-44c4-9a60-1a08dc653641%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Gonçalo Lopes

unread,
Aug 14, 2018, 5:31:15 AM8/14/18
to Bruno Cruz, Bonsai Users
Ah, actually the problem is you need to point NuGet to the Gallery repository that comes with the 2.4.0-preview.zip file.

Looking into the error message more carefully there is the hint in the last line. This won't happen after the official release, but for now you need to set your paths manually so that Visual Studio can download the dependency packages for intellisense.

On 14 August 2018 at 10:29, Gonçalo Lopes <goncal...@gmail.com> wrote:
Hi Bruno,

Sorry for taking so long to follow-up, I somehow didn't notice this post earlier. Were you able to work around this?
Intellisense should work fine both on Visual Studio Code and Visual Studio 2017.

Try installing the latest version and let me know if you still have issues.

I will post more information about C# scripting support soon.

Reply all
Reply to author
Forward
0 new messages