-
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
Blazor and .NET6 creates an error: EntrypointInvoker in assembly Microsoft.AspNetCore.Components.WebAssembly #38436
Comments
Hello, thanks for contacting us. The |
Hi @erossini. 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. |
This is the csproj
|
@erossini do you also mind including the |
Hi @erossini. 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. |
This is the |
Same problem here. I cleared out all bin/obj and other intermediate files I could find. |
Ohh but clearing my browser cache fixed it. Try that! |
Do you have your server configured to include the correct cache headers? For instance, in a Blazor hosted app, or in development, Blazor will include the following headers when serving this file: If you are unable to configure the server headers, you could consider using some cache busting mechanism such as adding a nonce to your blazor.webassembly.js script src. |
I use an hosting provider and I don't have a lot of option to change the configuration of the server. When you say "cache busting mechanism", what do you mean? How can I do that? I saw those links: |
Good to know @pranavkm thanks! My only hesitation though is won't that hurt us with those large AOT payloads? |
Why do you use AOT? In my test, it is working also without it |
I'm just asking if the HTTP headers prohibited caching, wouldn't that make it slower for users to download the application after the first visit? I just mention AOT because it adds significant file size. |
@legistek it's specifically for the blazor.webassembly.js file. Blazor manages downloading all other files which does not rely on the browser's HTTP cache. You can verify this by looking at your network tab after the app has been initialized once. |
Ah very clever! Thanks for clarifying! |
This issue has been resolved and has not had any activity for 1 day. It will be closed for housekeeping purposes. See our Issue Management Policies for more information. |
Ran into the same issue, but it wasn't in the browser cache, it was in the CDN cache (Cloudflare in my case). |
In my case the response header includes "x-cdn: Imperva" only when I'm off the corporate VPN. Get back on the VPN and the x-cdn falls off, and I see different values for content-length + ETag. |
I'm getting the same issue with an Azure CDN. It must be the caching as the same app works from an in-private window |
I found that this works: change the line where you reference the .js file and add a version to the url, e.g.
|
I have my simple project with Blazor. I updated the project from .NET5 to .NET6. I deploy to the production environment using
Web Deploy
. On the production server, I am getting this errorThe configuration of Web Deploy is
The text was updated successfully, but these errors were encountered: