-
Notifications
You must be signed in to change notification settings - Fork 10.3k
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
.Net 6 Preview 7 SDK seems to replicate resources from NuGet packages #36335
Comments
Thanks for contacting us. |
@MarkStega We believe this issue was caused because the content was being included as content and contentFiles within the nuget package. We believe this is solved in the RC2/RTM builds (to be sure, you can try using the nightly RTM bits, as there was an incrementalism bug that affected packing that didn't make it into the RC2 build and that could affect you if you were running pack after build or pack multiple times). |
Let us know if you still run into this issue with the RTM bits. |
I'm closing this for now as we believe the issue is fixed (@MarkStega also check out the answer I gave you in a similar issue regarding client assets compiled to the wwwroot folder as the output). Please let us know if after applying our suggestions you still run into issues and we'll reopen this ticket. |
I just tried this scenario using VS2022 17.1P1 & Net 6.0 RTM and the issue is still present
|
@MarkStega do you have a project that we can take a look at? |
@MarkStega did you follow the instructions we provided #35274 (comment) Also note the explanatory blog post here |
Hi @MarkStega. We have added the "Needs: Author Feedback" label to this issue, which indicates that we have an open question for you before we can take further action. This issue will be closed automatically in 7 days if we do not hear back from you by then - please feel free to re-open it if you come back to this issue after that time. |
@javiercn -- I am simply adding the nuget package Material.Blazor to the three projects in a hosted wasm app. See https://github.com/OptimiumHealth/BlazorAppMultipleNugetPackages I am simply adding nuget packages that have content; I fail to understand how the detail in the blog post will help. [EDIT] I see the issue but don't know why it happens. Simply adding a nuget package to a project now results in the assets from that nuget package getting placed in a wwwroot folder so when the name resolution occurs there is a conflict. [EDIT2] This seem problematic if I am using two different nuget packages of RCL's and they both define 'Styles.css' (a real possibility) then isn't a collision going to occur? It seems that the name of the asset alone isn't enough and it needs the package name so that you know the source of the asset. And if the asset is in multiple csproj projects then you need it to know to ignore duplicates [EDIT3] No, I haven't updated my real project to the new scheme outlined in #35274 (comment) ; I will at some point, but it was so painful to get the js & css generated I've been loath to mess with success. |
I have a solution that has multiple csproj/dll's; Prior to P7, I had references to the Nuget package 'Material.Blazor' in four of those csproj. With P7 the build failed with duplicate static content. Upon examination of the graphic view of the projects each that had the reference to Material.Blazor has content in wwwroot corresponding to the content in Material.Blazor (4 css files and 2 js files).
I had to remove references to Material.Blazor in three of the csproj projects and reply on them to reference the one csproj that included Material.Blazor.
Does this mean that the content is not only bundled in the included Material.Blazor nuget package but is also replicated in the assets of the project that references Material.Blazor?
The text was updated successfully, but these errors were encountered: