mirror of
https://github.com/xoofx/markdig.git
synced 2026-02-10 21:40:00 +00:00
The type initializer for 'Markdig.Wpf.MarkdownViewer' threw an exception #248
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @FoggyFinder on GitHub (Dec 16, 2018).
The code below doesn't compile with new version of markdig (0.15.5)
where
TestWindow.xamlis:It works fine with 0.15.4 although.
Initally I opened issue in markdig.wpf. Still not sure where it should be open.
@xoofx commented on GitHub (Dec 16, 2018):
Doesn't compile? What's the error? How do you want me to evaluate if this is a markdig issue?
@FoggyFinder commented on GitHub (Dec 16, 2018):
The type initializer for 'Markdig.Wpf.MarkdownViewer' threw an exceptionI can attach test project but let me check it on C# project first.
@MihaZupan commented on GitHub (Dec 16, 2018):
This is a runtime error
@xoofx commented on GitHub (Dec 16, 2018):
Yes, likely a constructor has been changed in markdig, until 1.0, markdig API can break, so Markdig.Wpf has to be recompiled with latest version
@FoggyFinder commented on GitHub (Dec 16, 2018):
@markheath no, it is a compile error here :-)
@Kryptos-FR can you check it again?
@xoofx commented on GitHub (Dec 17, 2018):
Note that markdig might be able also to provide backward compatibility on this constructor. PR welcome.
@Kryptos-FR commented on GitHub (Dec 17, 2018):
It works for me with if I upgrade to 0.15.5. I did not try to just replace the dll (without recompiling) because I assumed minor versions would not break binary compatibility.
@xen2 maybe I should package with exact version instead of
>=as a dependency?@xoofx commented on GitHub (Dec 17, 2018):
Yeah, I'm trying to follow semver2.0, specifically the item 4:
So in your case, an exact version dependency might be better
@Kryptos-FR commented on GitHub (Dec 18, 2018):
Just FYI the culprit was the
UseAutoLinks()extension method that now has a second optional parameter.@MihaZupan commented on GitHub (Dec 18, 2018):
Effectively this: https://stackoverflow.com/a/23517490/6845657
Source level compatibility is kept but dlls aren't binary compatible