Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,22 +12,26 @@ env:
jobs:
build:
name: Build
runs-on: windows-latest
runs-on: windows-2022

steps:
- name: Log in to GitHub package registry
uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
password: ${{ secrets.PAT_TOKEN }}

- name: Start Docker container
run: |
docker run -td `
--name unreal `
--volume "${{ github.workspace }}:C:\workspace" `
--workdir C:\workspace `
--env SENTRY_DSN="${{ secrets.SENTRY_DSN }}" `
--env SENTRY_ORG="${{ secrets.SENTRY_ORG }}" `
--env SENTRY_PROJECT="${{ secrets.SENTRY_PROJECT }}" `
--env SENTRY_AUTH_TOKEN="${{ secrets.SENTRY_AUTH_TOKEN }}" `
ghcr.io/getsentry/unreal-docker:${{ env.UE_VERSION }}

- uses: actions/checkout@v4
Expand All @@ -54,4 +58,4 @@ jobs:
with:
name: SentryTower
path: checkout/Builds/Windows/
retention-days: 90
retention-days: 90
6 changes: 4 additions & 2 deletions .github/workflows/run-demo.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
name: run-demo

on:
# schedule:
# - cron: '0 */2 * * *' # every two hours
schedule:
- cron: '*/50 * * * *' # every 50 minutes
workflow_dispatch:

jobs:
Expand All @@ -28,6 +28,8 @@ jobs:
run-id: ${{ steps.get-run.outputs.run-id }}

- name: Run Simulation
env:
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
run: |
$downloadPath = "${{ steps.download.outputs.download-path }}"
Write-Output "Download path: $downloadPath"
Expand Down
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@

# Compiled Dynamic libraries
*.so
*.dylib
*.dll

# Fortran module files
Expand Down
1 change: 0 additions & 1 deletion .ignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,3 @@
/Plugins/Sentry/Gradle
/Plugins/Sentry/Scripts
/Plugins/Sentry/Intermediate
/*.code-workspace
7 changes: 6 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,4 +74,9 @@ All captured crash events should have the following attachments:

## Self-playing mode

Launch the game with the `--idle` parameter to enable self-play mode (useful for running tests in a CI environment). In this mode, user input is not required. The game automatically responds to certain events (e.g., level-up, game over) by randomly selecting from a set of predefined actions.
Launch the game with the `--idle` parameter to enable self-play mode (useful for running tests in a CI environment). In this mode, user input is not required. The game automatically responds to certain events (e.g., level-up, game over) by randomly selecting from a set of predefined actions.

## Console Controls

- To open the in-game shop, press the Y button on Xbox or the △ (triangle) button on PS5
- To open the game menu, press the B button on Xbox or the ○ (circle) button on PS5
3 changes: 2 additions & 1 deletion Config/DefaultEngine.ini
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,7 @@ KeyPassword=android
+CollisionChannelRedirects=(OldName="PawnMovement",NewName="Pawn")

[/Script/Sentry.SentrySettings]
InitAutomatically=True
EnableAutoLogAttachment=True
SendDefaultPii=True
AttachScreenshot=True
Expand All @@ -293,7 +294,7 @@ IncludeSources=True
AutomaticBreadcrumbsForLogs=(bOnFatalLog=True,bOnErrorLog=False,bOnWarningLog=False,bOnInfoLog=False,bOnDebugLog=False)
EnableTracing=True
TracesSampleRate=1.000000
Dsn="https://f1818b87d128882c28e8a876858d2d1e@o447951.ingest.us.sentry.io/4508816831873030"
EnableStructuredLogging=True

[/Script/MacTargetPlatform.MacTargetSettings]
-TargetedRHIs=SF_METAL_SM5
Expand Down
Binary file added Content/Blueprints/BP_Utils.uasset
Binary file not shown.
Binary file modified Content/Maps/Menu.umap
Binary file not shown.
Binary file modified Content/UI/W_GameOver.uasset
Binary file not shown.
Binary file modified Content/UI/W_GameShop.uasset
Binary file not shown.
Binary file modified Content/UI/W_HUD.uasset
Binary file not shown.
Binary file modified Content/UI/W_InGameMenu.uasset
Binary file not shown.
Binary file modified Content/UI/W_LevelUp.uasset
Binary file not shown.
Binary file modified Content/UI/W_MainMenu.uasset
Binary file not shown.
Binary file modified Content/UI/W_MenuButtons.uasset
Binary file not shown.
152 changes: 152 additions & 0 deletions Plugins/Sentry/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,157 @@
# Changelog

### Features

- Implement structured logging for Unreal (all platforms) ([#1091](https://github.com/getsentry/sentry-unreal/pull/1091))

### Fixes

- Prevent usage of internal UE logger during crash handling ([#1081](https://github.com/getsentry/sentry-unreal/pull/1081))
- Crash when printing to logs from multiple threads on Android ([#1092](https://github.com/getsentry/sentry-unreal/pull/1092))

### Dependencies

- Bump Android Gradle Plugin from v5.10.0 to v5.12.0 ([#1078](https://github.com/getsentry/sentry-unreal/pull/1078), [#1086](https://github.com/getsentry/sentry-unreal/pull/1086))
- [changelog](https://github.com/getsentry/sentry-android-gradle-plugin/blob/main/CHANGELOG.md#5120)
- [diff](https://github.com/getsentry/sentry-android-gradle-plugin/compare/5.10.0...5.12.0)
- Bump Cocoa SDK (iOS and Mac) from v8.55.1 to v8.56.2 ([#1077](https://github.com/getsentry/sentry-unreal/pull/1077), [#1093](https://github.com/getsentry/sentry-unreal/pull/1093))
- [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8562)
- [diff](https://github.com/getsentry/sentry-cocoa/compare/8.55.1...8.56.2)
- Bump Native SDK from v0.10.1 to v0.11.1 ([#1080](https://github.com/getsentry/sentry-unreal/pull/1080), [#1088](https://github.com/getsentry/sentry-unreal/pull/1088))
- [changelog](https://github.com/getsentry/sentry-native/blob/master/CHANGELOG.md#0111)
- [diff](https://github.com/getsentry/sentry-native/compare/0.10.1...0.11.1)
- Bump CLI from v2.53.0 to v2.55.0 ([#1079](https://github.com/getsentry/sentry-unreal/pull/1079), [#1085](https://github.com/getsentry/sentry-unreal/pull/1085))
- [changelog](https://github.com/getsentry/sentry-cli/blob/master/CHANGELOG.md#2550)
- [diff](https://github.com/getsentry/sentry-cli/compare/2.53.0...2.55.0)
- Bump Java SDK (Android) from v8.21.1 to v8.22.0 ([#1083](https://github.com/getsentry/sentry-unreal/pull/1083))
- [changelog](https://github.com/getsentry/sentry-java/blob/main/CHANGELOG.md#8220)
- [diff](https://github.com/getsentry/sentry-java/compare/8.21.1...8.22.0)

## 1.2.0-beta.1

### Various fixes & improvements

- feat: Implement structured logging for Unreal (all platforms) (#1091) by @mujacica
- chore(deps): update Cocoa SDK (iOS and Mac) to v8.56.2 (#1093) by @github-actions
- Fix Android crash when logging from multiple threads (#1092) by @tustanivsky
- chore: update plugin-dev/sentry-cli.properties to 2.55.0 (#1085) by @github-actions
- chore: update scripts/update-android-gradle-plugin.sh to 5.12.0 (#1086) by @github-actions
- chore: update modules/sentry-native to 0.11.1 (#1088) by @github-actions
- Removed the text "Warning" for Win64 when symbol upload file is missing to match messaging above. (#1084) by @RiotRampRoy
- chore: update modules/sentry-java to 8.22.0 (#1083) by @github-actions
- fix: Prevent usage of internal UE logger during crash handling (#1081) by @mujacica
- chore(deps): update Native SDK to v0.11.0 (#1080) by @github-actions
- chore: update plugin-dev/sentry-cli.properties to 2.54.0 (#1079) by @github-actions
- chore(deps): update Cocoa SDK (iOS and Mac) to v8.56.0 (#1077) by @github-actions
- chore: update scripts/update-android-gradle-plugin.sh to 5.11.0 (#1078) by @github-actions

## 1.1.1

### Features

- Add support for automatic event linking with spans/transactions ([#1075](https://github.com/getsentry/sentry-unreal/pull/1075))

### Dependencies

- Bump Cocoa SDK (iOS and Mac) from v8.55.0 to v8.55.1 ([#1068](https://github.com/getsentry/sentry-unreal/pull/1068))
- [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8551)
- [diff](https://github.com/getsentry/sentry-cocoa/compare/8.55.0...8.55.1)
- Bump Java SDK (Android) from v8.20.0 to v8.21.1 ([#1070](https://github.com/getsentry/sentry-unreal/pull/1070), [#1074](https://github.com/getsentry/sentry-unreal/pull/1074))
- [changelog](https://github.com/getsentry/sentry-java/blob/main/CHANGELOG.md#8211)
- [diff](https://github.com/getsentry/sentry-java/compare/8.20.0...8.21.1)
- Bump Android Gradle Plugin from v5.9.0 to v5.10.0 ([#1072](https://github.com/getsentry/sentry-unreal/pull/1072))
- [changelog](https://github.com/getsentry/sentry-android-gradle-plugin/blob/main/CHANGELOG.md#5100)
- [diff](https://github.com/getsentry/sentry-android-gradle-plugin/compare/5.9.0...5.10.0)

## 1.1.0

### Features

- Add GPU and device contexts for all platforms if valid ([#1067](https://github.com/getsentry/sentry-unreal/pull/1067))

### Fixes

- Packaging errors in Unreal Engine 5.4 and 5.5 caused by a missing `SWIFT_PACKAGE` define when targeting Mac and iOS ([#1063](https://github.com/getsentry/sentry-unreal/pull/1063))
- Crash when attaching game log file to captured event on Android ([#1066](https://github.com/getsentry/sentry-unreal/pull/1066))

### Dependencies

- Bump CLI from v2.52.0 to v2.53.0 ([#1062](https://github.com/getsentry/sentry-unreal/pull/1062))
- [changelog](https://github.com/getsentry/sentry-cli/blob/master/CHANGELOG.md#2530)
- [diff](https://github.com/getsentry/sentry-cli/compare/2.52.0...2.53.0)
- Bump Native SDK from v0.10.0 to v0.10.1 ([#1065](https://github.com/getsentry/sentry-unreal/pull/1065))
- [changelog](https://github.com/getsentry/sentry-native/blob/master/CHANGELOG.md#0101)
- [diff](https://github.com/getsentry/sentry-native/compare/0.10.0...0.10.1)

## 1.0.0

After several months of work we're finally shipping the Sentry SDK for Unreal Engine version 1.0.0.
If you are upgrading from a version `0.x`, **please refer to the [migration guide on our docs](https://docs.sentry.io/platforms/unreal/migration/)**.

This release also includes compatibility with plugin extensions for [PlayStation](https://docs.sentry.io/platforms/playstation/), [Xbox](https://docs.sentry.io/platforms/xbox/) and [Nintendo Switch](https://docs.sentry.io/platforms/nintendo-switch/).
Access to the source code of these console extensions require components that exist in private GitHub repositories. Invites are sent to licensed developers after a middleware verification. Please [follow the steps on our docs](https://docs.sentry.io/platforms/unreal/game-consoles/).

Note that [the diff from the latest experimental release 0.22.0 and this 1.0.0](https://github.com/getsentry/sentry-unreal/compare/0.22.0...1.0.0) release include several alpha and beta releases.
We have not combined all of them in this header but instead, left each incremental change in their own version below.

If you're migrating from 0.22.0 and want to read through all the changes, we recommend starting from [## 1.0.0-alpha.1](#100-alpha1) below.

In case you encounter any issues, please [create a ticket on our GitHub repository](https://github.com/getsentry/sentry-unreal/issues/new/choose).

### Breaking Changes

- User feedback API reworked:
- Feedback no longer needs to be associated with a specific event - the only required parameter is the user message
- `SentryUserFeedback` class replaced with `SentryFeedback`
- `CaptureUserFeedback` function in `SentrySubsystem` replaced with `CaptureFeedback`
- `CreateSentryUserFeedback` function in `SentryLibrary` replaced with `CreateSentryFeedback`
- On Windows and Linux, `ToString` function of `SentryId` class now returns the ID without dashes
- `StartTransactionWithContextAndOptions` function in `SentrySubsystem` now accepts `FSentryTransactionOptions` struct instead of string map
- `GetCustomSamplingContext` function in `SentrySamplingContext` now returns `TMap<FString, FSentryVariant>` instead of string map

### Features

- Add functionality to give/revoke user consent for crash uploads ([#1053](https://github.com/getsentry/sentry-unreal/pull/1053))
- Add new API for capturing user feedback ([#1051](https://github.com/getsentry/sentry-unreal/pull/1051))
- Add Traces sampling function support for Windows and Linux ([#1057](https://github.com/getsentry/sentry-unreal/pull/1057))
- Read `DSN`, `Environment` and `Release` options from environment variables ([#1054](https://github.com/getsentry/sentry-unreal/pull/1054))

### Dependencies

- Bump CLI from v2.51.1 to v2.52.0 ([#1049](https://github.com/getsentry/sentry-unreal/pull/1049))
- [changelog](https://github.com/getsentry/sentry-cli/blob/master/CHANGELOG.md#2520)
- [diff](https://github.com/getsentry/sentry-cli/compare/2.51.1...2.52.0)
- Bump Cocoa SDK (iOS and Mac) from v8.54.0 to v8.55.0 ([#1050](https://github.com/getsentry/sentry-unreal/pull/1050))
- [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8550)
- [diff](https://github.com/getsentry/sentry-cocoa/compare/8.54.0...8.55.0)
- Bump Java SDK (Android) from v8.19.1 to v8.20.0 ([#1056](https://github.com/getsentry/sentry-unreal/pull/1056))
- [changelog](https://github.com/getsentry/sentry-java/blob/main/CHANGELOG.md#8200)
- [diff](https://github.com/getsentry/sentry-java/compare/8.19.1...8.20.0)

## 1.0.0-beta.8

### Fixes

- No more build warnings in platform extensions caused by deprecated Native SDK API usages

### Dependencies

- Bump Java SDK (Android) from v8.17.0 to v8.19.1 ([#1031](https://github.com/getsentry/sentry-unreal/pull/1031), [#1042](https://github.com/getsentry/sentry-unreal/pull/1042), [#1046](https://github.com/getsentry/sentry-unreal/pull/1046))
- [changelog](https://github.com/getsentry/sentry-java/blob/main/CHANGELOG.md#8191)
- [diff](https://github.com/getsentry/sentry-java/compare/8.17.0...8.19.1)
- Bump Cocoa SDK (iOS and Mac) from v8.53.2 to v8.54.0 ([#1032](https://github.com/getsentry/sentry-unreal/pull/1032))
- [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8540)
- [diff](https://github.com/getsentry/sentry-cocoa/compare/8.53.2...8.54.0)
- Bump CLI from v2.50.2 to v2.51.1 ([#1037](https://github.com/getsentry/sentry-unreal/pull/1037), [#1041](https://github.com/getsentry/sentry-unreal/pull/1041))
- [changelog](https://github.com/getsentry/sentry-cli/blob/master/CHANGELOG.md#2511)
- [diff](https://github.com/getsentry/sentry-cli/compare/2.50.2...2.51.1)
- Bump Android Gradle Plugin from v5.8.0 to v5.9.0 ([#1036](https://github.com/getsentry/sentry-unreal/pull/1036), [#1045](https://github.com/getsentry/sentry-unreal/pull/1045))
- [changelog](https://github.com/getsentry/sentry-android-gradle-plugin/blob/main/CHANGELOG.md#590)
- [diff](https://github.com/getsentry/sentry-android-gradle-plugin/compare/5.8.0...5.9.0)
- Bump Native SDK from v0.9.1 to v0.10.0 ([#1040](https://github.com/getsentry/sentry-unreal/pull/1040))
- [changelog](https://github.com/getsentry/sentry-native/blob/master/CHANGELOG.md#0100)
- [diff](https://github.com/getsentry/sentry-native/compare/0.9.1...0.10.0)

## 1.0.0-beta.7

### Fixes
Expand Down
5 changes: 3 additions & 2 deletions Plugins/Sentry/Sentry.uplugin
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
{
"EngineVersion" : "5.6.0",
"FileVersion": 3,
"Version": 1,
"VersionName": "1.0.0-beta.7",
"VersionName": "1.2.0-beta.1",
"FriendlyName": "Sentry",
"Description": "Sentry catches all your errors and performance issues, and shows you how to fix them before they bring down the player experience.",
"Category": "Code Plugins",
Expand Down Expand Up @@ -51,7 +52,7 @@
"set \"CRASHPAD_HANDLER_WIN=$(PluginDir)/Binaries/Win64/crashpad_handler.exe\"",
"if \"$(TargetPlatform)\"==\"Win64\" (\n if not exist \"%CRASHPAD_HANDLER_WIN%\" (xcopy \"$(PluginDir)/Source/ThirdParty/Win64/Crashpad/bin/*\" \"$(PluginDir)/Binaries/Win64/\" /F /R /Y /I)\n)",
"set \"SYM_UPLOAD_SCRIPT=$(PluginDir)/Scripts/upload-debug-symbols-win.bat\"",
"if exist \"%SYM_UPLOAD_SCRIPT%\" (call \"%SYM_UPLOAD_SCRIPT%\" $(TargetPlatform) $(TargetName) $(TargetType) $(TargetConfiguration) \"$(ProjectDir)\" \"$(PluginDir)\") else (\necho Warning: Sentry: Symbol upload script is missing. Skipping post build step.\n)",
"if exist \"%SYM_UPLOAD_SCRIPT%\" (call \"%SYM_UPLOAD_SCRIPT%\" $(TargetPlatform) $(TargetName) $(TargetType) $(TargetConfiguration) \"$(ProjectDir)\" \"$(PluginDir)\") else (\necho Sentry: Symbol upload script is missing. Skipping post build step.\n)",
"endlocal"
]
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
// Copyright (c) 2025 Sentry. All Rights Reserved.

#include "AndroidSentryFeedback.h"

#include "AndroidSentryId.h"

#include "Infrastructure/AndroidSentryJavaClasses.h"

FAndroidSentryFeedback::FAndroidSentryFeedback(const FString& message)
: FSentryJavaObjectWrapper(SentryJavaClasses::Feedback, "(Ljava/lang/String;)V",
*GetJString(message))
{
SetupClassMethods();
}

void FAndroidSentryFeedback::SetupClassMethods()
{
GetMessageMethod = GetMethod("getMessage", "()Ljava/lang/String;");
SetNameMethod = GetMethod("setName", "(Ljava/lang/String;)V");
GetNameMethod = GetMethod("getName", "()Ljava/lang/String;");
SetContactEmailMethod = GetMethod("setContactEmail", "(Ljava/lang/String;)V");
GetContactEmailMethod = GetMethod("getContactEmail", "()Ljava/lang/String;");
SetAssociatedEventMethod = GetMethod("setAssociatedEventId", "(Lio/sentry/protocol/SentryId;)V");
GetAssociatedEventMethod = GetMethod("getAssociatedEventId", "()Lio/sentry/protocol/SentryId;");
}

FString FAndroidSentryFeedback::GetMessage() const
{
return CallMethod<FString>(GetMessageMethod);
}

void FAndroidSentryFeedback::SetName(const FString& name)
{
CallMethod<void>(SetNameMethod, *GetJString(name));
}

FString FAndroidSentryFeedback::GetName() const
{
return CallMethod<FString>(GetNameMethod);
}

void FAndroidSentryFeedback::SetContactEmail(const FString& email)
{
CallMethod<void>(SetContactEmailMethod, *GetJString(email));
}

FString FAndroidSentryFeedback::GetContactEmail() const
{
return CallMethod<FString>(GetContactEmailMethod);
}

void FAndroidSentryFeedback::SetAssociatedEvent(const FString& eventId)
{
if (eventId.IsEmpty())
return;

TSharedPtr<FAndroidSentryId> idAndroid = MakeShareable(new FAndroidSentryId(eventId));
CallMethod<void>(SetAssociatedEventMethod, idAndroid->GetJObject());
}

FString FAndroidSentryFeedback::GetAssociatedEvent() const
{
auto idAndroid = CallObjectMethod<jobject>(GetAssociatedEventMethod);
if (!idAndroid)
{
return FString();
}

TSharedPtr<FAndroidSentryId> eventId = MakeShareable(new FAndroidSentryId(*idAndroid));
return eventId->ToString();
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
// Copyright (c) 2025 Sentry. All Rights Reserved.

#pragma once

#include "Interface/SentryFeedbackInterface.h"

#include "Infrastructure/AndroidSentryJavaObjectWrapper.h"

class ISentryId;

class FAndroidSentryFeedback : public ISentryFeedback, public FSentryJavaObjectWrapper
{
public:
FAndroidSentryFeedback(const FString& message);

void SetupClassMethods();

virtual FString GetMessage() const override;
virtual void SetName(const FString& name) override;
virtual FString GetName() const override;
virtual void SetContactEmail(const FString& email) override;
virtual FString GetContactEmail() const override;
virtual void SetAssociatedEvent(const FString& eventId) override;
virtual FString GetAssociatedEvent() const override;

private:
FSentryJavaMethod GetMessageMethod;
FSentryJavaMethod SetNameMethod;
FSentryJavaMethod GetNameMethod;
FSentryJavaMethod SetContactEmailMethod;
FSentryJavaMethod GetContactEmailMethod;
FSentryJavaMethod SetAssociatedEventMethod;
FSentryJavaMethod GetAssociatedEventMethod;
};

typedef FAndroidSentryFeedback FPlatformSentryFeedback;
Loading