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

Update feature branch #10680

Merged
merged 181 commits into from
Aug 14, 2024
Merged

Update feature branch #10680

merged 181 commits into from
Aug 14, 2024

Conversation

marcarro
Copy link
Contributor

Summary of the changes

Keep feature branch up to date

Fixes:

phil-allen-msft and others added 30 commits July 5, 2024 10:34
…Formatting_NetFx/FormattingTestBase.cs

Co-authored-by: Dustin Campbell <dustin@teamcampbell.org>
All of the types MS.VS.LanguageServices.Razor elide "LanguageServices" from their namespaces. So, each type has `Microsoft.VisualStudio.Razor` its root namespace. These have been kept in sync by pure discipline until this change.

This change updates the `<RootNamespace>` for MS.VS.LanguageServices.Razor to not include "LanguageServices". That way, new files in this project will be created with a root namespace of `Microsoft.VisualStudio.Razor`. Normally, changing the `<RootNamespace>` should be a painless process. However, it was blocked due to issues caused by the MS.ANC.Razor.Serialization.Json shared project's embedded string resources. I've gone ahead and sorted that so that updating the `<RootNamespace>` is now possible.
All of the types MS.VS.LanguageServices.Razor elide "LanguageServices"
from their namespaces. So, each type has `Microsoft.VisualStudio.Razor`
its root namespace. These have been kept in sync by pure discipline
until this change.

This change updates the `<RootNamespace>` for
MS.VS.LanguageServices.Razor to not include "LanguageServices". That
way, new files in this project will be created with a root namespace of
`Microsoft.VisualStudio.Razor`. Normally, changing the `<RootNamespace>`
should be a painless process. However, it was blocked due to issues
caused by the MS.ANC.Razor.Serialization.Json shared project's embedded
string resources. I've gone ahead and sorted that so that updating the
`<RootNamespace>` is now possible.
It's a complete coincidence I'm adding this now, and definitely not because I made a mistake in one of the aforementioned places
Since we updated to a .NET 9 SDK, the
MS.ANC.Razor.Microbenchmarks.Generator unit tests have failed to run
locally. This is because these test use Benchmark.NET, which performs a
builder at runtime targeting .NET 8. This works fine in CI because it
uses a .NET 8 SDK.

This change just adds the most recent .NET 8 runtime version to the
list of runtimes in Razor's global.json. So, it'll get installed into
the .dotnet folder and the Microbenchmarks.Generator will run and stop
reporting a spurious error.
…Test

Uses `UseVSTestRunner` instead of `TestRunneName`.

Fixes #10660
Separated commits to functional change and code moving. This moves the
feature flag check into tooling instead of relying on the compiler to
know and generate documents differently.

That also allows for correctly doing document generation of
designtime/runtime from the tooling side. If FUSE is enabled tooling
will use runtime in all places except formatting. This is to keep
formatting working as it does today without FUSE and start A/B testing
faster.
Since we updated to a .NET 9 SDK, the
MS.ANC.Razor.Microbenchmarks.Generator unit tests have failed to run
locally. This is because these test use Benchmark.NET, which performs a
builder at runtime targeting .NET 8. This works fine in CI because it
uses a .NET 8 SDK.

This change just adds the most recent .NET 8 runtime version to the list
of runtimes in Razor's global.json. So, it'll get installed into the
.dotnet folder and the Microbenchmarks.Generator will run and stop
reporting a spurious error.
… Build ID 2500297 (#10663)

This is the pull request automatically created by the OneLocBuild task
in the build process to check-in localized files generated based upon
translation source files (.lcl files) handed-back from the downstream
localization pipeline. If there are issues in translations, visit
https://aka.ms/icxLocBug and log bugs for fixes. The OneLocBuild wiki is
https://aka.ms/onelocbuild and the localization process in general is
documented at https://aka.ms/AllAboutLoc.
Part of #9519

Brings document highlight to cohosting, including tests. Also added some
basic tests for `RazorServices` and `Services.props`.
[
"RemoveUnnecessaryImportsFixable",
"IDE0005_gen", // Using directive is unnecessary
];
]).ToFrozenSet();
Copy link
Contributor

Choose a reason for hiding this comment

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

personally I like "Stay cool, birdboy!"

jaredpar and others added 15 commits August 9, 2024 15:26
* Move to central package pinning

This should make it much easier for us to respond to CG alerts in the
future. All that will need to be done is add an entry in
Directory.Packages.props and it will automatically impact all consumers
of it.

Consider this example in Roslyn for how to respond to a CG issue

dotnet/roslyn#74653
Every `TagHelperDescriptorProviderContext` creates an `ItemCollection`
to hold onto, at most, two objects: a `Compilation` and a target
`ISymbol`. This is enormously wasteful because an `ItemCollection`
internally creates a `ConcurrentDictionary<object, object>`. So, I've
changed `TagHelperDescriptorProviderContext` to just hold onto a
compilation and a target symbol and avoid the `ItemCollection`
altogether.

I recommend reviewing commit-by-commit.

Also, I bumped into a long standing compiler bug in
`EventHandlerTagHelperDescriptorProvider` that was recently filed by a
customer: #10497. I opted to stay
on target and not fix this issue, but I made it painfully obvious where
the fix would go. 😄
…release/dev17.10-to-release/dev17.11

* upstream/release/dev17.10:
  Upgrade System.Security.Cryptography.Xml to avoid CG alerts.
  Update System.Formats.Asn1 to address CG alert.
  Manually reference Microsoft.IO.Redist 6.0.1 where needed to fix CG alerts.
  Upgrade testing analyzers to address CG alert.
This is an automatically generated pull request from release/dev17.10
into release/dev17.11.


Once all conflicts are resolved and all the tests pass, you are free to
merge the pull request. 🐯

## Troubleshooting conflicts

### Identify authors of changes which introduced merge conflicts
Scroll to the bottom, then for each file containing conflicts copy its
path into the following searches:
- https://github.com/dotnet/razor/find/release/dev17.10
- https://github.com/dotnet/razor/find/release/dev17.11

Usually the most recent change to a file between the two branches is
considered to have introduced the conflicts, but sometimes it will be
necessary to look for the conflicting lines and check the blame in each
branch. Generally the author whose change introduced the conflicts
should pull down this PR, fix the conflicts locally, then push up a
commit resolving the conflicts.

### Resolve merge conflicts using your local repo
Sometimes merge conflicts may be present on GitHub but merging locally
will work without conflicts. This is due to differences between the
merge algorithm used in local git versus the one used by GitHub.
``` bash
git fetch --all
git checkout -t upstream/merges/release/dev17.10-to-release/dev17.11
git reset --hard upstream/release/dev17.11
git merge upstream/release/dev17.10
# Fix merge conflicts
git commit
git push upstream merges/release/dev17.10-to-release/dev17.11 --force
```
This is an automatically generated pull request from release/dev17.11
into main.


Once all conflicts are resolved and all the tests pass, you are free to
merge the pull request. 🐯

## Troubleshooting conflicts

### Identify authors of changes which introduced merge conflicts
Scroll to the bottom, then for each file containing conflicts copy its
path into the following searches:
- https://github.com/dotnet/razor/find/release/dev17.11
- https://github.com/dotnet/razor/find/main

Usually the most recent change to a file between the two branches is
considered to have introduced the conflicts, but sometimes it will be
necessary to look for the conflicting lines and check the blame in each
branch. Generally the author whose change introduced the conflicts
should pull down this PR, fix the conflicts locally, then push up a
commit resolving the conflicts.

### Resolve merge conflicts using your local repo
Sometimes merge conflicts may be present on GitHub but merging locally
will work without conflicts. This is due to differences between the
merge algorithm used in local git versus the one used by GitHub.
``` bash
git fetch --all
git checkout -t upstream/merges/release/dev17.11-to-main
git reset --hard upstream/main
git merge upstream/release/dev17.11
# Fix merge conflicts
git commit
git push upstream merges/release/dev17.11-to-main --force
```
…release/dev17.11-to-release/dev17.12

* upstream/release/dev17.11:
  Upgrade System.Security.Cryptography.Xml to avoid CG alerts.
  Update System.Formats.Asn1 to address CG alert.
  Manually reference Microsoft.IO.Redist 6.0.1 where needed to fix CG alerts.
  Upgrade testing analyzers to address CG alert.
  Update version of system.security.cryptography.xml in use in 17.10 (#10525)
Part of #9519
Fixes #10688

Tried not to go on too many side quests with this one, but I guess
review commit-at-a-time if you want to double check :)
This is an automatically generated pull request from release/dev17.11
into release/dev17.12.


Once all conflicts are resolved and all the tests pass, you are free to
merge the pull request. 🐯

## Troubleshooting conflicts

### Identify authors of changes which introduced merge conflicts
Scroll to the bottom, then for each file containing conflicts copy its
path into the following searches:
- https://github.com/dotnet/razor/find/release/dev17.11
- https://github.com/dotnet/razor/find/release/dev17.12

Usually the most recent change to a file between the two branches is
considered to have introduced the conflicts, but sometimes it will be
necessary to look for the conflicting lines and check the blame in each
branch. Generally the author whose change introduced the conflicts
should pull down this PR, fix the conflicts locally, then push up a
commit resolving the conflicts.

### Resolve merge conflicts using your local repo
Sometimes merge conflicts may be present on GitHub but merging locally
will work without conflicts. This is due to differences between the
merge algorithm used in local git versus the one used by GitHub.
``` bash
git fetch --all
git checkout -t upstream/merges/release/dev17.11-to-release/dev17.12
git reset --hard upstream/release/dev17.12
git merge upstream/release/dev17.11
# Fix merge conflicts
git commit
git push upstream merges/release/dev17.11-to-release/dev17.12 --force
```
This is an automatically generated pull request from release/dev17.12
into main.


Once all conflicts are resolved and all the tests pass, you are free to
merge the pull request. 🐯

## Troubleshooting conflicts

### Identify authors of changes which introduced merge conflicts
Scroll to the bottom, then for each file containing conflicts copy its
path into the following searches:
- https://github.com/dotnet/razor/find/release/dev17.12
- https://github.com/dotnet/razor/find/main

Usually the most recent change to a file between the two branches is
considered to have introduced the conflicts, but sometimes it will be
necessary to look for the conflicting lines and check the blame in each
branch. Generally the author whose change introduced the conflicts
should pull down this PR, fix the conflicts locally, then push up a
commit resolving the conflicts.

### Resolve merge conflicts using your local repo
Sometimes merge conflicts may be present on GitHub but merging locally
will work without conflicts. This is due to differences between the
merge algorithm used in local git versus the one used by GitHub.
``` bash
git fetch --all
git checkout -t upstream/merges/release/dev17.12-to-main
git reset --hard upstream/main
git merge upstream/release/dev17.12
# Fix merge conflicts
git commit
git push upstream merges/release/dev17.12-to-main --force
```
…release/dev17.12-to-main

# Conflicts:
#	src/Razor/test/Microsoft.VisualStudio.Razor.IntegrationTests/Microsoft.VisualStudio.Razor.IntegrationTests.csproj
This is an automatically generated pull request from release/dev17.12
into main.


Once all conflicts are resolved and all the tests pass, you are free to
merge the pull request. 🐯

## Troubleshooting conflicts

### Identify authors of changes which introduced merge conflicts
Scroll to the bottom, then for each file containing conflicts copy its
path into the following searches:
- https://github.com/dotnet/razor/find/release/dev17.12
- https://github.com/dotnet/razor/find/main

Usually the most recent change to a file between the two branches is
considered to have introduced the conflicts, but sometimes it will be
necessary to look for the conflicting lines and check the blame in each
branch. Generally the author whose change introduced the conflicts
should pull down this PR, fix the conflicts locally, then push up a
commit resolving the conflicts.

### Resolve merge conflicts using your local repo
Sometimes merge conflicts may be present on GitHub but merging locally
will work without conflicts. This is due to differences between the
merge algorithm used in local git versus the one used by GitHub.
``` bash
git fetch --all
git checkout -t upstream/merges/release/dev17.12-to-main
git reset --hard upstream/main
git merge upstream/release/dev17.12
# Fix merge conflicts
git commit
git push upstream merges/release/dev17.12-to-main --force
```
@phil-allen-msft
Copy link
Contributor

This PR is for already reviewed changes (in main) flowing into the feature branch.

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.