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

[PLAT-5040] Ignore OOMs that occur while the app is inactive #1416

Merged
merged 1 commit into from
Jun 27, 2022

Conversation

nickdowell
Copy link
Contributor

Goal

Ignore OOMs that occur in UIApplicationStateInactive, restoring behaviour previously introduced by #394.

Pull request #1307 (in v6.16.4) inadvertently stopped rejecting these OOMs.

Changeset

Adds BSGRunContext.inActive.
Observes UIApplicationDidBecomeActiveNotification / WillResignActiveNotification.
Checks isActive in BSGRunContextWasKilled().

Enables state tracking on tvOS, since OOMs are also reported there.

Testing

Adds an E2E scenario that simulates an OOM occurring in UIApplicationStateInactive and verifies that no error is reported.

@nickdowell nickdowell requested a review from kattrali June 27, 2022 09:52
@github-actions
Copy link

Bugsnag.framework binary size increased by 560 bytes from 814,656 to 815,216

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.2%    +352  +0.2%    +352    Symbol Table
  +0.1%    +324  +0.1%    +324    __TEXT,__text
  +0.1%    +200  +0.1%    +200    String Table
  +0.9%     +32  +0.9%     +32    __DATA,__const
  +0.4%      +8  +0.4%      +8    Rebase Info
  +0.2%      +8  +0.2%      +8    __TEXT,__unwind_info
  -0.4%     -32  -0.2%     -32    [__DATA]
  -1.4%    -332  -1.4%    -332    [__TEXT]
  [ = ]       0 -12.3%    -560    [__LINKEDIT]
  +0.1%    +560  [ = ]       0    TOTAL

Generated by 🚫 Danger

@nickdowell nickdowell merged commit c9ae6fd into next Jun 27, 2022
@nickdowell nickdowell deleted the nickdowell/ignore-inactive-ooms branch June 27, 2022 13:58
@nickdowell nickdowell changed the title Ignore OOMs that occur while the app is inactive [PLAT-5040] Ignore OOMs that occur while the app is inactive Jun 28, 2022
@nickdowell nickdowell mentioned this pull request Jun 29, 2022
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.

2 participants