Greetings, I'm trying to get clear stack traces from our webGL/WASM client. We need those in both debug and release builds. I have not been able to find any documentation on how to use the debug symbols. WebGLBuild.wasm.symbols.unityweb is output with the client if I build with debug symbols. As far as I've understood those are supposed to be used automatically by the client. It does not give me readable logs in the browser, though. How is this supposed to work? How do I use this feature? I've also looked at: Temp\StagingArea\Data\linkresult_wasm\build.js.symbols and Temp\StagingArea\Data\il2cppOutput\Symbols\MethodMap.tsv Those could be used to translate the browser log into a human readable call stack. Is this a better way to go? - Carl, KoGaMa/Multiverse
Hi Carl, if the Debug Symbols options is enabled, the UnityLoader will download the symbols file and demangle the callstack which is then printed in the console. To see how it's done you can check the un-minified UnilyLoader.js code in the Unity installation folder. Does that help?
Thanks. It does help a lot in terms of deciding where to focus my investigation. My logs still look like: Some message at wasm-function[22395]:95 ... I will look into the loader as suggested.
I think this is because there was a change in the Wasm names section format: From Unity 5.6 to 2018.1, you should use Firefox 54 or older. As of Unity 2018.2, you should use Firefox 55 or newer.
I can confirm with great sadness that my trusty 54.0.1 Firefox installation is now useless with Unity 2018.2. The latest version of Firefox (61.0.1) seems to work with 2018.2 and debug symbols in wasm!
Setup: Unity 2018.2. Logging set to full. Exception support set to full with stack trace. Debug symbols generated. Result: Stack traces from logs are not translated. They still refer to numbered wasm functions. Exceptions are translated properly. As far as I know, this isn't dependent on the debug symbols, though. Test results are consistent between Firefox 61.0.1 and Chrome 67.0.3396.99. Considering what you've said I will go with the assumption that this is a project specific issue. I'll try to update the thread if I find the problem/solution.
Development builds does indeed translate the the logs. This without outputting any debug symbols, even though debug symbols are checked. Development builds also have other side effects, which are highly undesirable for live releases. Not a viable solution for our case.
We make two binaries of every "build" we release. One "normal binary" (no exceptions, no symbols, limited logging) and one "debug binary" (development build, full exceptions, symbols, full logging). We obviously serve the normal binary to our users and if there's ever an error/exception we then load up the debug binary and attempt to reproduce the error. Works out in practice for us.
Hi, So just wondering: Is it possible to do a non dev wasm build and get reasonable stack traces from for instance Chrome or Firefox in this point in time?
I am experiencing the same issue as described here... I posted a detailed explanation here - https://forum.unity.com/threads/get-symbol-maps-to-work.979944/. Would you be so kind to help sort this out please?
Hello @Marco-Trivellato In your response "Hi Carl, if the Debug Symbols options is enabled, the UnityLoader will download the symbols file and demangle the callstack which is then printed in the console. To see how it's done you can check the un-minified UnilyLoader.js code in the Unity installation folder. Does that help?" That cleared some stuff up for my silimar problem. But do we need to "create" or upload the debug symbols anywhere? How are they created? I cannot find it anywhere in the documentation
Enable the 'Debug Symbols' in the player settings for WebGL. This creates a debug symbols file which is just a key value file. I created a simple lookup code using PHP to convert the key into the method name. Check this post for some more details - https://forum.unity.com/threads/get-symbol-maps-to-work.979944/