Visual Studio breaks without system exceptions breakpoint on rhino start

On every start of Rhino Visual Studio breaks on an exception being thrown:

Stacktrace:

System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.IO.FileNotFoundException: Could not load file or assembly 'System.Memory, Version=4.0.1.1, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' or one of its dependencies.
  at System.Resources.Extensions.DeserializingResourceReader.ValidateReaderType (System.String readerType) [0x00005] in <2064d16372bf44e38245b5612c18846f>:0
  at System.Resources.Extensions.DeserializingResourceReader._ReadResources () [0x00071] in <2064d16372bf44e38245b5612c18846f>:0
  at System.Resources.Extensions.DeserializingResourceReader.ReadResources () [0x00000] in <2064d16372bf44e38245b5612c18846f>:0
  at System.Resources.Extensions.DeserializingResourceReader..ctor (System.IO.Stream stream) [0x00054] in <2064d16372bf44e38245b5612c18846f>:0
  at at (wrapper managed-to-native) System.Reflection.RuntimeConstructorInfo.InternalInvoke(System.Reflection.RuntimeConstructorInfo,object,object[],System.Exception&)
  at System.Reflection.RuntimeConstructorInfo.InternalInvoke (System.Object obj, System.Object[] parameters, System.Boolean wrapExceptions) [0x00005] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/corlib/System.Reflection/RuntimeMethodInfo.cs:936
  --- End of inner exception stack trace ---
  at System.Reflection.RuntimeConstructorInfo.InternalInvoke (System.Object obj, System.Object[] parameters, System.Boolean wrapExceptions) [0x00015] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/corlib/System.Reflection/RuntimeMethodInfo.cs:944
  at System.Reflection.RuntimeConstructorInfo.DoInvoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00086] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/corlib/System.Reflection/RuntimeMethodInfo.cs:926
  at System.Reflection.RuntimeConstructorInfo.Invoke (System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/corlib/System.Reflection/RuntimeMethodInfo.cs:960
  at System.RuntimeType.CreateInstanceImpl (System.Reflection.BindingFlags bindingAttr, System.Reflection.Binder binder, System.Object[] args, System.Globalization.CultureInfo culture, System.Object[] activationAttributes, System.Threading.StackCrawlMark& stackMark) [0x0022b] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/referencesource/mscorlib/system/rttype.cs:5535
  at System.Activator.CreateInstance (System.Type type, System.Reflection.BindingFlags bindingAttr, System.Reflection.Binder binder, System.Object[] args, System.Globalization.CultureInfo culture, System.Object[] activationAttributes) [0x000b5] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/referencesource/mscorlib/system/activator.cs:107
  at System.Activator.CreateInstance (System.Type type, System.Object[] args) [0x00000] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/referencesource/mscorlib/system/activator.cs:112
  at System.Resources.ManifestBasedResourceGroveler.CreateResourceSet (System.IO.Stream store, System.Reflection.Assembly assembly) [0x000f9] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/referencesource/mscorlib/system/resources/manifestbasedresourcegroveler.cs:356
  at System.Resources.ManifestBasedResourceGroveler.GrovelForResourceSet (System.Globalization.CultureInfo culture, System.Collections.Generic.Dictionary`2[TKey,TValue] localResourceSets, System.Boolean tryParents, System.Boolean createIfNotExists, System.Threading.StackCrawlMark& stackMark) [0x000be] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/referencesource/mscorlib/system/resources/manifestbasedresourcegroveler.cs:152
  at System.Resources.ResourceManager.InternalGetResourceSet (System.Globalization.CultureInfo requestedCulture, System.Boolean createIfNotExists, System.Boolean tryParents, System.Threading.StackCrawlMark& stackMark) [0x00099] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/referencesource/mscorlib/system/resources/resourcemanager.cs:815
  at System.Resources.ResourceManager.InternalGetResourceSet (System.Globalization.CultureInfo culture, System.Boolean createIfNotExists, System.Boolean tryParents) [0x00002] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/referencesource/mscorlib/system/resources/resourcemanager.cs:759
  at System.Resources.ResourceManager.GetObject (System.String name, System.Globalization.CultureInfo culture, System.Boolean wrapUnmanagedMemStream) [0x00071] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/referencesource/mscorlib/system/resources/resourcemanager.cs:1427
  at System.Resources.ResourceManager.GetObject (System.String name, System.Globalization.CultureInfo culture) [0x00000] in /Users/curtis/Projects/McNeel/rhino7/src4/rhino4/MacOS/Mono64Framework/mono/mcs/class/referencesource/mscorlib/system/resources/resourcemanager.cs:1367
  at Grasshopper.My.Resources.Res_GUI.get_Doc_Aborted_48x48 () [0x00000] in /Users/bozo/TeamCity/buildAgent/work/96e64af5b81c6f85/src4/rhino4/Plug-ins/Grasshopper_osx/Grasshopper/Res_GUI.Designer.vb:292
  at Grasshopper.GUI.Canvas.GH_Canvas..cctor () [0x000a5] in /Users/bozo/TeamCity/buildAgent/work/96e64af5b81c6f85/src4/rhino4/Plug-ins/Grasshopper_osx/Grasshopper/GUI/GH_Canvas.vb:3281

Please post the results of the Rhino command _SystemInfo (copy&paste the text in a response here).

enabling just my code will mitigate the issue.

Rhino 7 SR15 2022-2-8 (Rhino 7, 7.15.22039.13002, Git hash:master @ 2833e18992fc4b5cf99bb29c4d8e8add4f02074d)
License type: Evaluation, build 2022-02-08
License details: Stand-Alone
Expires on: 2022-05-25

Apple macOS Version 12.2.1 (Build 21D62) (Physical RAM: 16Gb)
Mac Model Identifier: MacBookPro11,5
Language: en-DE (MacOS default)

AMD Radeon R9 M370X OpenGL Engine (OpenGL ver:4.1 ATI-4.7.103)

OpenGL Settings
  Safe mode: Off
  Use accelerated hardware modes: On
  Redraw scene when viewports are exposed: On
  
  Anti-alias mode: 4x
  Mip Map Filtering: Linear
  Anisotropic Filtering Mode: High
  
  Vendor Name: ATI Technologies Inc.
  Render version: 4.1
  Shading Language: 4.10
  Maximum Texture size: 16384 x 16384
  Z-Buffer depth: n/a
  Maximum Viewport size: 16384 x 16384
  Total Video Memory: 2 GB
  Graphics: AMD Radeon R9 M370X
  Displays: Color LCD (221dpi 2x), DELL U2412M (94dpi 1x)

Graphics processors
  Intel Iris Pro (1536 MB)
  AMD Radeon R9 M370X (2 GB)
    Color LCD (1440 x 900)
    DELL U2412M (1920 x 1200)

USB devices
  Apple Inc.: Apple Internal Keyboard / Trackpad
  Broadcom Corp.: Bluetooth USB Host Controller

Bluetooth devices
  None

Third party kernel extensions
  None

Third party plugins
  /usr/lib/swift/libswiftCloudKit.dylib
  /usr/lib/swift/libswiftCore.dylib
  /usr/lib/swift/libswiftCoreData.dylib
  /usr/lib/swift/libswiftCoreFoundation.dylib
  /usr/lib/swift/libswiftCoreGraphics.dylib
  /usr/lib/swift/libswiftCoreLocation.dylib
  /usr/lib/swift/libswiftDarwin.dylib
  /usr/lib/swift/libswiftDispatch.dylib
  /usr/lib/swift/libswiftFoundation.dylib
  /usr/lib/swift/libswiftIOKit.dylib
  /usr/lib/swift/libswiftObjectiveC.dylib
  /usr/lib/swift/libswiftXPC.dylib
  /usr/lib/swift/libswiftos.dylib
  /usr/lib/swift/libswift_Concurrency.dylib
  /usr/lib/swift/libswiftAppKit.dylib
  /usr/lib/swift/libswiftCoreImage.dylib
  /usr/lib/swift/libswiftMetal.dylib
  /usr/lib/swift/libswiftQuartzCore.dylib
  /usr/lib/swift/libswiftCryptoTokenKit.dylib
  /usr/lib/swift/libswiftAccelerate.dylib
  /usr/lib/swift/libswiftContacts.dylib
  /usr/lib/swift/libswiftCoreAudio.dylib
  /usr/lib/swift/libswiftCoreML.dylib
  /usr/lib/swift/libswiftCoreMedia.dylib
  /usr/lib/swift/libswiftOSLog.dylib
  /usr/lib/swift/libswiftVision.dylib
  /usr/lib/swift/libswiftsimd.dylib
  /usr/lib/swift/libswiftNetwork.dylib
  /usr/lib/swift/libswiftDemangle.dylib
  /usr/lib/swift/libswiftFileProvider.dylib
  /usr/lib/swift/libswiftIntents.dylib
  /usr/lib/swift/libswiftPrivate_BiomePubSub.dylib
  /usr/lib/swift/libswiftPrivate_BiomeStreams.dylib
  /usr/lib/swift/libswiftUniformTypeIdentifiers.dylib
  /usr/lib/swift/libswiftAVFoundation.dylib
  /usr/lib/swift/libswiftCoreMIDI.dylib
  /usr/lib/log/liblog_network.dylib


Rhino plugins that do not ship with Rhino
  /Users/jonas/WebstormProjects/normcut/rhinoplugin/RhinoPlugin/bin/Debug/net452/Normcut.rhp	"Normcut"	0.1.4.0

Rhino plugins that ship with Rhino
  /Applications/Rhino 7.app/Contents/PlugIns/PanelingTools.rhp	"PanelingTools"	7.15.22039.1002
  /Applications/Rhino 7.app/Contents/Frameworks/RhCore.framework/Resources/ManagedPlugIns/GrasshopperPlugin.rhp	"Grasshopper"	7.15.22039.13002
  /Applications/Rhino 7.app/Contents/PlugIns/Displacement.rhp	"Displacement"	7.15.22039.1002
  /Applications/Rhino 7.app/Contents/Frameworks/RhMaterialEditor.framework	"Renderer Development Kit"	7.15.22039.1002
  /Applications/Rhino 7.app/Contents/Frameworks/RhCore.framework/Resources/ManagedPlugIns/RhinoDLR_Python.rhp	"IronPython"	7.15.22039.13002
  /Applications/Rhino 7.app/Contents/PlugIns/NamedSnapshots.rhp	"Snapshots"	7.15.22039.1002
  /Applications/Rhino 7.app/Contents/Frameworks/RhCore.framework/Resources/ManagedPlugIns/Commands.rhp	"Commands"	7.15.22039.13002
  /Applications/Rhino 7.app/Contents/Frameworks/RhCore.framework/Resources/ManagedPlugIns/RhinoRenderCycles.rhp	"Rhino Render"	7.15.22039.13002
  /Applications/Rhino 7.app/Contents/Frameworks/RhCore.framework/Resources/ManagedPlugIns/RDK_EtoUI.rhp	"RDK_EtoUI"	7.15.22039.13002
  /Applications/Rhino 7.app/Contents/PlugIns/RhinoRender.rhp	"Legacy Rhino Render"	7.15.22039.1002
  /Applications/Rhino 7.app/Contents/Frameworks/RhCore.framework/Resources/ManagedPlugIns/RhinoCycles.rhp	"RhinoCycles"	7.15.22039.13002

I did not find this setting for Visual Studio for mac. I do not have a System.Exception Breakpoint.

I think this problem was dealt with in the latest SR, you may want to update to 7SR17. (Could’ve been fix was done for SR18, so if SR17 doesn’t work please try the service release candidate).

Thank you! Updating to 7SR17 solved the issue!

1 Like