GridTable Parse #195

Open
opened 2026-01-29 14:30:05 +00:00 by claunia · 0 comments
Owner

Originally created by @ashleybrookesics on GitHub (Feb 20, 2018).

Im using the markdig processor with all the advanced features turned on, setup here:

pipeline = New MarkdownPipelineBuilder().UseAdvancedExtensions().Build()
_Content.ContentText = Markdig.Markdown.ToHtml(DB.ProcessMarkdown_WasabiCustomTags(cvrow.ContentText), pipeline)

Got an error with the following grid table markup:

+------------+--+--+--+--+--+--+--+
| 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |
+==+==+==+==+==+==+==+==+==+

Error Strack trace:
[IndexOutOfRangeException: Index was outside the bounds of the array.]
Markdig.Helpers.StringSlice.TrimStart() +112
Markdig.Extensions.Tables.GridTableParser.SetRowSpanState(List1 columns, StringSlice line, Boolean& isHeaderRow, Boolean& hasRowSpan) +248
Markdig.Extensions.Tables.GridTableParser.HandleNewRow(BlockProcessor processor, GridTableState tableState, Table gridTable) +90
Markdig.Parsers.BlockProcessor.TryContinueBlocks() +202
Markdig.Parsers.BlockProcessor.ProcessLine(StringSlice newLine) +66
Markdig.Parsers.MarkdownParser.ProcessBlocks() +121
Markdig.Parsers.MarkdownParser.Parse() +16
Markdig.Markdown.ToHtml(String markdown, TextWriter writer, MarkdownPipeline pipeline) +144
Markdig.Markdown.ToHtml(String markdown, MarkdownPipeline pipeline) +58

I know this looks like its against the rules of the grid table but it still caused a run time error. We got this error while experimenting with grid tables. We've found them to be incredibly strict and difficult to setup with alot of text in each column.

Thanks.

Originally created by @ashleybrookesics on GitHub (Feb 20, 2018). Im using the markdig processor with all the advanced features turned on, setup here: pipeline = New MarkdownPipelineBuilder().UseAdvancedExtensions().Build() _Content.ContentText = Markdig.Markdown.ToHtml(DB.ProcessMarkdown_WasabiCustomTags(cvrow.ContentText), pipeline) Got an error with the following grid table markup: `+------------+--+--+--+--+--+--+--+ ` `| 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | ` `+==+==+==+==+==+==+==+==+==+` Error Strack trace: `[IndexOutOfRangeException: Index was outside the bounds of the array.]` ` Markdig.Helpers.StringSlice.TrimStart() +112` ` Markdig.Extensions.Tables.GridTableParser.SetRowSpanState(List1 columns, StringSlice line, Boolean& isHeaderRow, Boolean& hasRowSpan) +248` ` Markdig.Extensions.Tables.GridTableParser.HandleNewRow(BlockProcessor processor, GridTableState tableState, Table gridTable) +90` ` Markdig.Parsers.BlockProcessor.TryContinueBlocks() +202` ` Markdig.Parsers.BlockProcessor.ProcessLine(StringSlice newLine) +66` ` Markdig.Parsers.MarkdownParser.ProcessBlocks() +121` ` Markdig.Parsers.MarkdownParser.Parse() +16` ` Markdig.Markdown.ToHtml(String markdown, TextWriter writer, MarkdownPipeline pipeline) +144` ` Markdig.Markdown.ToHtml(String markdown, MarkdownPipeline pipeline) +58` I know this looks like its against the rules of the grid table but it still caused a run time error. We got this error while experimenting with grid tables. We've found them to be incredibly strict and difficult to setup with alot of text in each column. Thanks.
claunia added the bugPR Welcome! labels 2026-01-29 14:30:05 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/markdig#195