dotnet / dotnet/msbuild

Build error MSB4067 (UnrecognizedChildElement) when building a solution with rptproj or dwproj projects

Open
#2,064 28 comments 12 reactions 0 assignees View on GitHub
Area: Solution (.sln) bug regression triaged
Dominant language
C#
Stars
5.5k
Forks
1.5k
Avg merge
1d 8h
Merged PRs (30d)
141

Description

When using MSBuild 15.0, cleaning or building a solution which contains rptproj or dwproj projects gives the following error:

> Reports.rptproj(3,3): error MSB4067: The element <State> beneath element <Project> is unrecognized.

When using MSBuild 14.0, the behaviour is better: it logs warnings (MSB4078) about unsupported projects:

> warning MSB4078: The project file "Reports.rptproj" is not supported by MSBuild and cannot be built.

The latter behaviour is more desirable (for me, at least): I would like to able to build a solution in a configuration which includes the .rptproj files. This would allow me to include these projects when building the solution in Visual Studio, and to be able to use the same configuration when building the solution via an MSBuild script.

Is this change of behaviour a bug? The message certainly seems like it is attempting to parse the rptproj file into some structure to which it doesn't belong. If it is not, is there a way to downgrade the error MSB4067 to a warning, or to skip certain projects when building a solution? The `/ignoreprojectextensions:.rptproj` option does not prevent the error.

Note: this issue relates to [this Stack Overflow post](https://stackoverflow.com/q/43735390/5513562).

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.