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

Dependency conflict when project.json reference csproj #2865

Closed
rrelyea opened this Issue May 31, 2016 · 6 comments

Comments

Projects
None yet
6 participants
@rrelyea
Contributor

rrelyea commented May 31, 2016

Port of dotnet/cli#3205

@jainaashish

This comment has been minimized.

Show comment
Hide comment
@jainaashish

jainaashish Jun 6, 2016

Contributor

This works fine in VS or through msbuild but not with dotnet restore which is as designed as of now.

@sayedihashimi dotnet restore works only with xproj in current design and will need framework changes to support csproj.

Contributor

jainaashish commented Jun 6, 2016

This works fine in VS or through msbuild but not with dotnet restore which is as designed as of now.

@sayedihashimi dotnet restore works only with xproj in current design and will need framework changes to support csproj.

@jainaashish jainaashish assigned rrelyea and unassigned jainaashish Jun 6, 2016

@BrianVallelunga

This comment has been minimized.

Show comment
Hide comment
@BrianVallelunga

BrianVallelunga Jun 13, 2016

@jainaashish If I understand you correctly, then it is literally impossible to build a combined project.json + csproj solution right now with msbuild and that's as designed? If you read the linked issues, you'll see people are trying to build simple sites that reference a csproj project on a build server and the build is breaking, while working in VS.

BrianVallelunga commented Jun 13, 2016

@jainaashish If I understand you correctly, then it is literally impossible to build a combined project.json + csproj solution right now with msbuild and that's as designed? If you read the linked issues, you'll see people are trying to build simple sites that reference a csproj project on a build server and the build is breaking, while working in VS.

@rrelyea rrelyea modified the milestones: 3.5 Beta3, 3.5 Beta2 Jun 14, 2016

@rrelyea rrelyea modified the milestones: 3.6 Beta, 3.5 RTM Jul 19, 2016

@rrelyea rrelyea modified the milestones: 4.0 RC, Future-1 Nov 23, 2016

@rrelyea

This comment has been minimized.

Show comment
Hide comment
@rrelyea

rrelyea Nov 23, 2016

Contributor

This is being fixed by the move of .NET Core projects to use project files, instead of Project.Json.
The first release of that support is in VS 2017 RC, which is now publicly available.
Closing. Please let us know if you see any issues with the support we are shipping in VS 2017 RC.

Contributor

rrelyea commented Nov 23, 2016

This is being fixed by the move of .NET Core projects to use project files, instead of Project.Json.
The first release of that support is in VS 2017 RC, which is now publicly available.
Closing. Please let us know if you see any issues with the support we are shipping in VS 2017 RC.

@rrelyea rrelyea closed this Nov 23, 2016

@jsgoupil

This comment has been minimized.

Show comment
Hide comment
@jsgoupil

jsgoupil Nov 27, 2016

@rrelyea Trying this VS2017, after a conversion of a xproj to a csproj, there is no packages.config files.
Doing a normal nuget restore on a solution will not restore the dependencies.

You can repro this by creating a new ASP.net Framework web app. Then run what Azure would run:

:: 1. Restore NuGet packages
IF /I "WebApplication2.sln" NEQ "" (
  call :ExecuteCmd nuget restore     "%DEPLOYMENT_SOURCE%\WebApplication2.sln"
  IF !ERRORLEVEL! NEQ 0 goto error
)

You'll get

Nothing to do. None of the projects in this solution specify any packages for NuGet to restore.

Then, it won't compile...

NuGet is 3.5

CC @Rick-Anderson

jsgoupil commented Nov 27, 2016

@rrelyea Trying this VS2017, after a conversion of a xproj to a csproj, there is no packages.config files.
Doing a normal nuget restore on a solution will not restore the dependencies.

You can repro this by creating a new ASP.net Framework web app. Then run what Azure would run:

:: 1. Restore NuGet packages
IF /I "WebApplication2.sln" NEQ "" (
  call :ExecuteCmd nuget restore     "%DEPLOYMENT_SOURCE%\WebApplication2.sln"
  IF !ERRORLEVEL! NEQ 0 goto error
)

You'll get

Nothing to do. None of the projects in this solution specify any packages for NuGet to restore.

Then, it won't compile...

NuGet is 3.5

CC @Rick-Anderson

@blackdwarf

This comment has been minimized.

Show comment
Hide comment
@blackdwarf

blackdwarf Nov 28, 2016

@jsgoupil if you modify what Azure runs to run dotnet restore instead, does it work?

blackdwarf commented Nov 28, 2016

@jsgoupil if you modify what Azure runs to run dotnet restore instead, does it work?

@jsgoupil

This comment has been minimized.

Show comment
Hide comment
@jsgoupil

jsgoupil Nov 29, 2016

@blackdwarf

I spent so much time on this... just added 2 more hours and I didn't succeed much. dotnet restore works but it doesn't create the /packages like VS2017 does IF you have a Class Library. (Is it needed though?)

My project GUID is 7B770C35-F561-4221-8A08-E6646CB96DCE. I have noticed that the new Class Library in 2017 have 4DAECC67-F322-4E30-8B4A-A7F6D588ABD5.

There are too many variables that I cannot try them all. It's just not working.

When can I expect this to work on Azure out of the box.

jsgoupil commented Nov 29, 2016

@blackdwarf

I spent so much time on this... just added 2 more hours and I didn't succeed much. dotnet restore works but it doesn't create the /packages like VS2017 does IF you have a Class Library. (Is it needed though?)

My project GUID is 7B770C35-F561-4221-8A08-E6646CB96DCE. I have noticed that the new Class Library in 2017 have 4DAECC67-F322-4E30-8B4A-A7F6D588ABD5.

There are too many variables that I cannot try them all. It's just not working.

When can I expect this to work on Azure out of the box.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment