Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add vscode support #1356

Open
wants to merge 1 commit into
base: release-7.x
Choose a base branch
from
Open

Conversation

paule96
Copy link

@paule96 paule96 commented Dec 9, 2018

Issues

This have no Issue.

Description

This add the build assets to hit F5 in vscode too.
This comes from the PR #1348 and has been discussed with @mikepizzo .

Checklist (Uncheck if it is not completed)

  • Test cases added -> no because I don't change code
  • Build and test with one-click build and test script passed -> no because I don't change code

@mikepizzo mikepizzo added the Ready for review Use this label if a pull request is ready to be reviewed label Dec 12, 2018
"request": "launch",
"preLaunchTask": "build",
// If you have changed target frameworks, make sure to update the program path.
"program": "${workspaceFolder}/test/FunctionalTests/Microsoft.OData.Core.Tests/bin/Debug/netcoreapp1.0/Microsoft.OData.Core.Tests.dll",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we have configurations other than core?

"type": "process",
"args": [
"build",
"${workspaceFolder}/test/FunctionalTests/Microsoft.OData.Core.Tests/Microsoft.OData.Core.Tests.NetCore.csproj"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we have tasks for projects other than netcore.csproj?

@paule96
Copy link
Author

paule96 commented Dec 13, 2018

@mikepizzo your are right. I doesn't check what vscode has created. (in my normal projects it's works)
I'm sorry for that.

I have try to get this working but have some questions. There is a build.p1 in the root of this repo. But this always fails by the build of OData.Tests.E2E.NetCore.VS2017.sln.

If I look in the build log I see that the restoring of the dotnet core projects not working right. It doesn't create a project.assets.json.

So I search for this error in the WWW and found this. This means maybe we use the wrong nuget.exe. So I looked in the sln\.nuget folder and check the version. The nuget version there is currently the 3.5.0.1996. So I have tryed some nuget versions but only 3.5.0.1996 will work wih the rest of the project. So I'm not shure what todo with this.

But this is not my main problem. My main problem is that I can't run the dotnet core projects because there are everywhere \ instead of /. So dotnet build fails with this error:

Illegales Zeichen im Pfad.

in englisch it means:

Illegal character in path

So if I replace all \ with / in all build files (*.csproj, *.sln, *.props, *.config, *.json, *.targets) the build process works fine instead of the OData.Tests.E2E.NetCore.VS2017.sln. But if I now try to run dotnet build test/FunctionalTests/Microsoft.OData.Core.Tests/Microsoft.OData.Core.Tests.NetCore.csproj this fails with this error message:

H:\develop\odata.net\sln\packages\StyleCop.MSBuild.4.7.49.0\build\StyleCop.MSBuild.Targets(98,5): error MSB4062: Die StyleCopTask-Aufgabe konnte nicht aus der H:\develop\odata.net\sln\packages\StyleCop.MSBuild.4.7.49.0\build\..\tools\StyleCop.dll-Assembly geladen werden. Could not load file or assembly 'System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'. Das System kann die angegebene Datei nicht finden. Stellen Sie sicher, dass die <UsingTask>-Deklaration korrekt ist, die Assembly und alle zugehörigen Abhängigkeiten verfügbar sind und die Aufgabe eine öffentliche Klasse enthält, die Microsoft.Build.Framework.ITask implementiert. [H:\develop\odata.net\src\Microsoft.Spatial\Microsoft.Spatial.NetStandard.VS2017.csproj]
H:\develop\odata.net\sln\packages\StyleCop.MSBuild.4.7.49.0\build\StyleCop.MSBuild.Targets(98,5): error MSB4062: Die StyleCopTask-Aufgabe konnte nicht aus der H:\develop\odata.net\sln\packages\StyleCop.MSBuild.4.7.49.0\build\..\tools\StyleCop.dll-Assembly geladen werden. Could not load file or assembly 'System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'. Das System kann die angegebene Datei nicht finden. Stellen Sie sicher, dass die <UsingTask>-Deklaration korrekt ist, die Assembly und alle zugehörigen Abhängigkeiten verfügbar sind und die Aufgabe eine öffentliche Klasse enthält, die Microsoft.Build.Framework.ITask implementiert. [H:\develop\odata.net\src\Microsoft.OData.Edm\Microsoft.OData.Edm.NetStandard.VS2017.csproj]

so in conclusion I have to question:

  1. Is it normal that build.ps1 throws an error?
  2. How to build the dotnet core stuff in this project?

Befor this isn't clear I can't add the vscode support to this project for build and debug.

@mikepizzo
Copy link
Member

Thanks for the follow-up @paule96. Assigning this to @KanishManuja-MS, who is on-call this week, to follow up on the build issues.

@madansr7 madansr7 removed the Ready for review Use this label if a pull request is ready to be reviewed label Dec 17, 2018
@madansr7 madansr7 added this to the vNext milestone Dec 17, 2018
Copy link
Contributor

@KanishManuja-MS KanishManuja-MS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@paule96 This is interesting. The build should work fine, I wonder if it has to do with the locale setting for you?

@xuzhg xuzhg force-pushed the master branch 2 times, most recently from f9519fd to 14a4b12 Compare September 22, 2019 21:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants