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

Paket cannot resolve a conflict on Microsoft.AspNet.Razor when using a local package source #1703

Closed
yaakov-h opened this Issue May 25, 2016 · 3 comments

Comments

Projects
None yet
2 participants
@yaakov-h
Contributor

yaakov-h commented May 25, 2016

Description

When using a local package source, Paket cannot resolve the dependency conflict between RazorEngine and Microsoft.AspNet.Mvc.

This is likely due to a failure to resolve this dependencies section in RazorEngine's nuspec file:

    <dependencies>
      <group targetFramework=".NETFramework4.0">
        <dependency id="Microsoft.AspNet.Razor" version="[2.0.30506.0]" />
      </group>
      <group targetFramework=".NETFramework4.5">
        <dependency id="Microsoft.AspNet.Razor" version="3.0.0" />
      </group>
    </dependencies>

Repro steps

  1. Create a paket.dependencies file with the following:
source \\some-server\network-share
framework: net45
nuget Microsoft.AspNet.Mvc
nuget RazorEngine
  1. Copy the nupkgs for these dependencies, and their dependency tree, to \some-server\network-share
  2. Run paket.exe update

Expected behavior

Paket resolves Microsoft.AspNet.Razor (>= 3.2.3 < 3.3) to Microsoft.AspNet.Razor (3.2.3).

Actual behavior

Paket version 3.0.0.0
Resolving packages for group Main:
 - Microsoft.AspNet.Mvc 5.2.3
 - RazorEngine 3.8.2
 - RazorEngine 3.7.3
Paket failed with:
        There was a version conflict during package resolution.
  Resolved packages:
   - Microsoft.AspNet.Mvc 5.2.3
   - RazorEngine 3.7.3
  Could not resolve package Microsoft.AspNet.Razor:
   - Microsoft.AspNet.Mvc 5.2.3 requested package Microsoft.AspNet.Razor: >= 3.2.3 < 3.3
   - RazorEngine 3.7.3 requested package Microsoft.AspNet.Razor: 2.0.30506

  Please try to relax some conditions.

Known workarounds

One workaround:

  • Remove framework: net45 from paket.dependencies.

