Skip to content

Comments

chore: Utilize app-runner for Android#2548

Open
bitsandfoxes wants to merge 31 commits intomainfrom
feat/app-runner-android
Open

chore: Utilize app-runner for Android#2548
bitsandfoxes wants to merge 31 commits intomainfrom
feat/app-runner-android

Conversation

@bitsandfoxes
Copy link
Contributor

#skip-changelog

@github-actions
Copy link
Contributor

github-actions bot commented Feb 13, 2026

Semver Impact of This PR

🟢 Patch (bug fixes)

📋 Changelog Preview

This is how your changes will appear in the changelog.
Entries from this PR are highlighted with a left border (blockquote style).


This PR will not appear in the changelog.


🤖 This preview updates automatically when you update the PR.

Comment on lines +274 to +275
# api-level: [30, 31, 34]
api-level: [30]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll check and update the API levels in a followup.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need a tiny bump on the .NET SDK here that hardcodes isAOT = false to fix some false positives on older Unity versions.

PlayerSettings.SetIl2CppCodeGeneration(NamedBuildTarget.FromBuildTargetGroup(group), UnityEditor.Build.Il2CppCodeGeneration.OptimizeSpeed);
#elif UNITY_2021_2_OR_NEWER
EditorUserBuildSettings.il2CppCodeGeneration = UnityEditor.Build.Il2CppCodeGeneration.OptimizeSize;
EditorUserBuildSettings.il2CppCodeGeneration = UnityEditor.Build.Il2CppCodeGeneration.OptimizeSpeed;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A more likely setting for actual release builds.

Comment on lines -129 to -131
#if !UNITY_EDITOR
t.ExpectMessage(currentMessage, "'op':'awake','description':'Main Camera.SmokeTester'"); // auto instrumentation
#endif
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The current change from having a TestLauncher instead of having the MonoBehaviour already available during scene load makes this unfeasible. We can add this back in after the migration.

@bitsandfoxes bitsandfoxes requested a review from a team February 20, 2026 13:28
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

// Wait for the crash report to be sent
yield return new WaitForSeconds(10);

SentrySdk.FlushAsync(TimeSpan.FromSeconds(5)).GetAwaiter().GetResult();
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Blocking FlushAsync on main thread risks deadlock

Medium Severity

SentrySdk.FlushAsync(TimeSpan.FromSeconds(5)).GetAwaiter().GetResult() blocks Unity's main thread inside a coroutine. If the Sentry Unity SDK uses UnityWebRequestTransport (which processes HTTP via main-thread coroutines), blocking the main thread prevents those requests from completing, creating a deadlock. The 5-second timeout also can't fire because Unity's update loop is frozen. A coroutine-friendly approach (polling task.IsCompleted with yield return null) would allow the main thread to keep pumping while waiting for flush completion.

Fix in Cursor Fix in Web

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant