Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by N-Dream-AG · Oct 18, 2016 at 09:47 AM · javascriptwebglstacktrace

WebGL builds: decipher jsStackTrace errors with symbol map?

A lot of my players are getting the same error. We collect the JavaScript logs and it shows up as "abort(153) at jsStackTrace" but the since the stack trace is minified, I can't really get any information about where in the code something goes wrong from it.

I've had a look at this talk from Unite Europe 2016, where a dev explains that you can create a symbol map that can be used to decipher the stack trace. (Link goes exactly to the part where he talks about it)

He talks about having to pass an argument in order for the symbol map to be emitted, but according to this answers post, Unity 5.4 and upwards takes care of that internally.

So here comes the part that I'm struggling with:

What exactly is a symbol map and how do I use it to read the jsStackTrace error?

Unfortunately, the talk I linked to just says that you can use the map to decipher the StackTrace, but doesn't mention how, and I've been unable to find anything else on the subject.

As far as I know, I could build with Full Exception Support in order to get readable logs, but that would drastically increase file size and have an impact on performance, which is why I'd prefer to find another solution.

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
1
Best Answer

Answer by Marco-Trivellato · Oct 20, 2016 at 08:53 AM

A symbol map is a just a text file containing a list of symbols and their corresponding mangled function names from native code and scripts. Something like:

 Vb:_glClearStencil
 hVe:_Array_InternalArray__ICollection_Add_TisMark_t2724874473_m1613484179_gshared
 zLf:_mbrlen
 ZZd:_RuntimeTypeHandle_GetObjectData_m3567098501
 ...

In Unity 5.3 (or earlier version), this is not generated by default. You need to set this property to do so:

 PlayerSettings.SetPropertyString("emscriptenArgs", "--emit-symbol-map");

The symbol map is then generated in your project_folder\Temp\StagingArea\Data folder, which can be used to lookup each symbol in your callstack, either manually or ideally with a script that reads both callstack and symbol map and produces an "almost" readable callstack (function names will still be mangled but it's usually good enough).

The idea is that, for each content you publish, you keep the corresponding symbol map so that when you get a crash report from a user you can derive the unminified callstack. This can all be automated so that when a crash happens, the callstack is sent to your server that will process it and send you a bug report. This way you don't need to do anything else, but this is something you would need to setup.

  1. In 5.4+, the symbol map is generated by default.

  2. In 5.5+ this is all much easier: there is a new WebGL-specific option to generate the symbol map as .debugSymbols.jsgz file in your the Release folder, which will be hosted with the other build files (.jsgz, .datagz, etc..). Then, upon crash the symbol map will be automatically downloaded to lookup the callstack function names for you and the user will be shows a readable and unmangled callstack!

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

Can someone help me fix my Javascript for Flickering Light? 6 Answers

Unity WebGL UnityInstance.SendMessage Error: SendMessage: object Object1 does not have receiver for function moveObject 1 Answer

String coming as null from Unity to HTML WebGL 0 Answers

How to marshal a callback? 1 Answer

Unity WebGL calling a function from a jslib file in JavaScript(Vue) 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges