无法通过VS2015中的Nuget下载System.Data.Sqlite

无法通过VS2015中的Nuget下载System.Data.Sqlite,sqlite,entity-framework-6,nuget,visual-studio-2015,nullreferenceexception,Sqlite,Entity Framework 6,Nuget,Visual Studio 2015,Nullreferenceexception,我正试图通过Visual Studio 2015社区中的stock NuGet下载带有EF6支持的包System.Data.Sqlite。按下“安装”后,我被要求提供依赖项。然后,在确认之后,一段时间内什么也没有发生,然后在输出窗口中,我得到“Object reference not set to instance of Object”错误。我将NuGet升级到3.2.x,但问题仍然存在。我能做些什么来解决它 编辑:从输出控制台记录: Attempting to gather dependen

我正试图通过Visual Studio 2015社区中的stock NuGet下载带有EF6支持的包System.Data.Sqlite。按下“安装”后,我被要求提供依赖项。然后,在确认之后,一段时间内什么也没有发生,然后在输出窗口中,我得到“Object reference not set to instance of Object”错误。我将NuGet升级到3.2.x,但问题仍然存在。我能做些什么来解决它


编辑:从输出控制台记录:

Attempting to gather dependencies information for package 'System.Data.SQLite.1.0.98.1' with respect to project 'WPTManager', targeting '.NETFramework,Version=v4.5.2'
Attempting to resolve dependencies for package 'System.Data.SQLite.1.0.98.1' with DependencyBehavior 'Lowest'
Resolving actions to install package 'System.Data.SQLite.1.0.98.1'
Resolved actions to install package 'System.Data.SQLite.1.0.98.1'
Install failed. Rolling back...
Package 'EntityFramework 6.0.0' does not exist in project 'WPTManager'
Package 'EntityFramework 6.0.0' does not exist in folder 'D:\Dokumenty\Dev\VS\Projekty\WPTManager\packages'
System.NullReferenceException: Object reference not set to an instance of an object.
   at NuGet.Protocol.Core.v3.GlobalPackagesFolderUtility.<AddPackageAsync>d__1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
   at NuGet.Protocol.Core.v3.DownloadResourceV3.<GetDownloadResourceResultAsync>d__4.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at NuGet.PackageManagement.PackageDownloader.<GetDownloadResourceResultAsync>d__1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
   at NuGet.PackageManagement.NuGetPackageManager.<ExecuteNuGetProjectActionsAsync>d__42.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at NuGet.PackageManagement.NuGetPackageManager.<ExecuteNuGetProjectActionsAsync>d__42.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at NuGet.PackageManagement.UI.UIActionEngine.<ExecuteActionsAsync>d__5.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at NuGet.PackageManagement.UI.UIActionEngine.<PerformActionAsync>d__3.MoveNext()
========== Finished ==========
正在尝试收集程序包'System.Data.SQLite.1.0.98.1'与项目'WPTManager'相关的依赖项信息,目标是'.NETFramework,版本=v4.5.2'
正在尝试解析DependencyBehavior为“最低”的包“System.Data.SQLite.1.0.98.1”的依赖关系
解决安装包“System.Data.SQLite.1.0.98.1”的操作
已解决安装程序包“System.Data.SQLite.1.0.98.1”的操作
安装失败。正在回滚。。。
项目“WPTManager”中不存在包“EntityFramework 6.0.0”
文件夹“D:\Dokumenty\Dev\VS\Projekty\WPTManager\packages”中不存在包“EntityFramework 6.0.0”
System.NullReferenceException:对象引用未设置为对象的实例。
在NuGet.Protocol.Core.v3.GlobalPackagesFolderUtility.d_u1.MoveNext()中
---来自引发异常的上一个位置的堆栈结束跟踪---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(任务任务)
在System.Runtime.CompilerServices.TaskWaiter.HandleNonSuccessAndDebuggerNotification(任务任务)中
在System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()中
在NuGet.Protocol.Core.v3.DownloadResourceV3.d_u4.MoveNext()中
---来自引发异常的上一个位置的堆栈结束跟踪---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(任务任务)
在System.Runtime.CompilerServices.TaskWaiter.HandleNonSuccessAndDebuggerNotification(任务任务)中
在NuGet.PackageManagement.PackageDownloader.d_u1.MoveNext()中
---来自引发异常的上一个位置的堆栈结束跟踪---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(任务任务)
在System.Runtime.CompilerServices.TaskWaiter.HandleNonSuccessAndDebuggerNotification(任务任务)中
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(任务任务)
在NuGet.PackageManagement.NuGetPackageManager.d_u42.MoveNext()中
---来自引发异常的上一个位置的堆栈结束跟踪---
在System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()中
在NuGet.PackageManagement.NuGetPackageManager.d_u42.MoveNext()中
---来自引发异常的上一个位置的堆栈结束跟踪---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(任务任务)
在System.Runtime.CompilerServices.TaskWaiter.HandleNonSuccessAndDebuggerNotification(任务任务)中
在NuGet.PackageManagement.UI.UIActionEngine.d_u5.MoveNext()中
---来自引发异常的上一个位置的堆栈结束跟踪---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(任务任务)
在System.Runtime.CompilerServices.TaskWaiter.HandleNonSuccessAndDebuggerNotification(任务任务)中
在NuGet.PackageManagement.UI.UIActionEngine.d_u3.MoveNext()中
=============已完成==========
找到了解决方法

  • 通过NuGet安装实体框架
  • 现在安装System.Data.SQLite-它将正确安装

  • 虽然没有直接的解决方案,但很可能是NuGet中的一个bug。

    我也有同样的问题。所以我从NuGet站点手动下载了这个包,然后我设置了自己的包源,并从那里正确安装了它。它也是唯一一种类似于您的解决方案。

    到底是哪个软件包?@ErikEJ System.Data.SQLite.1.0.98.1