The SEHException can be caused by all kinds of things within any kind of .NET code. You can see various examples by looking globally for 'SEHException Revit':
https://duckduckgo.com/?q=SEHException+Revit
The second and third lines are more relevant, because they provide a hint on what is causing it:
An external component (your add-in?) executed a dynamic cast that failed.
I would suggest running your add-in in the debugger.
That will enable you to quickly pin down the offending cast operation.
Developer Advocacy and Support + The Building Coder + Autodesk Developer Network + ADN Open