Closed Bug 2001801 Opened 4 months ago Closed 2 months ago

Custom review prompt being displayed repeatedly in 145.0.1

Categories

(Firefox for Android :: Onboarding, defect, P2)

All
Android
defect

Tracking

()

VERIFIED FIXED
149 Branch
Tracking Status
firefox145 + wontfix
firefox146 + disabled
firefox147 + disabled
firefox148 --- verified
firefox149 --- verified

People

(Reporter: towhite, Assigned: mkozinski)

References

(Regression)

Details

(Keywords: regression, Whiteboard: [fxdroid][group2])

Attachments

(3 files, 2 obsolete files)

Original Reddit post of behaviour.

It appears the triggers aren't being respected OR the prompt recording is failing somehow. Not seeing any reports in Bugzilla so far or any other Reddit posts. Please link here if you see any.

Possible regression caused by https://bugzilla.mozilla.org/show_bug.cgi?id=1998628.

Whiteboard: [fxdroid][group2]
Component: Accounts and Sync → Onboarding
Attachment #9528550 - Attachment description: WIP: Bug 2001801 - Simplify logic structure (refactor) and don't process showing the review if the user is not eligible. → WIP: Bug 2001801 - Simplify logic structure (refactor) for handleReviewPromptCheck and don't process showing the review if the user is not eligible.
Attachment #9528550 - Attachment description: WIP: Bug 2001801 - Simplify logic structure (refactor) for handleReviewPromptCheck and don't process showing the review if the user is not eligible. → WIP: Bug 2001801 - Don't process showing the review if the user is not eligible in handleReviewPromptCheck.

Set release status flags based on info from the regressing bug 1998628

:mkozinski, since you are the author of the regressor, bug 1998628, could you take a look? Also, could you set the severity field?

For more information, please visit BugBot documentation.

Flags: needinfo?(mkozinski)

The bug is marked as tracked for firefox145 (release), tracked for firefox146 (beta) and tracked for firefox147 (nightly). We have limited time to fix this, the soft freeze is in 10 days. However, the bug still isn't assigned.

:mavduevskiy, could you please find an assignee for this tracked bug? Given that it is a regression and we know the cause, we could also simply backout the regressor. If you disagree with the tracking decision, please talk with the release managers.

For more information, please visit BugBot documentation.

Flags: needinfo?(mavduevskiy)

Wontfix for 145 as we ship our last dot release tomorrow

Assignee: nobody → towhite

At this time, the issue appears to be isolated, with reports limited to the Reddit OP
and one additional commenter. The OP noted that enabling the Debug menu resolved the problem, though there is no clear technical rationale for why that would have an impact.

QA (Mira) was not able to reproduce this on several devices:

Pixel 6 (Android 16), Samsung Galaxy S22 Ultra (Android 16), and Xiaomi Redmi Note 8 (Android 11).

No related Bugzilla reports were found during investigation.

Severity: -- → S3
Flags: needinfo?(mkozinski)
Flags: needinfo?(mavduevskiy)
Priority: -- → P2

We will observe for any issues related to this until 146 ships on December 9th.

Attachment #9528550 - Attachment is obsolete: true
Assignee: towhite → mkozinski
Regressions: 2004459
See Also: → 2004459

Set release status flags based on info from the regressing bug 1998628

Depends on: 2004459
No longer regressions: 2004459
See Also: 2004459
Status: NEW → ASSIGNED
Blocks: 2010551

I figured out steps to put the app in a state that reproduces the behaviour reported in the Reddit posts. There are likely other scenarios that cause the same behaviour and its almost certain that affected people didn't take these exact steps. So it doesn't explain how to prevent getting into a bad state, but at least it lets us test what happens in such state.

