Skip to content
This repository has been archived by the owner on Jul 22, 2024. It is now read-only.

Fixes #3643 Telemetry crash fix #3644

Merged
merged 1 commit into from
Jul 7, 2020
Merged

Fixes #3643 Telemetry crash fix #3644

merged 1 commit into from
Jul 7, 2020

Conversation

keianhzo
Copy link
Contributor

@keianhzo keianhzo commented Jul 7, 2020

Fixes #3643 The Telemetry service needs to get initialized in the Application onCreate as the service can be called when the app is not running and that only calls the Application onCreate, otherwise this crash happens.

I had to add a custom TestApplication for testing as the Unit testing initialization doesn't seems to provide a different process for the crash service as defined in the manifest and the GeckoRuntime crashes with:
java.lang.IllegalArgumentException: Crash handler service must run in a separate process

Also for some reason the Application onCreate is called from a different process the first time the app is launched and the GeckoRuntime is not correctly initialized and we don't get any content paints. I've added the same check as Fenix does to make sure we are running in the main process or just return otherwise.

@keianhzo keianhzo self-assigned this Jul 7, 2020
@keianhzo keianhzo requested review from bluemarvin and daoshengmu July 7, 2020 13:57
@keianhzo keianhzo force-pushed the v12/telemetry_crash_fix branch from 1619e26 to 924a304 Compare July 7, 2020 13:58
@keianhzo keianhzo added the Uplift PR that needs to be uplifted. label Jul 7, 2020
@keianhzo keianhzo force-pushed the v12/telemetry_crash_fix branch from 924a304 to 3ccae40 Compare July 7, 2020 14:29
Copy link
Contributor

@daoshengmu daoshengmu left a comment

Choose a reason for hiding this comment

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

R+ for the telemetry part.

Comment on lines +55 to +56
TelemetryWrapper.init(this, EngineProvider.INSTANCE.getDefaultClient(this));
GleanMetricsService.init(this, EngineProvider.INSTANCE.getDefaultClient(this));
Copy link
Contributor

Choose a reason for hiding this comment

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

It's unfortunate glean requires this.

@bluemarvin bluemarvin merged commit 7c7ce5d into main Jul 7, 2020
@bluemarvin bluemarvin deleted the v12/telemetry_crash_fix branch July 7, 2020 18:01
@bluemarvin bluemarvin removed the Uplift PR that needs to be uplifted. label Jul 7, 2020
bluemarvin pushed a commit that referenced this pull request Jul 7, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Oculus Quest] The app keeps crashing in the background after the latest Oculus update
3 participants