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

Reflection patterns can not resolve assemblies outside of the reference closure #943

Closed
sbomer opened this issue Feb 10, 2020 · 2 comments
Closed

Comments

@sbomer
Copy link
Member

sbomer commented Feb 10, 2020

When a supported reflection pattern references an assembly that is part of the linker input set, but not in the reference closure of any roots (and thus not loaded into the LinkContext assemblies by LoadReferencesStep or any other step that comes before MarkStep), the pattern will fail to resolve. Since simple reflection patterns are often used for activation without a build-time dependency, this seems like something worth supporting. See dotnet/sdk#4017 for the original issue with a repro.

#843 is a similar issue where PreserveDependency doesn't cause xml roots from the referenced assembly to be processed.

If we fix this, we should be able to undo dotnet/runtime#32023.

sbomer added a commit to sbomer/linker that referenced this issue Nov 4, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and constant propagation will also happen for lazy assemblies

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Nov 4, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and constant propagation will also happen for lazy assemblies

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Nov 4, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Nov 4, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Nov 4, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Nov 4, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Nov 4, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Nov 4, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
@marek-safar marek-safar added this to the .NET 6.0 milestone Nov 13, 2020
sbomer added a commit to sbomer/linker that referenced this issue Dec 2, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Dec 3, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Dec 7, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Dec 9, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Dec 10, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Dec 14, 2020
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Jan 4, 2021
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Jan 15, 2021
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
sbomer added a commit to sbomer/linker that referenced this issue Jan 20, 2021
This introduces the ability to add assemblies to LinkContext lazily and have them
processed in MarkStep. For now, the only additional processing is to
load references and run the TypeMap logic. Later, embedded XML processing and
constant propagation will also happen for lazy assemblies.

This is Phase 1 outlined in dotnet#1164 (comment).

Fixes dotnet#943
Fixes dotnet#1079
@marek-safar
Copy link
Contributor

I believe this should be fixed. @sbomer could you please undo the runtime change so we can fully verify this and close ?

@sbomer
Copy link
Member Author

sbomer commented Mar 12, 2021

Fixed by #1666, runtime workarounds removed in dotnet/runtime#49523.

@sbomer sbomer closed this as completed Mar 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants