Where can I download the latest version of VSLangProj150 - visual-studio-2017

I'm looking for the current version of VSLangProj150.dll but I can't seem to find it anywhere.
I have this version, VSLangProj150.15.0.26228 retrieved from nuget but I believe this is an old version because: 1) it was published on 4/13/2017 and 2) it only contains a single interface called PackageReferences which is empty and a VsProjReferencesPropId150 enum with only two values.
Today, I've installed VS 2017 v15.5 and included the Visual Studio SDK component, but I can't seem to find the dll anywhere on my system.
It appears that there is a new version because I've seen references on the web that refers to VSProject4 and Reference6 which are defined in VSLangProj150. And I've found this reference in NuGet.Clients that reads:
AsVsProject4.PackageRefereences?.InstalledPackages
Or am I missing something?

Found it! Must manually get it from nuget.org using VSLangProj150 Version 1.0.0 or as I did, I just added the following:
<package id="VSLangProj150" version="1.0.0" targetFramework="net46" />
to my packages.config file and then let VS 2017 automatically restore any of my missing packages!

Related

ExtensionsMetadataGenerator error when upgrading Azure Functions SDK

I upgraded my azure function sdk from 1.0.14 to 1.0.28 and I get this build error:
The ExtensionsMetadataGenerator package was not imported correctly.
I can't find any documentation or ways to resolve it.
According to the 1.0.28 function sdk released several day ago, it may have some bugs in it.
Workaround:
Manually adding the
Microsoft.Azure.WebJobs.Script.ExtensionsMetadataGenerator nuget package to your project and it will work well.
I got this error when starting with the Visual Studio Function App template which uses Microsoft.NET.Sdk.Functions 1.0.31 and is a .NET Core 2.0 App.
Nuget Package Manager wants to update the Microsoft.NET.Sdk.Functions package to version 3.0.2 which it tries to do but the app is still .NET Core 2 and you get the error:
The ExtensionsMetadataGenerator package was not imported correctly.
To resolve this update the application to .NET Core 3:
Make sure you update your Microsoft.NET.Sdk.Functions NuGet package to the newest version that supports your app's version of .NET.
For example, I have a web app running .NET 2.1, I had to rollback the NuGet version to 1.0.36, and the next version (3.0) only worked on .NET 3 and up. After doing this, Microsoft.Azure.WebJobs.Script.ExtensionsMetadataGenerator NuGet was not needed at all and all my errors were gone.
I am working with microsoft.net.sdk.functions 1.0.38 and see the same message but in my case it is a build warning and not an error.
I installed the suggested NuGet package with the version required. However, I then received 3 warnings:
The ExtensionsMetadataGenerator package was not imported correctly. Are you missing 'C:\Users\me\.nuget\packages\microsoft.azure.webjobs.script.extensionsmetadatagenerator\1.2.0\build\Microsoft.Azure.WebJobs.Script.ExtensionsMetadataGenerator.targets' or 'C:\Users\me\.nuget\packages\microsoft.azure.webjobs.script.extensionsmetadatagenerator\1.2.0\build\Microsoft.Azure.WebJobs.Script.ExtensionsMetadataGenerator.props'? "C:\Users\me\.nuget\packages\microsoft.azure.webjobs.script.extensionsmetadatagenerator\1.2.0\build\Microsoft.Azure.WebJobs.Script.ExtensionsMetadataGenerator.props" cannot be imported again. It was already imported at "C:\Users\me\.nuget\packages\microsoft.net.sdk.functions\1.0.38\build\Microsoft.NET.Sdk.Functions.props (56,3)". This is most likely a build authoring error. This subsequent import will be ignored. [D:\myproject.Web\myproject.Web.AzureFunctions\myproject.Web.AzureFunctions.csproj] "C:\Users\me\.nuget\packages\microsoft.azure.webjobs.script.extensionsmetadatagenerator\1.2.0\build\Microsoft.Azure.WebJobs.Script.ExtensionsMetadataGenerator.targets" cannot be imported again. It was already imported at "C:\Users\me\.nuget\packages\microsoft.net.sdk.functions\1.0.38\build\Microsoft.NET.Sdk.Functions.targets (64,3)". This is most likely a build authoring error. This subsequent import will be ignored. [D:\myproject.Web\myproject.Web.AzureFunctions\myproject.Web.AzureFunctions.csproj]
Worse still my project would not build - it freezes on build with no way to cancel. The only way to cancel was to do, elevated PowerShell:
stop-process -name "dotnet"
To fix this I tried uninstalling the NuGet package but this is not enough as it still seems to be used if it is on the system (even though the project does not reference it?!?).
It is necessary to actually delete the package from package store, i.e. at.
C:\Users\me\.nuget\packages\microsoft.azure.webjobs.script.extensionsmetadatagenerator
Or an alternative is to comment out the lines:
<GenerateFunctionsExtensionsMetadata SourcePath="$(_FunctionsExtensionsDir)" OutputPath="$(_FunctionsExtensionsDir)"/>
From:
C:\Users\me\.nuget\packages\microsoft.azure.webjobs.script.extensionsmetadatagenerator\1.2.0\build\Microsoft.Azure.WebJobs.Script.ExtensionsMetadataGenerator.targets
I have no idea if this is safe to do so but it gets rid of the warning message. I instead opted to just delete the NuGet package and live with the original warning.
Looks like a real mess with microsoft.net.sdk.functions package.

Nuget paths are different after csproj upgraded

I am trying to upgrade my WFP project from the VS 2015 format to the new VS 17 format. There is a lot of trial and error involved but I have come across an issue which I can find no solution for online:
Some of my code is looking for a file in a certain location:
name C:\git\myproj\packages\A.B.C.Installer.4.1.7\setup\dbpkg\MyProj.dbpkg is invalid.'
Unfortunately the new nuget places the same file in:
C:\git\myproj\packages\a.b.c.installer\4.1.7\setup\dbpkg\MyProj.dbpkg
It does two things different:
everything is lowercase
instead of appending the version, it create a new directory
How can I configure the nuget client to behave like it did before? I am unable to change my code to match.
How can I configure the nuget client to behave like it did before? I am unable to change my code to match.
I am afraid you have to update your code. That because this is the expected behavior now for the new NuGet.
Package ids and versions are case insensitive in NuGet and are now
written out lowercase to the global packages folder to avoid conflicts
on case sensitive file systems.
You can check some more details info from following thread:
NuGet PM 3.5.0 incorrectly using lowercase path in *.nuget.targets
So, if you update your project to the new VS 17 format, you have to update you code to resolve this issue. I saw you saying that you are unable to change my code to match, but this change was designed to make nuget work better, there is no ticket for us to return to the past at this moment.
Hope this helps.

NuGet package version is ignored when building

I am using VS 2017. I have this line in my packages.config file.
<package id="System.IdentityModel.Tokens.Jwt" version="4.0.4.403061554" targetFramework="net461" />
I got this error my trying to start my .net application.
System.TypeLoadException: Could not load type 'System.IdentityModel.Tokens.NamedKeySecurityKeyIdentifierClause' from assembly 'System.IdentityModel.Tokens.Jwt, Version=5.2.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35
Because System.IdentityModel.Tokens.NamedKeySecurityKeyIdentifierClause really does not exist in version 5.2.1.0. But it seem NuGet simply ignores the version specification, and always loads the latest version.
I have tried to clean NuGet caches, clean and rebuild entire solution, and restart computer...
Is there anything else I can do?
Update
One strange thing I observed in VS 2017. Notice the differences of the icons for System.Data and System.IdentityModel.Tokens.Jwt. When I try to check the properties of the latter, VS says the package is not installed, which it clearly did. The build went successful, but the application just wont load the right version.
There are a couple of steps you can perform to check that the right version is loaded:
Rebuild your solution to make sure all NuGet packages are restored and that the started application is up to date (You already did that).
Check the tag HintPath for the reference in the project file that references the package. Just open the file in a text editor and look for an XML tag starting with <Reference Include="System.IdentityModel.Tokens.Jwt. Make sure that no version-specific reference is set or that the version matches the version in the packages.config file.
Check in the properties of the according reference in Visual Studio that it is resolved correctly. That means, there must be no yellow exclamation-mark icon on the reference in the solution explorer and in the properties of the reference, the Path entry must point to the installed package. Hence, the path should point to the packages directory inside your solution directory and therein into a directory System.IdentityModel.Tokens.Jwt.4.0.4.403061554.
In most cases (from my experience), there is some mismatch between the reference in the packages.config file and in the project file. If that does not help, make sure that no other module is loaded by your application that has a reference to System.IdentityModel.Tokens.Jwt in version 5.2.1.0.
So far, it is still unclear why VS cannot handle the changes of the NuGet packages, and why it thinks my project is using both .Net Framework and .Net Standard at the same time. I bet it is a but in VS, and hope MS can fix it soon.
Before that, installing Rider and use it to fix the packages, then went back to VS, and everything went back to normal.

Confirm that the <UsingTask> declaration is correct

We have downloaded a project from TFS and after restoring Nuget packages we are getting below error:
Error 5 The "ValidatePackageReferences" task could not be loaded from the assembly projectPath\packages\Microsoft.Bcl.Build.1.0.14\tools\Microsoft.Bcl.Build.Tasks.dll. Could not load file or assembly 'file:///projectPath\packages\Microsoft.Bcl.Build.1.0.14\tools\Microsoft.Bcl.Build.Tasks.dll' or one of its dependencies. The system cannot find the file specified. Confirm that the <UsingTask> declaration is correct, that the assembly and all its dependencies are available, and that the task contains a public class that implements Microsoft.Build.Framework.ITask. projectName
We have not used Task anywhere. It seems it is being used internally. Any pointer how to get rid of this error?
Mostly it looks like its because of wrong version of NuGet package. But not sure whats root cause.
We are using VS 2013 Update 5 version.
First search "Microsoft.Bcl.Build.Tasks.dll." nuget on google. Then a link will be opened with named "https://www.nuget.org/packages/Microsoft.Bcl.Build/". Then copy the package name shown on the site like this
Install-Package Microsoft.Bcl.Build -Version 1.0.21
Then Open the Visual studio , Goto Tools>Nuget Package Manager>Package manager console. Now paste the copied install package,Install it. Then restart the VS.Issue will be solved.

How to integrate gitext to VS 2017?

After I install it, it doesn't show up as a menu anywhere.
Am I missing something or does it not support vs2017?
you should download and install VSIX
Temporary available here
https://mega.nz/#!S05nRBpR!jQL-JWUlIMzxKGtygjVStIJ5K8B8wUWEUb7Y8asIaCI
EDIT:
New link...
https://mega.nz/#!IzYSWKwB!jpO7Raj_4hi2aeiZ-RjweVFr_YkPdA6c2Zl9HdR7tD8
EDIT 1/14/18:
Now official, look #raghav answer
Seems it has been official now.
Visual Studio plugin for using Git Extensions. VS 2017 supported too.
https://marketplace.visualstudio.com/items?itemName=HenkWesthuis.GitExtensions
I don't now why, but GitExtensionsVSIX.vsix provided in GitExtension release version 2.51.02, fails to install because it lacks some files inside.
#raghav answer works, but it has older version (2.50.02 in 30\05\2018).
But GitExtensionsVSIX.vsix 2.51.02 could be fixed:
unpack GitExtensionsVSIX.vsix as it is zip archive.
add files manifest.json and catalog.json from contents of #raghav answer's GitExtensionsVSIX.vsix.
update version in that files to 2.51.02.
Update sha 256 hashes in manifest.json.
Add <Default Extension="json" ContentType="application/json" /> to Types in [Content_Types].xml.
zip-pack all files.
rename extension to ".vsix".
Install.