I’ve now moved everything out of my libraries folder and now I get different but still disturbing error messages.
Any thoughts, tips or tricks on this is more than welcome. As the beginner I am, I’m truly in the dark here…
I get the following when attempting to debug an “out of the box” empty GHA template:
Managed Debugging Assistant ‘DisconnectedContext’ has detected a problem in ‘c:\Program Files (x86)\Rhinoceros 5\System\Rhino4.exe’.
Additional information: Transition into COM context 0x650818 for this RuntimeCallableWrapper failed with the following error: Det anropade objektet har kopplats från sina klienter. (Exception from HRESULT: 0x80010108 (RPC_E_DISCONNECTED)). This is typically because the COM context 0x650818 where this RuntimeCallableWrapper was created has been disconnected or it is busy doing something else. Releasing the interfaces from the current COM context (COM context 0x650760). This may cause corruption or data loss. To avoid this problem, please ensure that all COM contexts/apartments/threads stay alive and are available for context transition, until the application is completely done with the RuntimeCallableWrappers that represents COM components that live inside them.
…And when trying to debug a simple component I’ve written (and which seems to work fine on my other computer), I get this instead:
Managed Debugging Assistant ‘ContextSwitchDeadlock’ has detected a problem in ‘c:\Program Files (x86)\Rhinoceros 5\System\Rhino4.exe’.
Additional information: The CLR has been unable to transition from COM context 0x4b0760 to COM context 0x4b0818 for 60 seconds. The thread that owns the destination context/apartment is most likely either doing a non pumping wait or processing a very long running operation without pumping Windows messages. This situation generally has a negative performance impact and may even lead to the application becoming non responsive or memory usage accumulating continually over time. To avoid this problem, all single threaded apartment (STA) threads should use pumping wait primitives (such as CoWaitForMultipleHandles) and routinely pump messages during long running operations.
I turned of ‘Deadlock’ in the debug exceptions and now it seem to work just fine when trying to debug the component I’ve written. As it appears, it was elefront_2.gha that caused the issue in the first place. When I put that back into my libraries starting Grasshopper during Visual Studio debug does not work.