Replace GeneratePkgDef with impl that does not load assemblies#43302
Replace GeneratePkgDef with impl that does not load assemblies#43302tmat merged 10 commits intodotnet:masterfrom
Conversation
src/VisualStudio/IntegrationTest/TestSetup/BindingAttributes.cs
Outdated
Show resolved
Hide resolved
jasonmalinowski
left a comment
There was a problem hiding this comment.
Looking fine so far; the better integration and handling where you can just mark a ProjectReference to have a binding redirect or codebase is really nifty.
There's some parts I can't review as the .pkgdefs are being considered by GitHub to be binary files. I'm guessing they're being encoded as UTF-16 and confusing the binary/text classifier? Can we reencode the files?
I absolutely do want us to reach out to the VS SDK owners though to get this integrated back so we're not maintaining this long term.
src/VisualStudio/IntegrationTest/TestSetup/BindingAttributes.cs
Outdated
Show resolved
Hide resolved
src/VisualStudio/IntegrationTest/TestSetup/Microsoft.VisualStudio.IntegrationTest.Setup.csproj
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
@dibarbet Why do we have to Codebase these? I guess if we're shipping our own copy then we have to be the ones to declare the codebase for this particular version?
7bd173d to
83790d5
Compare
b21c9ef to
4011180
Compare
4011180 to
907c489
Compare
jasonmalinowski
left a comment
There was a problem hiding this comment.
Only big issue (and reason for block) seems to be that the LiveShare .pkgdef includes stuff that would have came from attributes, but I don't see the attributes being deleted anywhere; I'm guessing that got forgotten and either there's a conflict somehow or the source version is dead.
Otherwise stuff looks good.
| "{d02dac01-ddd0-4ecc-8687-79a554852b14}"=dword:00000002 | ||
|
|
||
| [$RootKey$\Menus] | ||
| "{d02dac01-ddd0-4ecc-8687-79a554852b14}"=", Menus.ctmenu, 1" |
There was a problem hiding this comment.
We've confirmed there's no extra magic around menus this is also breaking?
There was a problem hiding this comment.
I don't understand the question. This is the exact value there used to be before.
src/VisualStudio/CSharp/Impl/Microsoft.VisualStudio.LanguageServices.CSharp.csproj
Show resolved
Hide resolved
src/VisualStudio/VisualBasic/Impl/LanguageService/VisualBasicPackage.vb
Outdated
Show resolved
Hide resolved
src/VisualStudio/VisualStudioDiagnosticsToolWindow/VisualStudioDiagnosticsWindowPackage.cs
Show resolved
Hide resolved
* upstream/master: (1099 commits) Specially handle tuple methods in CodeGenerator.EmitMethodInfoExpression for VB. (dotnet#43553) Remove unnecessary usings AssetStorage cleanup (dotnet#43511) Remove unused code (dotnet#43556) Revert anonymous type DebuggerDisplay change (dotnet#43575) Replace GeneratePkgDef with impl that does not load assemblies (dotnet#43302) Fix Update src/Analyzers/Core/CodeFixes/MakeFieldReadonly/AbstractMakeFieldReadonlyCodeFixProvider.cs PR feedback use capacity when creating builders. Push options down. Rename methods Fix GetSymbolInfo on ValueTuple declaration (dotnet#43467) Add support for cref-type-parameters. Support OOP with dynamic types. Support error locals in symbolkey Update tests to run OOP Update docs/Language Feature Status.md Update for partial methods Fix typos (dotnet#43494) ...
Removes all RegistrationAttributes applied to our VS package type definitions.
These attributes were used by CreatePkgDef tool to generate pkgdef entries. This tool loaded our assemblies during build and executed code on each RegistrationAttribute that produces pkgdef entries.
The replacement avoids loading assemblies during build, which is problematic, with an msbuild target that generates the pkgdef entries. Instead of adding attributes to VS package type definitions we now specify the raw pkgdef entries manually in PackageRegistration.pkgdef file. This file gets merged into the final pkgdef that will be included in the VSIX.
pkgdef entries that contain version information are auto-generated based on msbuild items (since the content is not static text). See 7bd173d#diff-1d351de3898f9b1efcf9aa14605f5766R4-R36 for detailed description.
TODO:
Changes to pkgdef
Roslyn.VisualStudio.Setup
added
removed