Skip to content

Unescape slnf original solution path#46833

Merged
edvilme merged 7 commits intodotnet:release/9.0.3xxfrom
edvilme:edvilme-sln-escape-characters
Feb 24, 2025
Merged

Unescape slnf original solution path#46833
edvilme merged 7 commits intodotnet:release/9.0.3xxfrom
edvilme:edvilme-sln-escape-characters

Conversation

@edvilme
Copy link
Copy Markdown
Contributor

@edvilme edvilme commented Feb 13, 2025

Related to dotnet/msbuild#11050

If the original solution file name contains a special character such as @, it will be escaped when reading the json slnf file. Hence, it looks for the file with the incorrect path. This attempts to unescape the original solution path

@ghost ghost added Area-CLI untriaged Request triage from a team member labels Feb 13, 2025
@edvilme edvilme marked this pull request as ready for review February 13, 2025 18:13
Copilot AI review requested due to automatic review settings February 13, 2025 18:13
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot reviewed 2 out of 4 changed files in this pull request and generated no comments.

Files not reviewed (2)
  • test/TestAssets/TestProjects/TestAppWithSlnxAndSolutionFoldersWithSpecialCharacters/App.slnf: Language not supported
  • test/TestAssets/TestProjects/TestAppWithSlnxAndSolutionFoldersWithSpecialCharacters/App@something.slnx: Language not supported
Comments suppressed due to low confidence (1)

src/Cli/dotnet/SlnFileFactory.cs:96

  • Verify if Uri.UnescapeDataString is the correct method to use for unescaping the solution path. Ensure it does not introduce any unintended side effects.
filteredSolution.Description = Uri.UnescapeDataString(originalSolutionPathAbsolute);

@edvilme edvilme requested a review from a team February 13, 2025 18:27
@edvilme edvilme requested a review from Copilot February 13, 2025 18:46
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot reviewed 2 out of 4 changed files in this pull request and generated no comments.

Files not reviewed (2)
  • test/TestAssets/TestProjects/TestAppWithSlnxAndSolutionFoldersWithSpecialCharacters/App.slnf: Language not supported
  • test/TestAssets/TestProjects/TestAppWithSlnxAndSolutionFoldersWithSpecialCharacters/App@something.slnx: Language not supported

@edvilme edvilme enabled auto-merge (squash) February 24, 2025 17:22
@edvilme edvilme merged commit d10cf4b into dotnet:release/9.0.3xx Feb 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area-CLI untriaged Request triage from a team member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants