DNX beta8-15530 : Could not load file or assembly 'Microsoft.DNX.PackageManager'
Asked Answered
M

3

15

I have run this command in Package Manager Console to upgrade the dnx.

"dnvm upgrade -u default"

Once It's get update, I can see(C:\Users\Chandrasekar.dnx\runtimes) the new runtime version as mention below

"dnx-clr-win-x86.1.0.0-beta8-15530"  

I started creating new project in VS2015 --> ASPNET 5 web application it ends up with some errors.

enter image description here

In output window you can see the error "Could not load 'Microsoft.DNX.PackageManager'", according to this announcement it has been renamed to 'Microsoft.Dnx.Tooling' so my question is why the new DNX beta 8 version still depends on this removed or renamed DLL 'Microsoft.DNX.PackageManager'?

Output Window Error:

PATH=.\node_modules\.bin;C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External;%PATH%;C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\git
C:\Users\Chandrasekar\.dnx\runtimes\dnx-clr-win-x86.1.0.0-beta8-15530\bin\dnx.exe "C:\Users\Chandrasekar\.dnx\runtimes\dnx-clr-win-x86.1.0.0-beta8-15530\bin\lib\Microsoft.DNX.PackageManager\Microsoft.DNX.PackageManager.dll" restore "C:\Users\Chandrasekar\Documents\Visual Studio 2015\Projects\DNX8\src\DNX8" -f "C:\Program Files (x86)\Microsoft Web Tools\DNU"
System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.DNX.PackageManager' or one of its dependencies. The system cannot find the file specified.
File name: 'Microsoft.DNX.PackageManager'
   at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   at System.Reflection.Assembly.Load(AssemblyName assemblyRef)
   at Microsoft.Dnx.Runtime.Loader.LoadContext.Load(AssemblyName assemblyName)
   at Microsoft.Dnx.Host.Bootstrapper.RunAsync(List`1 args, IRuntimeEnvironment env, FrameworkName targetFramework)
   at Microsoft.Dnx.Host.RuntimeBootstrapper.ExecuteAsync(String[] args, FrameworkName targetFramework)
   at Microsoft.Dnx.Host.RuntimeBootstrapper.Execute(String[] args, FrameworkName targetFramework)
WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

Can you please help me to solve this issues? Do I need to update any dlls or software?

Tools: Microsoft Visual Studio Enterprise 2015 Version 14.0.23107.0

Maple answered 1/9, 2015 at 11:5 Comment(5)
Do you happen to have an environment variable callled WEBPROJ_ENABLEBETA7RENAMES?..if so remove it and reload VS and try again and see if it fixes the issue.Ammadas
Same issue as OP, similar logs. I have no WEBPROJ_ENABLEBETA7RENAMES, unless VS2015 is adding it somehow. This errors only within VS2015; it works fine from command line.Dormancy
@KiranChalla I haven't added that environment variable. I restarted the VS and computer so many times no hopes. Am I missing something else?Maple
@MattDeKrey Is there any way to solve this issues in VS2015Maple
Still searching myself, @Chandru! I'll be sure to post an answer if I find one.Dormancy
R
12

You are not using the latest tooling version. Your version is probably 14.0.20711.0 while the latest is 14.0.20723.0.

20711 had a bug because it was trying to load Microsoft.DNX.PackageManager which is actually Microsoft.Dnx.Tooling .

Get the latest version: http://www.microsoft.com/en-us/download/details.aspx?id=48222

See this announcement.

Ranie answered 2/9, 2015 at 15:54 Comment(4)
Make sure the full install instructions are followed - it's two separate installers! (Thanks again, @VictorHurdugaci!)Dormancy
Thanks Victor Hurdugaci, I will update the Web Tools 2015 (Beta6) – Visual Studio 2015. How often I have to check and update this tool because until now I didn't get any notification to update my Web tooling? Do I need to register some where to get the notification of new release?Maple
Thanks Victor. After installing the latest version of Web Tool everything works fine.Maple
Worked for me too. I used Beta 7. microsoft.com/en-us/download/confirmation.aspx?id=48738Truck
C
5

Let me make this stand out - I tend to forget. Here's Beta 8:

Microsoft ASP.NET and Web Tools 2015 (Beta8) – Visual Studio 2015

And a search for all of them - if the name doesn't change, RC1 will show up shortly ;)

Search results for Microsoft ASP.NET and Web Tools on Microsoft.com

Candlemaker answered 9/11, 2015 at 4:47 Comment(0)
C
0

For RC1 there are a lot of choices for the downloads under the Microsoft ASP.NET and Web Tools 2015 (RC) – Visual Studio 2015 page , what I was missing was WebToolsExtensionsVS14.msi. After installing references got fixed and packages were able to restore.

Councilor answered 29/11, 2015 at 7:54 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.