dotnet / dotnet/docfx

[Bug] error InvalidMarkdown: Markup failed: Markdown elements in the input are too deeply nested - depth limit exceeded. Input is most likely not sensible or is a very large table..

Open
#8,854 2 comments 0 reactions 0 assignees View on GitHub
markdown
Dominant language
C#
Stars
4.4k
Forks
890
Avg merge
2h 11m
Merged PRs (30d)
10

Description

**Describe the bug**
After the upgrade from docfx v2.48 to the latest 2.67 docfx can't build our existing documentation https://github.com/2sic/2sxc-docs because of error `InvalidMarkdown: Markup failed: Markdown elements in the input are too deeply nested - depth limit exceeded. Input is most likely not sensible or is a very large table..`

**To Reproduce**
Here is an example: [docfx-poc04.zip](https://github.com/dotnet/docfx/files/11706273/docfx-poc04.zip).
Steps to reproduce the behavior:
1. create a new docfx project
2. add our table [intro.md](https://github.com/dotnet/docfx/files/11706275/intro.md) in md format to `articles\intro.md`
![image](https://github.com/dotnet/docfx/assets/2724850/625950f2-45be-4e5c-b2b7-a9de78d1390a)
3. run `docfx` in `docfx_project`
![image](https://github.com/dotnet/docfx/assets/2724850/d49c4e6c-aa11-471c-bd46-e5e165584f87)

```log
C:\Projects\_Test\docfx\docfx-poc04\docfx_project\articles\intro.md: error InvalidMarkdown: Markup failed: Markdown elements in the input are too deeply nested - depth limit exceeded. Input is most likely not sensible or is a very large table..
C:\Projects\_Test\docfx\docfx-poc04\docfx_project\articles\intro.md: Trouble processing file - C:\Projects\_Test\docfx\docfx-poc04\docfx_project\articles\intro.md, with error - Markup failed: Markdown elements in the input are too deeply nested - depth limit exceeded. Input is most likely not sensible or is a very large table..
```

**Expected behavior**
Docfx build should build docs (as was in v2.48).

**Context (please complete the following information):**
- OS: Windows 11
- Docfx version: 2.67.3

**Additional context**
There is a workaround. Use \` \` instead of \`\` to avoid `Markup failed: Markdown elements in the input are too deeply nested - depth limit exceeded. Input is most likely not sensible or is a very large table.`.

In lines 9 and 10, in the third table column replace \`\` with \` \` (one space between backticks) and build.
![image](https://github.com/dotnet/docfx/assets/2724850/500c6574-64fb-4494-8f72-ca451c8b932e)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.