sshnet / sshnet/SSH.NET

UAP10 "Microsoft.NETCore.UniversalWindowsPlatform": "5.2.0" is too high?

Open
#57 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
4.4k
Forks
993
Avg merge
9d 21h
Merged PRs (30d)
1

Description

The current project.json specified dependency as 5.2.0, yet the default template for UWP app is 5.1.0. Therefore the two can't work correctly together.

To repro:

1, use VS 2015 update 3 to create a new UWP app, it compiles alright.
2, add SSH.NET in by NuGet, then F6 will give us these errors:

Detected package downgrade: Microsoft.Win32.Primitives from 4.0.1 to 4.0.0 
 App3 (>= 1.0.0) -> Microsoft.NETCore.UniversalWindowsPlatform (>= 5.1.0) -> Microsoft.NETCore (>= 5.0.0) -> System.Net.Primitives (>= 4.0.10) -> runtime.win.System.Net.Primitives (>= 4.0.11) -> Microsoft.Win32.Primitives (>= 4.0.1) 
 App3 (>= 1.0.0) -> Microsoft.NETCore.UniversalWindowsPlatform (>= 5.1.0) -> Microsoft.Win32.Primitives (>= 4.0.0)
Detected package downgrade: Microsoft.Win32.Primitives from 4.0.1 to 4.0.0 
 App3 (>= 1.0.0) -> Microsoft.NETCore.UniversalWindowsPlatform (>= 5.1.0) -> System.Net.Requests (>= 4.0.10) -> System.Net.Primitives (>= 4.0.10) -> runtime.win.System.Net.Primitives (>= 4.0.11) -> Microsoft.Win32.Primitives (>= 4.0.1) 
 App3 (>= 1.0.0) -> Microsoft.NETCore.UniversalWindowsPlatform (>= 5.1.0) -> Microsoft.Win32.Primitives (>= 4.0.0)
...
1>------ Build started: Project: App3, Configuration: Debug x86 ------
1>C:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets(1820,5): warning MSB3277: Found conflicts between different versions of the same dependent assembly that could not be resolved.  These reference conflicts are listed in the build log when log verbosity is set to detailed.
1>  App3 -> c:\scratch\App3\App3\bin\x86\Debug\App3.exe
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\AppxPackage\Microsoft.AppXPackage.Targets(1692,5): error APPX1101: Payload contains two or more files with the same destination path 'Microsoft.Win32.Primitives.dll'. Source files: 
1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\AppxPackage\Microsoft.AppXPackage.Targets(1692,5): error APPX1101: C:\Users\dong\.nuget\packages\Microsoft.Win32.Primitives\4.0.0\lib\dotnet\Microsoft.Win32.Primitives.dll
...

If we change the UWP app json to 5.2.0, then all those will be gone. But this is probably prohibited for some people/project.

If there is no specific reason to require 5.2.0, can we change it to 5.1.0 so that it works out of box?

Best regards

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by inspecting the project's project.json dependency for Microsoft.NETCore.UniversalWindowsPlatform and compare its version with the UWP template's 5.1.0 requirement. Reproduce the issue in a VS 2015 Update 3 UWP app with SSH.NET installed, then verify that changing the dependency removes the package downgrade and duplicate Microsoft.Win32.Primitives build errors.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
build-system
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.