mirror of
https://github.com/xoofx/markdig.git
synced 2026-02-03 21:36:36 +00:00
Markdig does not appear to be threadsafe #42
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 @dotnetchris on GitHub (Jul 22, 2016).
While running inside a Parallel.ForEeach
Would throw intermittent exceptions for
The character~is already used by another emphasis descriptor,The given key was not present in the dictionary.Given the dictionary error message, it appears somewhere you're using a dictionary where either you need to use ConcurrentDictionary or you need to copy the data.
When i switched my usage from the readonly field to
and closing over localPipeline.Value instead of _markdownPipeline the errors went away.
Here's a stack trace for when you have tearing that results in "the character..." error:
@xoofx commented on GitHub (Jul 23, 2016):
Good catch, this should be fixed by commit
82af7caThe initialization should not occur at parsing time but pipeline build time. When I switched to a Pipeline+Builder workflow, forgot to move the init code. I should take the time to cleanup a bit more this code.
@dotnetchris commented on GitHub (Jul 26, 2016):
Awesomely fast fix