Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.slnx support - use the new parser for .sln and .slnx #10836

Open
wants to merge 52 commits into
base: main
Choose a base branch
from

Conversation

surayya-MS
Copy link
Member

@surayya-MS surayya-MS commented Oct 17, 2024

Context

The .slnx support PR is split in 2 - 1. use new parser for .slnx, 2. use new parser for both .sln (under change wave) and .slnx. This is the follow-up PR.

Changes Made

  • Use Microsoft.VisualStudio.SolutionPersistence parser to parse .slnx and .sln (applied 17.13 change wave for .sln)
  • Throw ArgumentException if solutionFile is null or empty (applied 17.13 change wave)

Testing

  • Moved tests from SolutionFile_Tests that are old parser specific to the SolutionFile_OldParser_Tests.

  • Some of them already had duplicates there:
    BadVersionStamp, VersionTooLow, ParseSolutionFileWithDescriptionInformation, MissingNestedProject, ParseInvalidSolutionConfigurations1, ParseInvalidSolutionConfigurations2, ParseInvalidSolutionConfigurations3.

  • Deleted SolutionFile_Tests.SharedProjects test because it just checks dependencies and we already have test for that. It also has "GlobalSection(SharedMSBuildProjectFiles)" section but we do not parse it in the old parser.

  • Changed SolutionProjectGeneratorTests - refactored strings and used both old and new parsers in the tests (except where only the old one can be used, made a remark there about it)

  • Deleted GraphConstructionShouldThrowOnMissingSolutionDependencies test because it checks specifics of how solution projects' dependencies were parsed. "SolutionParseProjectDepNotFoundError" is thrown when the project dependency does not exist. And this is handled differently in the new parser - the dependency is not added at all if it did not exist in solution.

@kasperk81
Copy link
Contributor

lets see what happens if we now merge main (fingers crossed) :)

@kasperk81
Copy link
Contributor

the one failing test Microsoft.Build.BuildCheck.UnitTests.TaskInvocationCheckDataTests.ReportsComplexTaskParameters seems unrelated (it also failed in #10813)

rainersigwald added a commit to rainersigwald/msbuild that referenced this pull request Oct 24, 2024
This should help identify failures like dotnet#10836 (comment).
@rainersigwald
Copy link
Member

Diagnosability on that test is quite unfortunate, but hopefully fixable (#10886).

Copy link
Member

@rainersigwald rainersigwald left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This one also probably needs a standalone insertion to VS due to potential regression risk, and @dotnet/kitten should keep a close eye on optprof data generation/collection since we're adding an assembly load on the msbuild.exe foo.sln path.

src/Framework/ChangeWaves.cs Outdated Show resolved Hide resolved
src/Build/Construction/Solution/SolutionFile.cs Outdated Show resolved Hide resolved
src/Build/Construction/Solution/SolutionFile.cs Outdated Show resolved Hide resolved
src/Build/Construction/Solution/SolutionFile.cs Outdated Show resolved Hide resolved
documentation/wiki/ChangeWaves.md Outdated Show resolved Hide resolved
eng/dependabot/Packages.props Outdated Show resolved Hide resolved
rainersigwald added a commit to rainersigwald/msbuild that referenced this pull request Oct 25, 2024
This should help identify failures like dotnet#10836 (comment).
Comment on lines 5 to 6
<VersionPrefix>17.14.0</VersionPrefix>
<PackageValidationBaselineVersion>17.12.0</PackageValidationBaselineVersion>
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rainersigwald do you know if we should also update PackageValidationBaselineVersion?

eng/Versions.props Outdated Show resolved Hide resolved
Copy link
Contributor

@kasperk81 kasperk81 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants