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

[Android] fix crash enable brave news when no internet connection #17012

Merged
merged 1 commit into from
Feb 3, 2023

Conversation

tapanmodh
Copy link
Contributor

@tapanmodh tapanmodh commented Feb 3, 2023

Resolves brave/brave-browser#28197

Submitter Checklist:

  • I confirm that no security/privacy review is needed, or that I have requested one
  • There is a ticket for my issue
  • Used Github auto-closing keywords in the PR description above
  • Wrote a good PR/commit description
  • Squashed any review feedback or "fixup" commits before merge, so that history is a record of what happened in the repo, not your PR
  • Added appropriate labels (QA/Yes or QA/No; release-notes/include or release-notes/exclude; OS/...) to the associated issue
  • Checked the PR locally:
    • npm run test -- brave_browser_tests, npm run test -- brave_unit_tests wiki
    • npm run lint, npm run presubmit wiki, npm run gn_check, npm run tslint
  • Ran git rebase master (if needed)

Reviewer Checklist:

  • A security review is not needed, or a link to one is included in the PR description
  • New files have MPL-2.0 license header
  • Adequate test coverage exists to prevent regressions
  • Major classes, functions and non-trivial code blocks are well-commented
  • Changes in component dependencies are properly reflected in gn
  • Code follows the style guide
  • Test plan is specified in PR before merging

After-merge Checklist:

Test Plan:

  1. Install this build
  2. Disable the internet connection
  3. Open the app and go through the welcome onboarding
  4. Tap on Show Brave News button from news card on NTP
  5. It shouldn't crash

@tapanmodh tapanmodh added CI/skip-linux CI/skip-macos-x64 Do not run CI builds for macOS x64 CI/skip-ios Do not run CI builds for iOS labels Feb 3, 2023
@tapanmodh tapanmodh added this to the 1.50.x - Nightly milestone Feb 3, 2023
@tapanmodh tapanmodh self-assigned this Feb 3, 2023
Copy link
Member

@SergeyZhukovsky SergeyZhukovsky left a comment

Choose a reason for hiding this comment

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

++. That's cool, we have users who experience that crash and I see it in GPS as well. We want to uplift it up to a stable channel as it's a problem there as well.

@stephendonner
Copy link
Contributor

Verified PASSED using 1.50.9, Chromium 110.0.5481.77 on a Google Pixel XL (arm64) running Android 9

Steps:

  1. installed 1.50.9
  2. launched Brave
  3. disabled Wi-Fi
  4. tapped through onboarding
  5. swiped up on the new-tab page
  6. tapped Show Brave News

Confirmed Brave restarts now, rather than hard-crashing, when it hits this case

1.50.9 1.49.77
20230204_175218.mp4
20230204_175707.mp4

@kjozwiak
Copy link
Member

kjozwiak commented Feb 6, 2023

Didn't see #17012 (comment) before checking so quickly went through the above as well and verified that everything seems to be working. Went through a few other cases to ensure everything was working as expected.

Verification PASSED on Pixel 6 running Android 13 using the following build(s):

Brave | 1.50.11 Chromium: 110.0.5481.77 (Official Build) canary (32-bit)
--- | ---
Revision | 65ed616c6e8ee3fe0ad64fe83796c020644d42af-refs/branch-heads/5481@{#839}
OS | Android 13; Build/TQ1A.230105.002
  • ensure there's no crashes when enabling/disabling Brave News while the network is disabled and the feed never loaded
  • ensured that enabling the network loaded the news feed when opening a NTP without any issues
  • ensured that you can scroll through the news feed without any issues
  • ensured that you're seeing Brave Ads within the news feed
  • ensured that tapping on articles opens them within the same tab without any issues
Example Example
image image

kjozwiak pushed a commit that referenced this pull request Feb 6, 2023
kjozwiak pushed a commit that referenced this pull request Feb 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI/skip-ios Do not run CI builds for iOS CI/skip-macos-x64 Do not run CI builds for macOS x64
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Exception when no internet connection load Brave News
5 participants