Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Remove reportDrawnWhen api due to crash on Android 9 #2530

Merged
merged 1 commit into from
Dec 15, 2023

Conversation

ohassine
Copy link
Member


PR Submission Checklist for internal contributors

  • The PR Title

    • conforms to the style of semantic commits messages¹ supported in Wire's Github Workflow²
    • contains a reference JIRA issue number like SQPIT-764
    • answers the question: If merged, this PR will: ... ³
  • The PR Description

    • is free of optional paragraphs and you have filled the relevant parts to the best of your ability

What's new in this PR?

Issues

ReportDrawnWhen which used to improve app startup is causing some crashes on Samsung devices running on Android 9

Exception java.lang.SecurityException: Permission Denial: broadcast from android asks to run as user -1 but is calling from user 0; this requires android.permission.INTERACT_ACROSS_USERS_FULL or android.permission.INTERACT_ACROSS_USERS
  at android.os.Parcel.createException (Parcel.java:1966)
  at android.os.Parcel.readException (Parcel.java:1934)
  at android.os.Parcel.readException (Parcel.java:1884)
  at android.app.IActivityManager$Stub$Proxy.reportActivityFullyDrawn (IActivityManager.java:7301)
  at android.app.Activity.reportFullyDrawn (Activity.java:2087)
  at androidx.activity.ComponentActivity.reportFullyDrawn (ComponentActivity.java)
  at androidx.activity.ComponentActivity.lambda$new$0 (ComponentActivity.java)
  at android.view.Choreographer$CallbackRecord.run (Choreographer.java:988)
  at android.view.Choreographer.doCallbacks (Choreographer.java:765)
  at android.view.Choreographer.doFrame (Choreographer.java:697)
  at android.view.Choreographer$FrameDisplayEventReceiver.run (Choreographer.java:971)
  at android.os.Handler.handleCallback (Handler.java:873)
  at android.os.Handler.dispatchMessage (Handler.java:99)
  at android.os.Looper.loop (Looper.java:216)
  at android.app.ActivityThread.main (ActivityThread.java:7266)
  at java.lang.reflect.Method.invoke
  at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:494)
  at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:975)
Caused by android.os.RemoteException: Remote stack trace:
  at com.android.server.am.UserController.handleIncomingUser (UserController.java:1832)
  at com.android.server.am.ActivityManagerService.broadcastIntentLocked (ActivityManagerService.java:26232)
  at com.android.server.am.ActivityManagerService.broadcastIntentLocked (ActivityManagerService.java:26163)
  at com.android.server.am.ActivityManagerService.broadcastIntent (ActivityManagerService.java:27033)
  at android.app.ContextImpl.sendBroadcastAsUser (ContextImpl.java:1264)

There is ticket created on issueTracker, it's still in progress : https://issuetracker.google.com/issues/316294709.

For now we are just going to remove it.

Needs releases with:

  • GitHub link to other pull request

Testing

Test Coverage (Optional)

  • I have added automated test to this contribution

How to Test

Briefly describe how this change was tested and if applicable the exact steps taken to verify that it works as expected.

Notes (Optional)

Specify here any other facts that you think are important for this issue.

Attachments (Optional)

Attachments like images, videos, etc. (drag and drop in the text box)


PR Post Submission Checklist for internal contributors (Optional)

  • Wire's Github Workflow has automatically linked the PR to a JIRA issue

PR Post Merge Checklist for internal contributors

  • If any soft of configuration variable was introduced by this PR, it has been added to the relevant documents and the CI jobs have been updated.

References
  1. https://sparkbox.com/foundry/semantic_commit_messages
  2. https://github.com/wireapp/.github#usage
  3. E.g. feat(conversation-list): Sort conversations by most emojis in the title #SQPIT-764.

@ohassine ohassine requested review from MohamadJaara, a team, typfel, yamilmedina, alexandreferris and Garzas and removed request for a team December 15, 2023 09:19
Copy link
Contributor

Test Results

702 tests   702 ✔️  9m 12s ⏱️
  99 suites      0 💤
  99 files        0

Results for commit e52007f.

Copy link
Contributor

APKs built during tests are available here. Scroll down to Artifacts!

@AndroidBob
Copy link
Collaborator

Build 2310 succeeded.

The build produced the following APK's:

@MohamadJaara MohamadJaara merged commit 26be39e into release/candidate Dec 15, 2023
12 checks passed
@MohamadJaara MohamadJaara deleted the remove_ReportDrawnWhen_api branch December 15, 2023 15:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants