All Collections
Advanced usage
See Javascript stack traces by applying source maps
See Javascript stack traces by applying source maps
Jordi Giménez avatar
Written by Jordi Giménez
Updated over a week ago

When building a Javascript app, the source code sometimes undergoes a series of transformations, such as obfuscation (sometimes called "uglifying"), minification, or source-to-source compilation (transpilation). This process makes the final code less readable, so a set of source map files can optionally be generated to find the original names of functions, file names, and line numbers.

When debugging crashes with Bugfender, you can use these source maps to map the crash stack trace. In the Bugfender dashboard, you will see a Mappings: Missing message. Click on that icon to upload your source maps.

Automatically uploading source maps

The /api/upload-symbols endpoint can be used to upload source maps automatically. This can be used, for example, in your CI/CD process before releasing an application.

You can upload multiple source maps files as a ZIP file. This endpoint is available to all users (it does not require a plan with API support). The access token is in the application Settings tab.


Here are the most common problems we have found when using source maps:

  • The source maps must match the version of the code. If you use different versions, some symbols will be missing, and the file names and line numbers might not make sense.

  • If you have multiple source map files, they must be zipped and uploaded as a single file. If you upload multiple files, only the last one will be used.

  • If you're debugging a hybrid application, you must upload three files separately: the iOS dSYM files, the Android mapping file, and the Javascript sourcemap files.

  • If your hybrid application build process generates multiple source map files for each platform (iOS, Android, web platforms), you can upload multiple source maps by zipping them together. The file names are important; do not rename the files.

  • Bugfender only uses the source map files to map stack traces in crashes. If you send stack traces in logs, Bugfender will not map them.

Did this answer your question?