Unhandled Exception: System.IO.FileNotFoundException: Could not load file or assembly Microsoft.DotNet.InternalAbstractions
See original GitHub issueI’m currently running a build on AppVeyor, with the new .NET Core 1.1. Apperently one of my test projects fail to run.
...
Finished executing task: Build
========================================
Tests
========================================
Executing task: Tests
Executing: "C:/Program Files/dotnet/dotnet.exe" test "C:/projects/auth/test/AskCody.Auth.Infrastructure.Tests/project.json" --configuration Release
Project AskCody.Auth (.NETStandard,Version=v1.6) was previously compiled. Skipping compilation.
Project AskCody.Auth.Infrastructure (.NETStandard,Version=v1.6) was previously compiled. Skipping compilation.
Project AskCody.Auth.Infrastructure.Tests (.NETCoreApp,Version=v1.1) was previously compiled. Skipping compilation.
xUnit.net .NET CLI test runner (64-bit .NET Core win81-x64)
Discovering: AskCody.Auth.Infrastructure.Tests
Discovered: AskCody.Auth.Infrastructure.Tests
Starting: AskCody.Auth.Infrastructure.Tests
Finished: AskCody.Auth.Infrastructure.Tests
=== TEST EXECUTION SUMMARY ===
AskCody.Auth.Infrastructure.Tests Total: 7, Errors: 0, Failed: 0, Skipped: 0, Time: 1.271s
SUMMARY: Total: 1 targets, Passed: 1, Failed: 0.
Executing: "C:/Program Files/dotnet/dotnet.exe" test "C:/projects/auth/test/AskCody.Auth.Server.Tests/project.json" --configuration Release
Project AskCody.Auth (.NETStandard,Version=v1.6) was previously compiled. Skipping compilation.
Project AskCody.Auth.Infrastructure (.NETStandard,Version=v1.6) was previously compiled. Skipping compilation.
Project AskCody.Auth.Server (.NETCoreApp,Version=v1.1) was previously compiled. Skipping compilation.
Project AskCody.Auth.Server.Tests (.NETCoreApp,Version=v1.1) was previously compiled. Skipping compilation.
Cake.exe : Unhandled Exception: System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.DotNet.InternalAbstractions, Version=1.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60'. The system cannot find
the file specified.
At line:1 char:1
+ & "C:\projects\auth\tools\Cake\Cake.exe" "build.cake" -target="AppVey ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (Unhandled Excep...file specified.:String) [], RemoteException
+ FullyQualifiedErrorId : NativeCommandError
at Xunit.Runner.DotNet.Program.GetAvailableRunnerReporters()
at Xunit.Runner.DotNet.Program.Run(String[] args)
at Xunit.Runner.DotNet.Program.Main(String[] args)
SUMMARY: Total: 1 targets, Passed: 0, Failed: 1.
An error occurred when executing task '
Tests'.
Error:
Cake.Core.CakeException: .NET Core CLI: Process returned an error (exit code -532462766).
at Cake.Core.Tooling.Tool`1.ProcessExitCode(Int32 exitCode)
at Cake.Core.Tooling.Tool`1.Run(TSettings settings, ProcessArgumentBuilder arguments, ProcessSetti
ngs processSettings, Action`1 postAction)
at Cake.Core.Tooling.Tool`1.Run(TSettings settings, ProcessArgumentBuilder arguments)
at Cake.Common.Tools.DotNetCore.Test.DotNetCoreTester.Test(String project, DotNetCoreTestSettings settings)
at Cake.Common.Tools.DotNetCore.DotNetCoreAliases.DotNetCoreTest(ICakeContext context, String project, DotNetCoreTestSettings settings)
at Submission#0.<.ctor>b__10()
at Cake.Core.CakeTaskBuilderExtensions.<>c__DisplayClass5_0.<Does>b__0(ICakeContext context)
at Cake.Core.ActionTask.Execute(ICakeContext context)
at Cake.Core.DefaultExecutionStrategy.Execute(CakeTask task, ICakeContext context)
at Cake.Core.CakeEngine.ExecuteTask(ICakeContext context, IExecutionStrategy strategy, Stopwatch stopWatch, CakeTask task, CakeReport report)
at Cake.Core.CakeEngine.RunTarget(ICakeContext context, IExecutionStrategy strategy, String target)
at Cake.Scripting.BuildScriptHost.RunTarget(String target)
at Submission#0..ctor(Session session, Object& submissionResult)
at Submission#0.<Factory>(Session session)
at Roslyn.Scripting.CommonScriptEngine.Execute[T](String code, String path, DiagnosticBag diagnostics, Session session, Boolean isInteractive)
at Roslyn.Scripting.Session.Execute(String code)
at Cake.Scripting.Roslyn.Stable.DefaultRoslynScriptSession.Execute(Script script)
at Cake.Core.Scripting.ScriptRunner.Run(IScriptHost host, FilePath scriptPath, IDictionary`2 arguments)
at Cake.Commands.BuildCommand.Execute(CakeOptions options)
at Cake.CakeApplication.Run(CakeOptions options)
at Cake.Program.Main()
Command executed with exception:
The test projects have the same dependencies, so I am unsure why one of the projects fail. The exception of Could not load file or assembly 'Microsoft.DotNet.InternalAbstractions
is not a dependency I have anywhere in my code base.
The build script for testing is:
Task("Tests")
.IsDependentOn("Build")
.Does(() => {
foreach (var projectJson in GetFiles("./test/**/project.json"))
{
DotNetCoreTest(projectJson.FullPath, new DotNetCoreTestSettings
{
Configuration = "Release"
});
}
});
I am running Cake 0.16.2.
Issue Analytics
- State:
- Created 7 years ago
- Comments:12 (6 by maintainers)
Top Results From Across the Web
Upgrade to Nuget package Telerik.UI.for.AspNet.Core ...
FileNotFoundException : Could not load file or assembly 'Microsoft.DotNet.InternalAbstractions, Version=1.0.0.0, Culture=neutral, PublicKeyToken= ...
Read more >System.IO.FileNotFoundException: Could not load file or ...
Unhandled Exception : System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.DotNet.InternalAbstractions, Version=1.0.0.0, ...
Read more >System.IO.FileNotFoundException: 'Could not load file or ...
I have an application in .net core. the application was running fine, but the error started coming after I installed.
Read more >Could not load file or assembly Microsoft. ...
I'm trying to search if the problem is caused by any application part loaded in the startup but no success. Important: My goal...
Read more >How do I fix the error: "Unhandled exception. System.IO. ...
The above error happens when I try to create a scaffold for the identity, ... System.IO.FileLoadException: Could not load file or assembly ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Yes, it is actually dotnet cli:
It smells like it. I’ll poke around their GitHub issues