Pex 0.94.0.0 发布 Visual Studio 10.0.40219.1 错误报告
如何重现:
- 打开一个类库项目
- 创建一个空方法
- 右键单击-> 运行 Pex
我在另一台机器上运行没有问题(在 Office 中,VS2010 Utimate)
但是我在家用电脑上遇到了这个异常(VS2010 Professional)
异常详细信息:System.InvalidCastException:无法将“System.__ComObject”类型的 COM 对象转换为接口类型“EnvDTE.DTE”。此操作失败,因为 IID 为“{04A72314-32E9-48E2-9B87-A63603454F3E}”的接口的 COM 组件上的 QueryInterface 调用因以下错误而失败:接口未注册。(HRESULT 的异常:0x80040155)在 Microsoft.Pex.VsPackage.VsServiceProviderHelper.GetService[T](IServiceProvider serviceProvider) 在 Microsoft.Pex.VsPackage.Helpers.ProjectHelper.SaveAllFiles(IServiceProvider serviceProvider) 在 Microsoft.Pex.VsPackage.Actions.ActionComponent .SaveAll() 在 Microsoft.Pex.VsPackage.Actions.ExplorationActionBase.InternalExecute() 在 Microsoft.Pex.VsPackage.Actions.ActionComponent.Execute(对象目标)
Microsoft.Pex.VsPackage.Controls.ErrorReport.<>c_DisplayClass4.b 的 Microsoft.Pex.VsPackage.Controls.ErrorReport.CreateReport(Exception ex) 的当前堆栈跟踪_3() 在 System.RuntimeMethodHandle._InvokeMethodFast(IRuntimeMethodInfo 方法,对象目标,Object[] 参数,SignatureStruct& sig,MethodAttributes methodAttributes,RuntimeType typeOwner) 在 System.RuntimeMethodHandle.InvokeMethodFast(IRuntimeMethodInfo 方法,对象目标,Object[] 参数,签名 sig , MethodAttributes methodAttributes, RuntimeType typeOwner) 在 System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfoculture, Boolean skipVisibilityChecks) 在 System.Delegate.DynamicInvokeImpl(Object[] args) 在 Microsoft .Pex.VsPackage.Helpers.UIThreadInvoker.SafeMethodInvoker.Invoke() 在 System.RuntimeMethodHandle._InvokeMethodFast(IRuntimeMethodInfo 方法,对象目标,对象 [] 参数,SignatureStruct& sig,System.RuntimeMethodHandle.InvokeMethodFast(IRuntimeMethodInfo 方法,对象目标,Object[] 参数,签名 sig,MethodAttributes methodAttributes,RuntimeType typeOwner)中的 MethodAttributes methodAttributes,RuntimeType typeOwner)在 System.Reflection.RuntimeMethodInfo.Invoke(Object obj,BindingFlags invokeAttr,Binding , Object[] 参数, CultureInfo 文化, Boolean skipVisibilityChecks) 在 System.Delegate.DynamicInvokeImpl(Object[] args) 在 System.Windows.Forms.Control.InvokeMarshaledCallbackDo(ThreadMethodEntry tme) 在 System.Windows.Forms.Control.InvokeMarshaledCallbackHelper(Object obj) 在 System.Threading.ExecutionContext.runTryCode(Object userData) 在 System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode 代码, CleanupCode backoutCode, Object userData) 在系统。Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx) 在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback , 对象状态) 在 System.Windows.Forms.Control.InvokeMarshaledCallbacks() 在 System.Windows.Forms.Control.WndProc(Message& m) 在 System.Windows.Forms.InvokeMarshaledCallback(ThreadMethodEntry tme) 在 System.Windows.Forms .Control.ControlNativeWindow.OnMessage(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m) 在 System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object状态)在 System.Windows.Forms.Control.InvokeMarshaledCallback(ThreadMethodEntry tme) 在 System.Windows.Forms.Control.WndProc(Message& m) 在 System.Windows.Forms.Control.InvokeMarshaledCallbacks() 在 System.Windows.Forms.Control .ControlNativeWindow.OnMessage(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m) 在 System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) 在 System.Windows.Forms.Control.InvokeMarshaledCallback(ThreadMethodEntry tme) 在 System.Windows.Forms.Control.InvokeMarshaledCallbacks() 在 System.Windows.Forms.Control.WndProc(Message& m) 在 System.Windows.Forms.Control .ControlNativeWindow.OnMessage(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m) 在 System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)在 System.Windows.Forms.Control.InvokeMarshaledCallback(ThreadMethodEntry tme) 在 System.Windows.Forms.Control.InvokeMarshaledCallbacks() 在 System.Windows.Forms.Control.WndProc(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd,Int32 msg,IntPtr wparam,IntPtr lparam)上 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)的 .OnMessage(Message& m)RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)在 System.Windows.Forms.Control.InvokeMarshaledCallback(ThreadMethodEntry tme) 在 System.Windows.Forms.Control.InvokeMarshaledCallbacks() 在 System.Windows.Forms.Control.WndProc(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd,Int32 msg,IntPtr wparam,IntPtr lparam)上 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)的 .OnMessage(Message& m)IntPtr lparam)IntPtr lparam)对象状态)在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx) 在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) 在 System.Windows.Forms.Control .InvokeMarshaledCallback(ThreadMethodEntry tme) 在 System.Windows.Forms.Control.InvokeMarshaledCallbacks() 在 System.Windows.Forms.Control.WndProc(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m) 在 System .Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m) 在 System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)对象状态)在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx) 在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) 在 System.Windows.Forms.Control .InvokeMarshaledCallback(ThreadMethodEntry tme) 在 System.Windows.Forms.Control.InvokeMarshaledCallbacks() 在 System.Windows.Forms.Control.WndProc(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m) 在 System .Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m) 在 System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)System.Windows.Forms.Control.InvokeMarshaledCallback(ThreadMethodEntry tme) 在 System.Windows.Forms.Control 的 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) 的 ContextCallback 回调,对象状态,布尔 ignoreSyncCtx)。 InvokeMarshaledCallbacks() 在 System.Windows.Forms.Control.WndProc(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m) 在System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd,Int32 msg,IntPtr wparam,IntPtr lparam)System.Windows.Forms.Control.InvokeMarshaledCallback(ThreadMethodEntry tme) 在 System.Windows.Forms.Control 的 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) 的 ContextCallback 回调,对象状态,布尔 ignoreSyncCtx)。 InvokeMarshaledCallbacks() 在 System.Windows.Forms.Control.WndProc(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m) 在System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd,Int32 msg,IntPtr wparam,IntPtr lparam)InvokeMarshaledCallback(ThreadMethodEntry tme) 在 System.Windows.Forms.Control.InvokeMarshaledCallbacks() 在 System.Windows.Forms.Control.WndProc(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m) 在 System。 Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m) 在 System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)InvokeMarshaledCallback(ThreadMethodEntry tme) 在 System.Windows.Forms.Control.InvokeMarshaledCallbacks() 在 System.Windows.Forms.Control.WndProc(Message& m) 在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m) 在 System。 Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m) 在 System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)IntPtr wparam, IntPtr lparam)IntPtr wparam, IntPtr lparam)
相关环境变量:COR_ENABLE_PROFILER= COR_PROFILER= PROCESSOR_ARCHITECTURE=x86
机器数据:处理器计数 = 4