Upload Dart symbols

If you are stripping debug symbols from your Dart code when building your Flutter apps, you will need to upload symbol files in order to see full stacktraces in BugSnag.

For installation instructions for the BugSnag CLI, please see our Installation guide.

Overview

The dart command uploads the debug symbols split off from app binaries when the --split-debug-info option is used in a Flutter build – see the Showing full stacktraces guide for more details.

For iOS, the app’s binary is also required in order to obtain a unique build identifier. The command will attempt to find the binary if your project uses the standard directory structure for a Flutter project.

Example usage

To upload symbol files, specify your BugSnag API key and the directory of the generated symbol files:

$ bugsnag-cli upload dart \
    --api-key=YOUR_API_KEY \
    app-debug-info/

You can find your API key in Project Settings from your BugSnag dashboard.

Use the --ios-app-path option to override the path for non-standard project structures:

$ bugsnag-cli upload dart \
    --api-key=YOUR_API_KEY \
    --ios-app-path=build/ios/iphoneos/MyApp/Frameworks/App.framework/App
    app-debug-info/

Available options

API key (--api-key)

Your project’s API key. Required.

You can find your API key in Project Settings from your BugSnag dashboard.

Bundle version (--app-bundle-version)

The bundle version of this build of the app. Used for display purposes of the build in the BugSnag dashboard.

App Version code (--app-version-code)

The version code of this build of the app. Used for display purposes of the build in the BugSnag dashboard.

App Version (--app-version)

The version of the app. Used for display purposes of the build in the BugSnag dashboard.

iOS app path (--ios-app-path)

The path to the iOS app binary, used to determine a unique build ID. By default, the command looks for a binary at build/ios/iphoneos/<AppName>/Frameworks/App.framework/App.

Overwrite (--overwrite)

Whether to ignore and overwrite existing uploads with same identifier. By default the command will fail if a matching file exists.

Retries (--retries)

The number of retry attempts before failing an upload. By default it is only attempted once.

Timeout (--timeout)

The number of seconds to wait before failing an upload attempt. By default the upload is given 300s (5 mins).

Upload API root URL (--upload-api-root-url)

The BugSnag On-premise upload server hostname, optionally containing port number. The command will append the appropriate path to access the correct BugSnag API upload endpoint.