-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Extensible PixelName API #1129
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
Extensible PixelName API #1129
Conversation
ca42480 to
4d34aa7
Compare
4d34aa7 to
f913790
Compare
| WEB_RENDERER_GONE_CRASH("m_d_wrg_c"), | ||
| WEB_RENDERER_GONE_KILLED("m_d_wrg_k"), | ||
|
|
||
| APP_LAUNCH("ml"), | ||
|
|
||
| FORGET_ALL_PRESSED_BROWSING("mf_bp"), | ||
| FORGET_ALL_PRESSED_TABSWITCHING("mf_tp"), | ||
| FORGET_ALL_EXECUTED("mf"), | ||
| FORGET_ALL_AUTO_RESTART("m_f_r"), | ||
| FORGET_ALL_AUTO_RESTART_WITH_INTENT("m_f_ri"), | ||
| COOKIE_DATABASE_NOT_FOUND("m_cdb_nf"), | ||
| COOKIE_DATABASE_OPEN_ERROR("m_cdb_oe"), | ||
| COOKIE_DATABASE_DELETE_ERROR("m_cdb_de"), | ||
| COOKIE_DATABASE_CORRUPTED_ERROR("m_cdb_ce"), |
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.
These pixels are use in the OfflinePixelSender that lives in the statistics gradle module.
I think at some point we should also look into not having these pixels in the statistics gradle module. Ideally it should only contain the public API for the pixels, but none of the pixel names to be sent.
for now I just left these here
malmstein
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.
small comment on the test logging, otherwise great work @aitorvs
| fun verifyNoDuplicatePixelNames() { | ||
| val existingNames = mutableSetOf<String>() | ||
| Pixel.PixelName.values().forEach { | ||
| AppPixelName.values().forEach { |
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.
👍
| Pixel.PixelName.values().forEach { | ||
| AppPixelName.values().forEach { | ||
| if (!existingNames.add(it.pixelName)) { | ||
| fail("Duplicate pixel name found: ${it.pixelName}") |
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.
Maybe be more specific towards what type of pixel is missing? Something like "Duplicate app / statistics pixel name found"
Task/Issue URL: https://app.asana.com/0/0/1200049149472987/f
Tech Design URL: https://app.asana.com/0/715106103902962/1200043236683507/f
CC:
Description:
This PR
PixelNameas an interface so that it can be extendedSteps to test this PR:
(it is not extrictly necessary to perform any test as all issues should be detected at compile time)
Internal references:
Software Engineering Expectations
Technical Design Template