dotnet / aspnetcore

ASP.NET Core is a cross-platform .NET framework for building modern cloud-based web applications on Windows, Mac, or Linux.
https://asp.net
MIT License
35.19k stars 9.93k forks source link

Blazor 0.2.0 applications fail to load in Safari on macOS/iOS #16180

Closed panesofglass closed 4 years ago

panesofglass commented 6 years ago

Environment:

Repro steps:

  1. Create a blazer stand-alone (or hosted) app from the latest templates
  2. Build with dotnet build $project
  3. Run with dotnet run --project $project

Expected:

Blazor app runs in Safari as it did for the 0.1.0 runtime and templates

Actual

Additional details:

danroth27 commented 6 years ago

@SteveSandersonMS Looks like we're still having issues with Safari.

panesofglass commented 6 years ago

I'm happy to provide any additional details you may need if I can get them.

muqeet-khan commented 6 years ago

Same issue, mobile environment.

Environment: iPhone 7s Version 11.2.6 (15D100) Blazor 0.2.0 Standalone Application published on Azure.

Repro steps: Browse https://learningblazor.azurewebsites.net from iPhone 7s

Expected: Show up properly as it does on windows desktop machine on both Chrome and edge.

Actual: Safari attempts to load and fails and stuck at "Loading ..." Google Chrome on iOS attempts to load and fails and stuck at "Loading ..."

Works just fine on Android on all browsers I tested with so I am assuming it has something to do with Mac and iOS rather than the browsers on that platform. :-(

panesofglass commented 6 years ago

Chrome and Firefox work fine for me on macOS.

danroth27 commented 6 years ago

@Kumpera This issue is being reported for macOS High Sierra. Do we potentially have Mono misconfigured in Blazor?

@muqeet-khan The issue for mobile Safari is known and is being investigated by the Mono team in conjunction with Apple.

kumpera commented 6 years ago

What version of High Sierra and Safari? I'm on Safari 11.0.3 (13604.5.6) and it works fine.

panesofglass commented 6 years ago

Safari 11.1 (13605.1.33.1.2)

kumpera commented 6 years ago

@panesofglass I can confirm is crashes with that newer version of Safari. Just updated my machine this morning and now it's crashing. 😢

kumpera commented 6 years ago

WebKit bug: https://bugs.webkit.org/show_bug.cgi?id=184829

kumpera commented 6 years ago

As it turns out, all crashes, mobile and desktop safari, share the same underlying bug.

vertonghenb commented 6 years ago

I can confirm that it's working on Safari for Mac 11.1.1 for the initial online demo, but I don't know which version of Blazor that is running.

screen shot 2018-06-16 at 23 04 17

A local version of the latest Blazor version (0.4.0) still shows the issue. Also the online flight finder example, has to same issue

screen shot 2018-06-16 at 23 13 59
SteveSandersonMS commented 6 years ago

@vertonghenb Unfortunately that doesn't confirm it, because that site is running a much older runtime that wasn't affected. A valid test would be with http://blazor-flight-finder.azurewebsites.net/, but I don't think you'll find it's fixed in 11.1.1 since the underlying issue was only addressed in Webkit sources in the last week.

vertonghenb commented 6 years ago

@SteveSandersonMS, was a bit too enthusiastic... updated the comment accordingly.

Daddoon commented 6 years ago

For this issue, rolling back to asmjs on theses specific buggy Webkit version seem to solve the problem, but of course you can feel the performance drawback at startup.

I will try to address an update on my Blazor.Polyfill project tomorrow, in order to workaround to asmjs on theses specific Safari version. Better than nothing...

Daddoon commented 6 years ago

@vertonghenb Updated my projects if you want to have a fallback to asmjs on theses specific Webkit versions.

chucker commented 6 years ago

While the release notes don't mention it, the current Safari Technology Preview no longer crashes. WebKit versions >= 606.1.23.1 appear to have the fix.

Daddoon commented 6 years ago

As a side note for this thread, nothing more is necessary if people use my last version Blazor.Polyfill , as only a range of Webkit version was checked at startup.

It should work as WebAssembly (normal behavior) at startup of Blazor app.

SteveSandersonMS commented 6 years ago

This was confirmed fixed in iOS 12.

Anyone who needs iOS 11 support should use @Daddoon's polyfill.

pheuter commented 5 years ago

Blazor apps don't appear to be working in the latest iOS 13 beta as well as macOS Catalina.

Daddoon commented 5 years ago

This repository is closed, as far as i know, and everything merged to aspnet components. By the way, wich version of Blazor have you tested ? This thread was about 0.2.0.

danroth27 commented 5 years ago

@pheuter Thanks for letting us know! We're looking into it.

pheuter commented 5 years ago

@danroth27 Awesome, thanks!

@Daddoon Gotcha, yeah figured I'd just post here since the thread seemed potentially relevant, but also aware that Blazor is now officially supported by the core asp.net team. I'm on version 3.0.0-preview5-19227-01 and using the ASP.NET Core Hosted client-side model.

chucker commented 5 years ago

@danroth27 this is probably http://www.openradar.me/50400451

I've seen this with any client-side Blazor page on Safari 13.x (the current release build Safari 12.1.1 is fine).