Another workaround:

  • Use the public gallery (https://api.nuget.org/v3/index.json), not a local source.

Another workaround:

  • Use Paket 3.x beta with the public gallery source (above) and a cache directive to the local folder,

Related information

  • Operating System: Windows 10.0 (build 10240)
  • Issue occurs in (at least) Paket 2.60.2.0, 2.66.3.0, and 3.0.0.0 (beta053)
  • .NET 4.6.1 installed on the machine, attempting to target .NET 4.5 for the project Paket is being used in.
@forki

This comment has been minimized.

Show comment
Hide comment
@forki

forki May 25, 2016

Member

Could you please create a zip which reproduces this issue? Thanks
On May 25, 2016 2:47 AM, "Yaakov" notifications@github.com wrote:

Description

When using a local package source, Paket cannot resolve the dependency
conflict between RazorEngine and Microsoft.AspNet.Mvc.

This is likely due to a failure to resolve this dependencies section in
RazorEngine's nuspec file:

<dependencies>
  <group targetFramework=".NETFramework4.0">
    <dependency id="Microsoft.AspNet.Razor" version="[2.0.30506.0]" />
  </group>
  <group targetFramework=".NETFramework4.5">
    <dependency id="Microsoft.AspNet.Razor" version="3.0.0" />
  </group>
</dependencies>

Repro steps

  1. Create a paket.dependencies file with the following:

source \some-server\network-share
framework: net45
nuget Microsoft.AspNet.Mvc
nuget RazorEngine

Copy the nupkgs for these dependencies, and their dependency tree, to
\some-server\network-share
2.

Run paket.exe update

Expected behavior

Paket resolves Microsoft.AspNet.Razor (>= 3.2.3 < 3.3) to Microsoft.AspNet.Razor
(3.2.3).
Actual behavior

Paket version 3.0.0.0
Resolving packages for group Main:

  • Microsoft.AspNet.Mvc 5.2.3

  • RazorEngine 3.8.2

  • RazorEngine 3.7.3
    Paket failed with:
    There was a version conflict during package resolution.
    Resolved packages:

    • Microsoft.AspNet.Mvc 5.2.3
    • RazorEngine 3.7.3
      Could not resolve package Microsoft.AspNet.Razor:
    • Microsoft.AspNet.Mvc 5.2.3 requested package Microsoft.AspNet.Razor: >= 3.2.3 < 3.3
    • RazorEngine 3.7.3 requested package Microsoft.AspNet.Razor: 2.0.30506

    Please try to relax some conditions.

Known workarounds

One workaround:

  • Remove framework: net45 from paket.dependencies.

Another workaround:

Another workaround:

  • Use Paket 3.x beta with the public gallery source (above) and a cache
    directive to the local folder,

Related information

  • Operating System: Windows 10.0 (build 10240)
  • Issue occurs in (at least) Paket 2.60.2.0, 2.66.3.0, and 3.0.0.0
    (beta053)
  • .NET 4.6.1 installed on the machine, attempting to target .NET 4.5
    for the project Paket is being used in.


You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
#1703

Member

forki commented May 25, 2016

Could you please create a zip which reproduces this issue? Thanks
On May 25, 2016 2:47 AM, "Yaakov" notifications@github.com wrote:

Description

When using a local package source, Paket cannot resolve the dependency
conflict between RazorEngine and Microsoft.AspNet.Mvc.

This is likely due to a failure to resolve this dependencies section in
RazorEngine's nuspec file:

<dependencies>
  <group targetFramework=".NETFramework4.0">
    <dependency id="Microsoft.AspNet.Razor" version="[2.0.30506.0]" />
  </group>
  <group targetFramework=".NETFramework4.5">
    <dependency id="Microsoft.AspNet.Razor" version="3.0.0" />
  </group>
</dependencies>

Repro steps

  1. Create a paket.dependencies file with the following:

source \some-server\network-share
framework: net45
nuget Microsoft.AspNet.Mvc
nuget RazorEngine

Copy the nupkgs for these dependencies, and their dependency tree, to
\some-server\network-share
2.

Run paket.exe update

Expected behavior

Paket resolves Microsoft.AspNet.Razor (>= 3.2.3 < 3.3) to Microsoft.AspNet.Razor
(3.2.3).
Actual behavior

Paket version 3.0.0.0
Resolving packages for group Main:

  • Microsoft.AspNet.Mvc 5.2.3

  • RazorEngine 3.8.2

  • RazorEngine 3.7.3
    Paket failed with:
    There was a version conflict during package resolution.
    Resolved packages:

    • Microsoft.AspNet.Mvc 5.2.3
    • RazorEngine 3.7.3
      Could not resolve package Microsoft.AspNet.Razor:
    • Microsoft.AspNet.Mvc 5.2.3 requested package Microsoft.AspNet.Razor: >= 3.2.3 < 3.3
    • RazorEngine 3.7.3 requested package Microsoft.AspNet.Razor: 2.0.30506

    Please try to relax some conditions.

Known workarounds

One workaround:

  • Remove framework: net45 from paket.dependencies.

Another workaround:

Another workaround:

  • Use Paket 3.x beta with the public gallery source (above) and a cache
    directive to the local folder,

Related information

  • Operating System: Windows 10.0 (build 10240)
  • Issue occurs in (at least) Paket 2.60.2.0, 2.66.3.0, and 3.0.0.0
    (beta053)
  • .NET 4.6.1 installed on the machine, attempting to target .NET 4.5
    for the project Paket is being used in.


You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
#1703

@yaakov-h

This comment has been minimized.

Show comment
Hide comment
@yaakov-h

yaakov-h May 25, 2016

Contributor

@forki here you go

(previous link was incorrect)

Contributor

yaakov-h commented May 25, 2016

@forki here you go

(previous link was incorrect)

@forki forki added the bug label May 26, 2016

@forki forki closed this in 67e2779 May 26, 2016

@forki

This comment has been minimized.

Show comment
Hide comment
@forki

forki May 26, 2016

Member

thanks for the repro sample. should be fixed now.

Member

forki commented May 26, 2016

thanks for the repro sample. should be fixed now.

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