Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Chrome 42 Issue?

Discussion in 'WebGL' started by levwsr, Oct 26, 2015.

  1. levwsr

    levwsr

    Joined:
    Jul 23, 2012
    Posts:
    68
    We are seeing an abnormally high number of users stuck in webgl at "Downloading (0.0/1)" status in our metrics. More or less, they didnt get anywhere into the install process.

    Is there any known issue that might prevent install for these users?

    Thanks
     
  2. Marco-Trivellato

    Marco-Trivellato

    Unity Technologies

    Joined:
    Jul 9, 2013
    Posts:
    1,654
    No known issue. Any info about which browser/OS ? which version of Unity ?

    A log from the browser would be useful too.
     
  3. levwsr

    levwsr

    Joined:
    Jul 23, 2012
    Posts:
    68
    Lol.. the title is "Chrome 42 issue" - thats the browser. OS is windows. Unity version is webgl built with 5.2.6.

    The last thing in the browser log is "Downloading (0.0/1)" as far as we can tell.

    Have you done any testing with ad blockers? They are becoming more common in the wild, and there are a lot of flavors out there.
     
  4. support

    support

    Joined:
    Oct 24, 2013
    Posts:
    19
    "Downloading (0.0/1)" is printed by index.html . All other progress statuses are printed by UnityLoader after main game js file is loaded, processed and executed. In most cases, the problems happen there.
    You can customize error handler in the Release/UnityConfig.js (generated by Unity) to see a little bit more. Add console.log before alerts. In our case, the most popular are "Out of memory...." and "Invalid array buffer length", It is about 20% of all failed cases. 80% are peacefully dead between phases "loading" and "start to execute".
     
    levwsr likes this.
  5. sirrus

    sirrus

    Joined:
    Jun 10, 2012
    Posts:
    250
    If you can get a console log from a test case, does it produce this error?

    "Uncaught RangeError: Invalid typed array length"

    We are experiencing similar issues with Chrome (v46) and I believe it may have to do with errors that are not properly caught by the error handling provided by Unity (or even our own custom JS error handling). We get this specific error if we jack up the TOTAL_MEMORY value to something very large to mimick an out-of-memory error.

    It seems that this error simply is not caught via window.onerror when the main js script is loaded via the .src attribute. We are looking into other ways to accommodate this.

    Any thoughts?
     
  6. sirrus

    sirrus

    Joined:
    Jun 10, 2012
    Posts:
    250
    FYI, Chrome not catching the error is due to a bug referenced here:

    https://code.google.com/p/chromium/issues/detail?id=225513#c25

    If the main game JS file included an onerror handler, it would be caught properly. Any way this can be part of a template or referenced externally?

    For example, unity_built_game.js includes a window.onerror function that just calls UnityErrorHandler(...) which is already part of UnityConfig.js.