StackOverflow error if `api` folder is missed from the content
- Dominant language
- C#
- Stars
- 4.4k
- Forks
- 890
- Avg merge
- 2h 11m
- Merged PRs (30d)
- 10
Description
**Operation System**: `Windows`
**DocFX Version Used**: 2.45
**Template used**: `default`
I've missed to include `api` folder to the build:content. So docfx.json was like below
```json
"build": {
"content": [
{
"files": [
"articles/**.md",
"articles/**/toc.yml",
"toc.yml",
"*.md"
]
}
],
```
But I have used index.md with the `xref:WindowsApplication1` namespace reference. It has to be resolved to the api/WindowsApplication1.yml.
my index.md file contains WindowsApplication1 reference like
```
some text [controllers](xref:WindowsApplication1)
```
Then I've tried to generate metadata and run build. The problem is that StackOverflow exception is raised.
**Steps to Reproduce**:
1. exclude `api` folder from the docfx.json `build:content` element (it was by mistake)
2. run docfx metadata (`api` folder content is generated properly)
3. run `docfx build`
**Expected Behavior**:
xref can't be resolved warning
**Actual Behavior**:
StackOverflow exception
PS if toc.yml file has reference to the `api` folder topicUid no exception is raised. However no warning is generated and link is not created.
Contributor guide
Assessment
This issue has not been assessed yet.