Prerequisites:

  • Rooted device.
    (Doesn't need to be a physical device, can be an emulator. For example emulators with AOSP builds are rooted out of the box.)
  • adb available to send commands to the device.

Steps:

  • adb shell
    This opens an interactive shell on the device. The following commands are going to run on the device, not on your machine.
  • su
    This opens a superuser/root shell. The following commands are going to run as superuser/root.
  • The last command depends on the type of the build:
    • Debug: chmod u-rx /data/data/org.mozilla.fenix.debug/nimbus_data/db
    • Nightly: chmod u-rx /data/data/org.mozilla.fenix/nimbus_data/db
    • Beta: chmod u-rx /data/data/org.mozilla.firefox_beta/nimbus_data/db
    • Release/Production: chmod u-rx /data/data/org.mozilla.firefox/nimbus_data/db
      This causes permanent "Permission denied" errors when Nimbus SDK initialises and tries to read the database from disk.
  • Force-stop and restart the application. Nimbus SDK database errors should be visible in logcat. If other criteria are satisfied (at least 5 app opens, set as default browser) the review prompt should be shown on each restart on affected builds (from 145.0.1 to 146).

I managed to reproduce the issue on the Firefox for Android 145.0.1 on an emulator, on Android Studio, following the steps provided by Marcin, and with his guidance.
I've attached a short video with the issue. It is 100% reproducible.

Status: ASSIGNED → RESOLVED
Closed: 2 months ago
Resolution: --- → FIXED
Target Milestone: --- → 149 Branch
Flags: qe-verify+

Verified on the Firefox for Android Nightly build from 1/20 on an emulator (by running the terminal command with the steps from Comment 11) and I am not able to see the prompt at all, even after setting Firefox for Android Nightly as the default browser, and restarted 5 time.

Flags: qe-verify+

firefox-beta Uplift Approval Request

  • User impact if declined: If declined we'll continue to prompt for reviews in a non-optimised way, resulting in lower average rating.
  • Code covered by automated testing: yes
  • Fix verified in Nightly: yes
  • Needs manual QE test: yes
  • Steps to reproduce for manual QE testing: - Install the build on a rooted device (for example emulator with an AOSP build).
  • Run adb shell in terminal, so the following commands run on the test device/emulator.
  • Run su on the device/emulator.
  • The last command depends on the type of the build:
    Debug: chmod u-rx /data/data/org.mozilla.fenix.debug/nimbus_data/db
    Nightly: chmod u-rx /data/data/org.mozilla.fenix/nimbus_data/db
    Beta: chmod u-rx /data/data/org.mozilla.firefox_beta/nimbus_data/db
    Release/Production: chmod u-rx /data/data/org.mozilla.firefox/nimbus_data/db

This causes permanent "Permission denied" errors when Nimbus SDK initialises and tries to read the database from disk.

  • Force-stop and restart the application. Nimbus SDK database errors should be visible in logcat.
  • Satisfy prompt criteria, by setting the app as default browser and restarting at least 5 times.

Expected behaviour (with this workaround and the second patch to re-enable the prompt): The prompt never shows.

Expected behaviour without the steps to cause "Permission denied" errors: The prompt shows once after satisfying criteria.

  • Risk associated with taking this patch: low
  • Explanation of risk level: We've investigated the issue for a long time and are confident in our understanding of what caused the prompt to show repeatedly. We've verified the fix in manual testing on debug and nightly builds. If we're still wrong, the worst that could happen is we regress the repeated prompts issue, which happens for a small fraction of % of people.
  • String changes made/needed: no
  • Is Android affected?: yes
Attachment #9538987 - Flags: approval-mozilla-beta?
Flags: qe-verify+

firefox-release Uplift Approval Request

  • User impact if declined: If declined we'll continue to prompt for reviews in a non-optimised way, resulting in lower average rating.
  • Code covered by automated testing: yes
  • Fix verified in Nightly: yes
  • Needs manual QE test: yes
  • Steps to reproduce for manual QE testing: - Install the build on a rooted device (for example emulator with an AOSP build).
  • Run adb shell in terminal, so the following commands run on the test device/emulator.
  • Run su on the device/emulator.
  • The last command depends on the type of the build:
    Debug: chmod u-rx /data/data/org.mozilla.fenix.debug/nimbus_data/db
    Nightly: chmod u-rx /data/data/org.mozilla.fenix/nimbus_data/db
    Beta: chmod u-rx /data/data/org.mozilla.firefox_beta/nimbus_data/db
    Release/Production: chmod u-rx /data/data/org.mozilla.firefox/nimbus_data/db

This causes permanent "Permission denied" errors when Nimbus SDK initialises and tries to read the database from disk.

  • Force-stop and restart the application. Nimbus SDK database errors should be visible in logcat.
  • Satisfy prompt criteria, by setting the app as default browser and restarting at least 5 times.

Expected behaviour (with this workaround and the second patch to re-enable the prompt): The prompt never shows.

Expected behaviour without the steps to cause "Permission denied" errors: The prompt shows once after satisfying criteria.

  • Risk associated with taking this patch: low
  • Explanation of risk level: We've investigated the issue for a long time and are confident in our understanding of what caused the prompt to show repeatedly. We've verified the fix in manual testing on debug and nightly builds. If we're still wrong, the worst that could happen is we regress the repeated prompts issue, which happens for a small fraction of % of people.
  • String changes made/needed: no
  • Is Android affected?: yes
Attachment #9538988 - Flags: approval-mozilla-release?

Bug 2004459 disabled the custom review prompts. Bug 2010551 enabled it but is only in Nightly (Fx149).
Marcin, can you clarify why we need an uplift for Beta (FX148) and Release (Fx147)?

EDIT: I see Bug 2010551 has uplift requests also, so cancelling the need-info. I'm going to let this bake in Nightly for a few more days before uplifting to Beta.

Flags: needinfo?(mkozinski)
Flags: needinfo?(mkozinski)
Attachment #9538987 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

Verified on the Firefox for Android Beta 148.0b7 on an emulator (by running the terminal command with the steps from Comment 18) and I was able to see the prompt once, after setting Firefox for Android Beta as the default browser, and restarted 5 times.

Status: RESOLVED → VERIFIED
Flags: qe-verify+
Attachment #9538988 - Attachment is obsolete: true
Attachment #9538988 - Flags: approval-mozilla-release?
See Also: → 2013858
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: