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

Additional "default browser" prompts: variant 2 #5476

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

LukasPaczos
Copy link
Contributor

@LukasPaczos LukasPaczos commented Jan 15, 2025

Task/Issue URL: https://app.asana.com/0/1208671518894266/1208944504536347/f

Description

Introduces variant 2 of the experiment that proposes new CTAs around setting DDG as a default browser. The PR also adds all of the experiment foundations and abstractions, so the remaining two variants will only be a small formality.

I'm going to follow up on pixels in a separate PR.

Class diagram

image

Flow diagram

image

Steps to test this PR

This PR relies on the new A/B/N framework for rollout, so to test you'll need a custom privacy config which includes the feature definition, for example:

"defaultBrowserPrompts": {
  "state": "enabled",
  "exceptions": [],
  "features": {
    "additionalPrompts": {
      "state": "enabled",
      "rollout": {
        "steps": [
          {
            "percent": 100
          }
        ]
      },
      "settings": {
        "activeDaysUntilStage1": 1,
        "activeDaysUntilStage2": 3,
        "activeDaysUntilStop": 5
      },
      "cohorts": [
        {
          "name": "control",
          "weight": 0
        },
        {
          "name": "variant_2",
          "weight": 1
        }
      ]
    }
  },
}

or you can apply this JSON Blob:

diff --git a/privacy-config/privacy-config-api/src/main/java/com/duckduckgo/privacy/config/api/PrivacyFeatureName.kt b/privacy-config/privacy-config-api/src/main/java/com/duckduckgo/privacy/config/api/PrivacyFeatureName.kt
index ca0870311..5a904f76b 100644
--- a/privacy-config/privacy-config-api/src/main/java/com/duckduckgo/privacy/config/api/PrivacyFeatureName.kt
+++ b/privacy-config/privacy-config-api/src/main/java/com/duckduckgo/privacy/config/api/PrivacyFeatureName.kt
@@ -27,4 +27,5 @@ enum class PrivacyFeatureName(val value: String) {
     TrackingParametersFeatureName("trackingParameters"),
 }
 
-const val PRIVACY_REMOTE_CONFIG_URL = "https://staticcdn.duckduckgo.com/trackerblocking/config/v4/android-config.json"
+// const val PRIVACY_REMOTE_CONFIG_URL = "https://staticcdn.duckduckgo.com/trackerblocking/config/v4/android-config.json"
+const val PRIVACY_REMOTE_CONFIG_URL = "https://www.jsonblob.com/api/1329040942036082688"

Once built with the right config, ensure that you don't have DDG app set as a default browser, only then you'll be assigned to the experiment.

Given the example config above:

  • after one active day you'll see a dialog pop up
  • after additional 2 active days you'll see a highlighted menu icon and a new menu button
  • after additional 2 days, the menu button will disappear

If you convert at any point and set DDG app as default browser, the experiment will permanently stop.

Screen_recording_20250115_173728.webm

In the video I'm using the ADB commands to change the date, but any mechanism of date change will be enough :)

@LukasPaczos LukasPaczos force-pushed the feature/lukasz-p/default-browser-prompts-variant-2 branch 4 times, most recently from 4f0b107 to 042d38e Compare January 17, 2025 13:06
@LukasPaczos LukasPaczos marked this pull request as ready for review January 17, 2025 13:11
@LukasPaczos LukasPaczos requested a review from malmstein January 17, 2025 13:11
@LukasPaczos LukasPaczos force-pushed the feature/lukasz-p/default-browser-prompts-variant-2 branch 3 times, most recently from 916a745 to 4a97b9f Compare January 22, 2025 12:49
@LukasPaczos LukasPaczos force-pushed the feature/lukasz-p/default-browser-prompts-variant-2 branch from 4a97b9f to 6c7a3cd Compare January 23, 2025 13:19
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.

1 participant