-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Add attributed metrics internal dev settings #6901
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
Add attributed metrics internal dev settings #6901
Conversation
|
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
bedf6b7 to
5fd75af
Compare
marcosholgado
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
| import java.util.* | ||
| import javax.inject.Inject | ||
|
|
||
| @InjectWith(ViewScope::class) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm gonna guess these 2 files and the layout are here rather than in the attributed internal module because some dependencies are within the app module?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Correct, there's some stored data that belongs to other modules and our logic depends on those values. So allowing other modules to include internal views here. I was about to create an statistics-internal setting, but some data also belongs to :app module, and it was too much to create several new settings.
0602cd7 to
1e2a8db
Compare
5fd75af to
6a6bd27
Compare
1e2a8db to
8c38c24
Compare
6a6bd27 to
56ec903
Compare
7bc82de to
9877907
Compare
56ec903 to
78547d9
Compare
9877907 to
a93f92a
Compare
78547d9 to
5e2e3da
Compare
a93f92a to
a79e076
Compare
5e2e3da to
b0525e6
Compare
a79e076 to
ec2ac1f
Compare
b0525e6 to
78c4bd9
Compare
ec2ac1f to
f4a53c4
Compare
78c4bd9 to
075c16c
Compare
f4a53c4 to
8935fae
Compare
075c16c to
8342549
Compare
Task/Issue URL: https://app.asana.com/1/137249556945/project/488551667048375/task/1211382557175158?focus=true and: https://app.asana.com/1/137249556945/project/488551667048375/task/1211382557175159?focus=true ### Description Introduces 2 attributed metrics and their initial implementation. ### Steps to test this PR While testing this PR you need to add the following in your logcat filter: `tag~:"AttributedMetrics"` Note: Test cases should be executed in order _Not enough data_ - [x] We need fresh install (including removing DDG folder in file system) - [x] Open the app - [x] wait until "skip onboarding" appears - [x] After downloading privacy config and atb init, you should see `Client status running: true -> isActive: true, isEnabled: true` - [x] Skip onboarding, and go to the browser - [x] Go to settings -> `Attributed Metrics Dev Settings` - [x] Update app retention atb with `v502-1` (and click save) - [x] Update search atb with `v502-1` (and click save) - [x] Update installation date with 10-8d ago (and click save) - [x] Go back to the browser - [x] Perform a search - [x] No pixels are emitted, `SearchCount7d: Skip emitting, atb not changed` _Sending data_ - [x] Go to settings -> `Attributed Metrics Dev Settings` - [x] Click on "Add Search Events" - [x] Update app retention atb with `v502-1` (and click save) - [x] Update search atb with `v502-1` (and click save) - [x] Go back to the browser - [x] Perform a NEW search - [x] Ensure you see `Fired pixel user_average_searches_past_week_first_month with params {count=0}` (Note: 0 is the bucket, not value. Notice first_month in pixel name) - [x] Close the app, open it again (or fire button) - [x] Ensure you see `Fired pixel user_active_past_week with params {days=2}`(note: 2 is the bucket, not the value) _Trigger only if search atb refreshes_ - [x] Perform a new search - [x] No pixels are emitted, `SearchCount7d: Skip emitting, atb not changed` - [x] You should see 2 collected events (both `ddg_search_days` and `ddg_search`) _Trigger only if app retention atb refreshes_ - [x] Close app, open it again (or fire button) - [x] No pixel emitted, `SearchDays: Skip emitting atb not changed`) _installation >1mo ago_ - [ ] Go to settings -> `Attributed Metrics Dev Settings` - [x] Update app retention atb with `v402-1` (and click save) - [x] Update search atb with `v402-1` (and click save) - [x] Update installation date with some day in August (and click save) - [x] Perform a new search - [x] Ensure you see `Fired pixel user_average_searches_past_week with params {count=0}` (Note: 0 is the bucket, not value. Notice this is not first_month) - [x] Close app, open it again (or fire button) - [x] Ensure you see `Fired pixel user_active_past_week with params {days=2}`(note: 2 is the bucket, not the value) _Client not active_ - [x] Clear storage - [x] Open the app - [x] After downloading privacy config and atb init, you should see `Client status running: false -> isActive: false, isEnabled: true` - [x] Skip onboarding, and go to the browser - [x] Perform a search - [x] Ensure nothing collected `Discard collect event....client not active` ### UI changes | Before | After | | ------ | ----- | !(Upload before screenshot)|(Upload after screenshot)|
75480f7
into
feature/cristian/attributed_metrics_module
Task/Issue URL: https://app.asana.com/1/137249556945/project/488551667048375/task/1211578504512146?focus=true ### Description Includes a dev setting screen for testing purposes. It will allow you to: - Add fake data - Update atb - Update origin - Update installation date ### Steps to test this PR _Feature 1_ - [ ] fresh install internal debug - [ ] go settings -> "Attributed Metrics Dev Settings" - [ ] ensure data about client, atb and installation is present (and see if it matches expectation) ### UI changes | Before | After | | ------ | ----- | !(Upload before screenshot)|(Upload after screenshot)|

Task/Issue URL: https://app.asana.com/1/137249556945/project/488551667048375/task/1211578504512146?focus=true
Description
Includes a dev setting screen for testing purposes. It will allow you to:
Steps to test this PR
Feature 1
UI changes