Git Product home page Git Product logo

bugsplat-git / bugsplat-unreal Goto Github PK

View Code? Open in Web Editor NEW
30.0 4.0 7.0 355.37 MB

βš™οΈπŸ‘ΎπŸ€― BugSplat's Unreal Engine plugin for configuring top-notch crash reporting!

Home Page: https://docs.bugsplat.com/introduction/getting-started/integrations/game-development/unreal-engine/

License: MIT License

C# 8.48% C++ 71.36% Batchfile 1.08% Shell 16.83% TypeScript 2.26%
bugsplat crash-reporting minidump ue4 ue4-plugin ue5 ue5-plugin unreal-engine hacktoberfest

bugsplat-unreal's Introduction

bugsplat-github-banner-basic-outline

BugSplat

Crash and error reporting built for busy developers.


πŸ‘‹ Introduction

BugSplat's Unreal Editor plugin makes adding crash reporting to your game a breeze! With BugSplat, you'll get a crash notification containing a full call stack with function names, line numbers, as well as many other invaluable insights into the issues tripping up your users.

Before diving into the plugin, please complete the following tasks:

  • Sign Up as a new BugSplat user
  • Complete the Welcome workflow and make a note of your BugSplat database
  • Review our MyUnrealCrasher sample application to jump-start your evaluation of BugSplat

πŸ— Installation

You may choose to add BugSplat through the Unreal Marketplace or add the plugin to your Unreal project manually.

Install from Marketplace

Install BugSplat from the Unreal Marketplace

Install Manually

  1. Navigate to your project folder containing your [ProjectName].uproject file.
  2. Create a Plugins folder if it does not already exist.
  3. Create a BugSplat folder in the Plugins folder and copy the contents of this repo into the BugSplat folder. Please note, if you're cloning this repo on macOS or Linux, you'll need to use Git LFS and git lfs fetch --all to download our symbol-upload tool.
  4. In the Unreal Editor, ensure you can access the BugSplat plugin via Edit > Project Settings and scroll to the BugSplat section under Plugins.

βš™οΈ Configuration

BugSplat's Unreal plugin currently supports adding crash reporting to Windows, macOS, Linux, Android, and iOS games. With a few clicks, the BugSplat plugin can be configured to automatically upload symbol files so crash report stack traces display function names and line numbers.

To get started, generate a Client ID and Client Secret via the Integrations page.

Next, open the BugSplat plugin menu in the Unreal Editor via Edit > Project Settings. Scroll to the BugSplat section of Project Settings and add values for Database, Application, Version, Client ID, and Client Secret:

BugSplat Unreal Plugin Settings

Windows, macOS, and Linux

BugSplat leverages Unreal's CrashReportClient to provide crash reporting for Windows, macOS, and Linux games. Be sure to update your project settings and enable Include Crash Reporter and Include Debug Files in Shipping Builds:

BugSplat Unreal Project Settings

To configure CrashReportClient to post to BugSplat, the DataRouterUrl value needs to be added to DefaultEngine.ini. The bugsplat-unreal plugin automatically updates the value for DataRouterUrl when the Update Engine DefaultEngine.ini option is enabled. Please note the DataRouterUrl value is global and is shared across all packaged builds created by the affected engine. To override the DataRouterUrl value a package build uses, you may optionally use the Update Packaged Game INI button under the Tools section.

In order to get function names and line numbers in crash reports, you'll need to upload your game's .exe, .dll, and .pdb files. To upload debug symbols for reach build, ensure that the Enable Automatic Symbol Uploads option is selected. When selected, a script to execute symbol-upload will be added to the PostBuildSteps field in BugSplat.uplugin. The symbol upload script will run automatically when your game is built.

iOS and Android

Before attempting to use the BugSplat plugin to capture crashes on Mobile, please ensure you've completed the iOS and Android quickstart guides.

In order to get function names and line numbers in your iOS crash reports, please make the following changes in the iOS section of Project Settings.

Option Value
Generate dSYMs for code debugging and profiling true
Generate dSYMs as a bundle for third-party crash tools true
Support bitcode in shipping false

To enable crash reporting, ensure the Enable iOS Crash Reporting and Enable Android Crash Reporting options are selected. Also ensure that Enable Automatic Symbol Uploads is checked so that your crash reports contain function names and line numbers.

Note that sometimes iOS applications won't crash while the USB cable is connected. If this happens, disconnect the USB cable and re-run the application to trigger a crash.

Xbox and PlayStation

BugSplat can provide instructions for implementing Unreal crash reporting on Xbox and PlayStation. Please email us at [email protected] for more info.

πŸƒ Usage

Once you've installed the plugin, add the following C++ snippet to your game to generate a sample crash.

UE_LOG(LogTemp, Fatal, TEXT("BugSplat!"));

Run your application and submit a crash report.

On Desktops, submit a crash report via the Unreal CrashReportClient dialog that appears at crash time. We have developed a handy guide on how you can customize the Unreal CrashReportClient dialog that is available here.

On iOS, after a crash occurs, restart the game and tap the Send Report option when prompted. On Android, crashes are submitted automatically at crash time.

Once you've submitted a crash report, navigate to the Crashes page. On the Crashes page, click the link in the ID column.

If everything is configured correctly, you should see something that resembles the following:

BugSplat Crash Page

πŸ§‘β€πŸ’» Contributing

BugSplat ❀️s open source! If you feel that this package can be improved, please open an Issue. If you have an awesome new feature you'd like to implement, we'd love to merge your Pull Request. You can also send us an email, join us on Discord, or message us via the in-app chat on bugsplat.com.

bugsplat-unreal's People

Contributors

bobbyg603 avatar tustanivsky avatar zoolouie avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

bugsplat-unreal's Issues

Add Copyright Info to Scripts

All plugin scripts should include copyright notice (i.e. // Copyright to BugSplat, 2022)

Per recommendation from @itustanvski

Crashes not uploaded for Android and IOS symbols not loaded for UE5.1 crashes

Hi,

I integrated version 0.2.5 of BugSplat Unreal plugin in UE5.1.
I see crashes and symbols correctly uploaded and parsed for Linux server builds. But I am not seeing the crash at all reported for Android.
For iOS I see the crash but it is not symbolicated.

All the settings are standard. I am currently testing with development builds.

I have tried global as well as Project specific configs to try to make it work.

I am seeing Android symbol upload process start as part of packaged builds but never completes. No error in the logs either.
Is Android symbol upload supported when running UE Editor on Mac?

I see IOS symbols upload successfully.

I do not see any logs for crash being sent from Android client run.

Update Documentation

Update the Readme and website screenshots and instructions now that the plugin is located in project settings.

Unable to cook - demo content has errors

I'm unable to cook my version of 4.26 with the BugSplat plugin without deleting the Content folder.

  LogAssetRegistry: Error: Package ../../../ShooterGame/Plugins/BugSplat/Content/UI/W_BugSplatButton.uasset has newer custom version of FortniteMain
  LogAssetRegistry: Error: Package ../../../ShooterGame/Plugins/BugSplat/Content/UI/W_BugSplatDemo.uasset has newer custom version of FortniteMain

I get the above error when using it. I can't just resave the assets either, they don't show up in the content browser at all - I can see the other plugin content, just not those widgets.

Fix Build Issue

Opening the my-unreal-crasher.uproject file fails and recommends building from source. This works on Windows, but prevents users from opening the project on macOS.

Android Symbol Uploads for UE5

Looks like script is waiting for ue4completeDebug, but in Unreal 5 that task is ueCompleteDebug.

if (task.name == 'ue4CompleteDebug' || task.name == 'ue4CompleteRelease') {
  ...
}

should be

if (
  task.name == 'ue4CompleteDebug' ||
  task.name == 'ue4CompleteRelease' ||
  task.name == 'ueCompleteDebug' ||
  task.name == 'ueCompleteRelease'
) {
  ...
}

Add User Feedback for Failed Game Ini File Location, Improve Logic

Currently, the user must select the WindowsNoEditor folder in their packaged game for us to correctly locate DefaultEngine.ini.

This is not specified anywhere in the UI, so we should consider:

  1. Adding this to documentation and
  2. Adding console logging feedback whenever we unsuccessfully modify the packaged game DefaultEngine.ini when the path is wrong.

Fix Docs Link

There should be a link in the docs to the Unreal Engine help page

Update Overview Text

Update text at the top to something that is more relevant now that we support both Desktop and Mobile.

image

Add Marketplace Plugin URL

Marketplace plugin URL will be required in .uplugin for publishing as well.

Per recommendation from @itustanvski

Support Application/Version Containing Spaces

We had a customer reach out because they were using spaces in their application name. Wrapping the application name param in quotes on the symbol upload script fixed the issue. The plugin should handle this.

'οΏ½@' is not recognized as an internal or external command

Hi! Please consider replace
args.Add(FPaths::Combine(FPaths::ConvertRelativePathToFull(FPaths::ProjectDir()), "Binaries"));
with
args.Add(FPaths::Combine(FPaths::ConvertRelativePathToFull(FPaths::ProjectDir()), FString("Binaries")));

Else the "Binaries" will become unknown characters in BugSplat.bat which will cause the build failed in UE4.26

Symbol Uploads Broken in Store Install

In the symbol upload script we are hardcoding the path to the project plugins directory for symbol-uploads.exe. We need to fix this path to point to the Engine plugins dir.

Bugsplat option is not available on Edit context menu

I've tried this plugin by putting the content of this repo into the Plugins/Bugsplat of my project's directory. But after running the Editor the Bugsplat menu item is not visible in the Edit context menu of the Editor.

I got the following error in my logs if that helps.

Error: Package {Project}/Plugins/BugSplat/Content/UI/W_BugSplatButton.uasset has newer custom version of FortniteMain
Error: Package {Project}/Plugins/BugSplat/Content/UI/W_BugSplatDemo.uasset has newer custom version of FortniteMain

Environment -

  • Customized version of UE 4.26.1
  • VS 2019
  • Win 10

What I've tried -
I tried to add these assets manually into the engine content folder but couldn't add. But when I tried that with UE 4.27 I could add it to the Content folder in the editor. So I opened these two blueprints using 4.27 and created duplicates of these two assets using our customized UE 4.26. And tried replacing {Project}/Plugins/BugSplat/Content/UI/W_BugSplatButton.uasset and {Project}/Plugins/BugSplat/Content/UI/W_BugSplatDemo.uasset with the newer ones I created using 4.26. But when I start the UE 4.26.1 again I get the above error.

Any clue on whats going on ?

Support for ENV Variables

From one of our favorite customers (name redacted):

Friend β€” Today at 6:51 PM
does it have the ability to set via env var ?

image

that was the biggest blocker I had
and why we don't use the plugin itself

bobbyg β€” Today at 6:54 PM
i'd imagine that is something we could figure out

Friend β€” Today at 6:54 PM
πŸ€”

bobbyg β€” Today at 6:54 PM
which values specifically needed to be env variables?

Friend β€” Today at 6:54 PM
ideally all of them pictured
clientid/secret can skip but it's NICE to have env secrets for build
then you don't need to check in secrets

bobbyg β€” Today at 6:55 PM
i buy that, we had been gitignoring that file
but i can see how that would be annoying for everyone else

Friend β€” Today at 6:55 PM
which file?
because it puts it in defaultgame I think?
can't really ignore THAT
or does it have a bugsplat specific in?

bobbyg β€” Today at 6:56 PM
well, i think since our sample doesn't change much, we checked in a default version of DefaultGame.ini without the ClientId and ClientSecret and then added it to gitignore

Friend β€” Today at 6:56 PM
ah

bobbyg β€” Today at 6:56 PM
but i can see how that would be annoying

Add Linux Support

This shouldn't be too difficult. It seems the Linux build outputs are LinuxNoEditor and Linux which is pretty similar to the Windows output!

Can't Upload Android Symbols > 2 GB

Uploading libUE4.so...
RangeError [ERR_FS_FILE_TOO_LARGE]: File size (3265634448) is greater than 2 GiB
at new NodeError (node:internal/errors:388:5)
at readFileHandle (node:internal/fs/promises:434:11)
at async AndroidDumpSymsClient.upload (C:\snapshot\android-dump-syms\dist\src\android-dump-syms-client.js)
at async C:\snapshot\android-dump-syms\dist\bin\index.js { code: 'ERR_FS_FILE_TOO_LARGE' }

Update Crashpad for Android

The current version of Crashpad for Android does not reliably post crashes. We need to update the libraries.

Add Version Support Info

In order to publish plugin at UE Marketplace .uplugin file should explicitly specify supported platforms and engine version. Note that last 3 UE versions have be supported (4.26, 4.27 and 5.0 atm).

Per recommendation from @itustanvski

Automatically Update Engine INI

This is the most common sticking point in integrating with BugSplat.

The vast majority of people using our Plugin do not care about the DataRouterUrl value in DefautlEngine.ini and likely don't care if we change it.

We hope anyone who cares will also understand why we changed it (and likely not need to use the plugin in the first place!)

Remove hardcoded paths in UE4 plugin scripts to path "<project>/Plugins/*BugSplat*"

Hello,

I noticed that the BlugSplat UE4 plugin is writing batch files into "/Plugins/BugSplat" directory. It assumes that the plugin can only be installed on this directory. Also the "Bugsplat/Scripts" folder has batch files that make this assumption, as well.

The plugin should be able to install in any directory under "Plugins". As is, it's creating artifacts in the hard coded directory mentioned.

Example: Consider that the github repo's root folder, "bugsplat-unreal", does not match the directory name the documentation say to use, "BugSplat". With UE4, It's common practice to just copy the repo of a plugin directly into "Plugins" (or even a subfolder in "Plugins")

Write DefaultEngine.ini to path based on Engine version

// TODO BG conditional for Unreal Engine <= 4.25 packaged path ([BUILD_DIR]\WindowsNoEditor\Engine\Programs\CrashReportClient\Config\NoRedist)
// TODO BG conditional for Unreal Engine >= 4.26 packaged path ([BUILD_DIR]\WindowsNoEditor\Engine\Restricted\NoRedist\Programs\CrashReportClient\Config)

For <= 4.25 ([BUILD_DIR]\WindowsNoEditor\Engine\Programs\CrashReportClient\Config\NoRedist)
For >= 4.26 ([BUILD_DIR]\WindowsNoEditor\Engine\Restricted\NoRedist\Programs\CrashReportClient\Config)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.