dotnet / dotnet/docfx

[Bug] Unable to build UWP project docs

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

Description

**Describe the bug**
When I run `docfx` for a UWP project, I get following error:
```
warning: [Failure] Msbuild failed when processing the file '\xxx.csproj' with message:
The imported project "C:\Program Files\dotnet\sdk\8.0.204\Microsoft\WindowsXaml\v16.0\Microsoft.Windows.UI.Xaml.CSharp.targets"
was not found.
Confirm that the expression in the Import declaration
"C:\Program Files\dotnet\sdk\8.0.204\Microsoft\WindowsXaml\v16.0\Microsoft.Windows.UI.Xaml.CSharp.targets"
is correct, and that the file exists on disk. xxx.csproj
```

**To Reproduce**
Steps to reproduce the behavior:
1. Create a UWP project
2. docfx init
3. run docfx command

**Expected behavior**
documents are generated

**Context (please complete the following information):**
- OS: Windows
- Docfx version: [e.g. 2.59.0] - 2.57.2

**Additional context**
For some reason docfx is building project with .NET 8 which should not be the case for UWP.

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.