Skip to content

add cpc and cpm and rate#1392

Merged
mozza-wins merged 2 commits intomainfrom
molly/cpc
Feb 11, 2026
Merged

add cpc and cpm and rate#1392
mozza-wins merged 2 commits intomainfrom
molly/cpc

Conversation

@mozza-wins
Copy link
Contributor

@mozza-wins mozza-wins commented Feb 11, 2026

moving cpm and cpc calculations to lookml instead
because we created eCPM in the view directly, this field is now duplicate as a dimension, but we still need a measure for it to work in looker

@github-actions
Copy link

Integration report for "this commit"

lookml.diff

Click to expand!
Only in /tmp/workspace/looker-hub/firefox_ios: dashboards
Only in /tmp/workspace/looker-hub/marketing: datagroups
Only in /tmp/workspace/looker-hub/search_private/datagroups: search_term_data_validation_reports_last_updated.datagroup.lkml
Only in /tmp/workspace/looker-hub/search_private/datagroups: search_term_sanitization_job_metadata_daily_last_updated.datagroup.lkml
Only in /tmp/workspace/looker-hub/: user_journey
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/ads/views/campaigns_monthly.view.lkml /tmp/workspace/generated-lookml/ads/views/campaigns_monthly.view.lkml
--- /tmp/workspace/looker-hub/ads/views/campaigns_monthly.view.lkml	2026-02-11 22:51:48.910757365 +0000
+++ /tmp/workspace/generated-lookml/ads/views/campaigns_monthly.view.lkml	2026-02-11 22:51:44.515741931 +0000
@@ -185,6 +185,21 @@
     type: sum
   }
 
+  measure: booked_rate {
+    sql: SAFE_DIVIDE(${booked_budget}, ${sold_quantity}) ;;
+    type: number
+  }
+
+  measure: cpc {
+    sql: SAFE_DIVIDE(${booked_budget}, ${budgeted_clicks}) ;;
+    type: number
+  }
+
+  measure: cpm {
+    sql: SAFE_DIVIDE(${booked_budget}, ${budgeted_impressions}) ;;
+    type: number
+  }
+
   measure: total_delivered_revenue {
     sql: ${delivered_revenue} ;;
     type: sum
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/fenix/views/metrics.view.lkml /tmp/workspace/generated-lookml/fenix/views/metrics.view.lkml
--- /tmp/workspace/looker-hub/fenix/views/metrics.view.lkml	2026-02-11 22:51:48.929757432 +0000
+++ /tmp/workspace/generated-lookml/fenix/views/metrics.view.lkml	2026-02-11 22:51:44.731742690 +0000
@@ -23704,24 +23704,6 @@
 "
   }
 
-  dimension: metrics__string__preferences_prefs_file_first_parse_error {
-    label: "Preferences: Prefs File First Parse Error"
-    hidden: no
-    sql: ${TABLE}.metrics.string.preferences_prefs_file_first_parse_error ;;
-    type: string
-    group_label: "Preferences"
-    group_item_label: "Prefs File First Parse Error"
-
-    link: {
-      label: "Glean Dictionary reference for Preferences: Prefs File First Parse Error"
-      url: "https://dictionary.telemetry.mozilla.org/apps/fenix/metrics/preferences_prefs_file_first_parse_error"
-      icon_url: "https://dictionary.telemetry.mozilla.org/favicon.png"
-    }
-
-    description: "The first error message encountered when parsing a prefs file.
-"
-  }
-
   dimension: metrics__boolean__preferences_prefs_file_was_invalid {
     label: "Preferences: Prefs File Was Invalid"
     hidden: no
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/fenix/views/user_characteristics.view.lkml /tmp/workspace/generated-lookml/fenix/views/user_characteristics.view.lkml
--- /tmp/workspace/looker-hub/fenix/views/user_characteristics.view.lkml	2026-02-11 22:51:48.937757460 +0000
+++ /tmp/workspace/generated-lookml/fenix/views/user_characteristics.view.lkml	2026-02-11 22:51:44.907743307 +0000
@@ -41,24 +41,6 @@
 "
   }
 
-  dimension: metrics__string__characteristics_audio_compressor_gain_reduction {
-    label: "Characteristics: Audio Compressor Gain Reduction"
-    hidden: no
-    sql: ${TABLE}.metrics.string.characteristics_audio_compressor_gain_reduction ;;
-    type: string
-    group_label: "Characteristics"
-    group_item_label: "Audio Compressor Gain Reduction"
-
-    link: {
-      label: "Glean Dictionary reference for Characteristics: Audio Compressor Gain Reduction"
-      url: "https://dictionary.telemetry.mozilla.org/apps/fenix/metrics/characteristics_audio_compressor_gain_reduction"
-      icon_url: "https://dictionary.telemetry.mozilla.org/favicon.png"
-    }
-
-    description: "WebAudio DynamicsCompressorNode gain reduction value from OfflineAudioContext rendering. This is most likely consistent for all/most users but we wish to verify that experimentally.
-"
-  }
-
   dimension: metrics__text2__characteristics_audio_devices {
     label: "Characteristics: Audio Devices"
     hidden: yes
@@ -95,60 +77,6 @@
 "
   }
 
-  dimension: metrics__string__characteristics_audio_fingerprint2 {
-    label: "Characteristics: Audio Fingerprint2"
-    hidden: no
-    sql: ${TABLE}.metrics.string.characteristics_audio_fingerprint2 ;;
-    type: string
-    group_label: "Characteristics"
-    group_item_label: "Audio Fingerprint2"
-
-    link: {
-      label: "Glean Dictionary reference for Characteristics: Audio Fingerprint2"
-      url: "https://dictionary.telemetry.mozilla.org/apps/fenix/metrics/characteristics_audio_fingerprint2"
-      icon_url: "https://dictionary.telemetry.mozilla.org/favicon.png"
-    }
-
-    description: "A second method to calculate an audio fingerprint, used by a different fingerprinter. Hash of audio buffer sample snapshot (100 samples from 4500-4600 range) from OfflineAudioContext rendering.
-"
-  }
-
-  dimension: metrics__string__characteristics_audio_float_frequency_sum {
-    label: "Characteristics: Audio Float Frequency Sum"
-    hidden: no
-    sql: ${TABLE}.metrics.string.characteristics_audio_float_frequency_sum ;;
-    type: string
-    group_label: "Characteristics"
-    group_item_label: "Audio Float Frequency Sum"
-
-    link: {
-      label: "Glean Dictionary reference for Characteristics: Audio Float Frequency Sum"
-      url: "https://dictionary.telemetry.mozilla.org/apps/fenix/metrics/characteristics_audio_float_frequency_sum"
-      icon_url: "https://dictionary.telemetry.mozilla.org/favicon.png"
-    }
-
-    description: "Sum of float frequency data from AnalyserNode.getFloatFrequencyData() during OfflineAudioContext rendering. Collected as string to preserve floating-point precision.
-"
-  }
-
-  dimension: metrics__string__characteristics_audio_float_time_domain_sum {
-    label: "Characteristics: Audio Float Time Domain Sum"
-    hidden: no
-    sql: ${TABLE}.metrics.string.characteristics_audio_float_time_domain_sum ;;
-    type: string
-    group_label: "Characteristics"
-    group_item_label: "Audio Float Time Domain Sum"
-
-    link: {
-      label: "Glean Dictionary reference for Characteristics: Audio Float Time Domain Sum"
-      url: "https://dictionary.telemetry.mozilla.org/apps/fenix/metrics/characteristics_audio_float_time_domain_sum"
-      icon_url: "https://dictionary.telemetry.mozilla.org/favicon.png"
-    }
-
-    description: "Sum of float time domain data from AnalyserNode.getFloatTimeDomainData() during OfflineAudioContext rendering. Collected as string to preserve floating-point precision.
-"
-  }
-
   dimension: metrics__quantity__characteristics_audio_frames {
     label: "Characteristics: Audio Frames"
     hidden: no
@@ -185,24 +113,6 @@
 "
   }
 
-  dimension: metrics__quantity__characteristics_audio_unique_samples {
-    label: "Characteristics: Audio Unique Samples"
-    hidden: no
-    sql: ${TABLE}.metrics.quantity.characteristics_audio_unique_samples ;;
-    type: number
-    group_label: "Characteristics"
-    group_item_label: "Audio Unique Samples"
-
-    link: {
-      label: "Glean Dictionary reference for Characteristics: Audio Unique Samples"
-      url: "https://dictionary.telemetry.mozilla.org/apps/fenix/metrics/characteristics_audio_unique_samples"
-      icon_url: "https://dictionary.telemetry.mozilla.org/favicon.png"
-    }
-
-    description: "Count of unique sample values in the OfflineAudioContext audio buffer. This is used by fingerprinting scripts to detect anamolies - they expect 1-3k unique samples, not 5000. We are collecting it to ensure we are behaving as they generally expect non-anomalous browsers to behave.
-"
-  }
-
   dimension: metrics__quantity__characteristics_avail_height {
     label: "Characteristics: Avail Height"
     hidden: no
@@ -4429,7 +4339,7 @@
       icon_url: "https://dictionary.telemetry.mozilla.org/favicon.png"
     }
 
-    description: "The list of GL parameters of GL1. Parameters: ALIASED_LINE_WIDTH_RANGE, ALIASED_POINT_SIZE_RANGE, MAX_COMBINED_TEXTURE_IMAGE_UNITS, MAX_CUBE_MAP_TEXTURE_SIZE, MAX_FRAGMENT_UNIFORM_VECTORS, MAX_RENDERBUFFER_SIZE, MAX_TEXTURE_IMAGE_UNITS, MAX_TEXTURE_SIZE, MAX_VARYING_VECTORS, MAX_VERTEX_ATTRIBS, MAX_VERTEX_TEXTURE_IMAGE_UNITS, MAX_VERTEX_UNIFORM_VECTORS, MAX_VIEWPORT_DIMS, SHADING_LANGUAGE_VERSION, STENCIL_BACK_VALUE_MASK, STENCIL_BACK_WRITEMASK, STENCIL_VALUE_MASK, STENCIL_WRITEMASK, SUBPIXEL_BITS.
+    description: "The list of GL parameters of GL1.
 "
   }
 
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/firefox_desktop/views/metric_definitions_firefox_desktop_active_users_view.view.lkml /tmp/workspace/generated-lookml/firefox_desktop/views/metric_definitions_firefox_desktop_active_users_view.view.lkml
--- /tmp/workspace/looker-hub/firefox_desktop/views/metric_definitions_firefox_desktop_active_users_view.view.lkml	2026-02-11 22:51:48.951757509 +0000
+++ /tmp/workspace/generated-lookml/firefox_desktop/views/metric_definitions_firefox_desktop_active_users_view.view.lkml	2026-02-11 22:51:44.896743269 +0000
@@ -8,6 +8,7 @@
   derived_table: {
     sql: SELECT
                 COUNTIF(is_dau) AS client_level_daily_active_users_v2,
+COALESCE(MIN(mozfun.bits28.days_since_seen(days_active_bits)), 30) < 3 AS active_in_last_3_days_legacy,
 
                 looker_base_fields_app_name,
 looker_base_fields_app_version,
@@ -215,6 +216,14 @@
     sql: ${TABLE}.client_level_daily_active_users_v2 ;;
   }
 
+  dimension: active_in_last_3_days_legacy {
+    group_label: "Metrics"
+    label: "3 Days Retention"
+    description: "Records whether a client submitted any pings (i.e. used Firefox) on any of the last 3 days. Uses legacy telemetry."
+    type: number
+    sql: ${TABLE}.active_in_last_3_days_legacy ;;
+  }
+
   dimension: app_name {
     sql: ${TABLE}.looker_base_fields_app_name ;;
     type: string
@@ -323,7 +332,7 @@
   }
 
   set: metrics {
-    fields: [client_level_daily_active_users_v2]
+    fields: [client_level_daily_active_users_v2, active_in_last_3_days_legacy]
   }
 
   parameter: aggregate_metrics_by {
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/firefox_desktop/views/metric_definitions_firefox_desktop_baseline_active_users_view.view.lkml /tmp/workspace/generated-lookml/firefox_desktop/views/metric_definitions_firefox_desktop_baseline_active_users_view.view.lkml
--- /tmp/workspace/looker-hub/firefox_desktop/views/metric_definitions_firefox_desktop_baseline_active_users_view.view.lkml	2026-02-11 22:51:48.952757513 +0000
+++ /tmp/workspace/generated-lookml/firefox_desktop/views/metric_definitions_firefox_desktop_baseline_active_users_view.view.lkml	2026-02-11 22:51:44.896743269 +0000
@@ -8,6 +8,7 @@
   derived_table: {
     sql: SELECT
                 COUNTIF(is_dau) AS client_level_daily_active_users_v2_glean,
+COALESCE(MIN(days_since_desktop_active), 30) < 3 AS active_in_last_3_days,
 
                 looker_base_fields_app_name,
 looker_base_fields_app_version,
@@ -215,6 +216,14 @@
     sql: ${TABLE}.client_level_daily_active_users_v2_glean ;;
   }
 
+  dimension: active_in_last_3_days {
+    group_label: "Metrics"
+    label: "3 Days Retention"
+    description: "Records whether a client submitted any pings (i.e. used Firefox) on any of the last 3 days."
+    type: number
+    sql: ${TABLE}.active_in_last_3_days ;;
+  }
+
   dimension: app_name {
     sql: ${TABLE}.looker_base_fields_app_name ;;
     type: string
@@ -323,7 +332,7 @@
   }
 
   set: metrics {
-    fields: [client_level_daily_active_users_v2_glean]
+    fields: [client_level_daily_active_users_v2_glean, active_in_last_3_days]
   }
 
   parameter: aggregate_metrics_by {
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/marketing/datagroups/firefox_for_families_forecasted_expectations_last_updated.datagroup.lkml /tmp/workspace/generated-lookml/marketing/datagroups/firefox_for_families_forecasted_expectations_last_updated.datagroup.lkml
--- /tmp/workspace/looker-hub/marketing/datagroups/firefox_for_families_forecasted_expectations_last_updated.datagroup.lkml	2026-02-11 22:51:48.977757601 +0000
+++ /tmp/workspace/generated-lookml/marketing/datagroups/firefox_for_families_forecasted_expectations_last_updated.datagroup.lkml	1970-01-01 00:00:00.000000000 +0000
@@ -1,20 +0,0 @@
-# *Do not manually modify this file*
-
-# This file has been generated via https://github.com/mozilla/lookml-generator
-
-# Using a datagroup in an Explore: https://cloud.google.com/looker/docs/reference/param-explore-persist-with
-# Using a datagroup in a derived table: https://cloud.google.com/looker/docs/reference/param-view-datagroup-trigger
-
-datagroup: firefox_for_families_forecasted_expectations_last_updated {
-  label: "firefox_for_families_forecasted_expectations Last Updated"
-  sql_trigger: SELECT MAX(storage_last_modified_time)
-    FROM (
-        
-    SELECT MAX(storage_last_modified_time) AS storage_last_modified_time
-    FROM `mozdata`.`region-us`.INFORMATION_SCHEMA.TABLE_STORAGE
-    WHERE (table_schema = 'analysis' AND table_name = 'marketing_firefox_for_families_forecasted_expectations')
-
-    ) ;;
-  description: "Updates for firefox_for_families_forecasted_expectations when referenced tables are modified."
-  max_cache_age: "24 hours"
-}
\ No newline at end of file
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/namespaces.yaml /tmp/workspace/generated-lookml/namespaces.yaml
--- /tmp/workspace/looker-hub/namespaces.yaml	2026-02-11 22:51:49.645759946 +0000
+++ /tmp/workspace/generated-lookml/namespaces.yaml	2026-02-11 22:51:49.570759683 +0000
@@ -288,6 +288,15 @@
         booked_impressions:
           sql: ${budgeted_impressions}
           type: sum
+        booked_rate:
+          sql: SAFE_DIVIDE(${booked_budget}, ${sold_quantity})
+          type: number
+        cpc:
+          sql: SAFE_DIVIDE(${booked_budget}, ${budgeted_clicks})
+          type: number
+        cpm:
+          sql: SAFE_DIVIDE(${booked_budget}, ${budgeted_impressions})
+          type: number
         total_delivered_revenue:
           sql: ${delivered_revenue}
           type: sum
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/search_private/datagroups/search_term_data_validation_reports_last_updated.datagroup.lkml /tmp/workspace/generated-lookml/search_private/datagroups/search_term_data_validation_reports_last_updated.datagroup.lkml
--- /tmp/workspace/looker-hub/search_private/datagroups/search_term_data_validation_reports_last_updated.datagroup.lkml	2026-02-11 22:51:49.026757773 +0000
+++ /tmp/workspace/generated-lookml/search_private/datagroups/search_term_data_validation_reports_last_updated.datagroup.lkml	1970-01-01 00:00:00.000000000 +0000
@@ -1,20 +0,0 @@
-# *Do not manually modify this file*
-
-# This file has been generated via https://github.com/mozilla/lookml-generator
-
-# Using a datagroup in an Explore: https://cloud.google.com/looker/docs/reference/param-explore-persist-with
-# Using a datagroup in a derived table: https://cloud.google.com/looker/docs/reference/param-view-datagroup-trigger
-
-datagroup: search_term_data_validation_reports_last_updated {
-  label: "search_term_data_validation_reports Last Updated"
-  sql_trigger: SELECT MAX(storage_last_modified_time)
-    FROM (
-        
-    SELECT MAX(storage_last_modified_time) AS storage_last_modified_time
-    FROM `moz-fx-data-shared-prod`.`region-us`.INFORMATION_SCHEMA.TABLE_STORAGE
-    WHERE (table_schema = 'search_terms_derived' AND table_name = 'search_term_data_validation_reports_v1')
-
-    ) ;;
-  description: "Updates for search_term_data_validation_reports when referenced tables are modified."
-  max_cache_age: "24 hours"
-}
\ No newline at end of file
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/search_private/datagroups/search_term_sanitization_job_metadata_daily_last_updated.datagroup.lkml /tmp/workspace/generated-lookml/search_private/datagroups/search_term_sanitization_job_metadata_daily_last_updated.datagroup.lkml
--- /tmp/workspace/looker-hub/search_private/datagroups/search_term_sanitization_job_metadata_daily_last_updated.datagroup.lkml	2026-02-11 22:51:49.026757773 +0000
+++ /tmp/workspace/generated-lookml/search_private/datagroups/search_term_sanitization_job_metadata_daily_last_updated.datagroup.lkml	1970-01-01 00:00:00.000000000 +0000
@@ -1,20 +0,0 @@
-# *Do not manually modify this file*
-
-# This file has been generated via https://github.com/mozilla/lookml-generator
-
-# Using a datagroup in an Explore: https://cloud.google.com/looker/docs/reference/param-explore-persist-with
-# Using a datagroup in a derived table: https://cloud.google.com/looker/docs/reference/param-view-datagroup-trigger
-
-datagroup: search_term_sanitization_job_metadata_daily_last_updated {
-  label: "search_term_sanitization_job_metadata_daily Last Updated"
-  sql_trigger: SELECT MAX(storage_last_modified_time)
-    FROM (
-        
-    SELECT MAX(storage_last_modified_time) AS storage_last_modified_time
-    FROM `moz-fx-data-shared-prod`.`region-us`.INFORMATION_SCHEMA.TABLE_STORAGE
-    WHERE (table_schema = 'search_terms_derived' AND table_name = 'sanitization_job_metadata_v2')
-
-    ) ;;
-  description: "Updates for search_term_sanitization_job_metadata_daily when referenced tables are modified."
-  max_cache_age: "24 hours"
-}
\ No newline at end of file
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/user_journey/views/events_daily.view.lkml /tmp/workspace/generated-lookml/user_journey/views/events_daily.view.lkml
--- /tmp/workspace/looker-hub/user_journey/views/events_daily.view.lkml	2026-02-11 22:51:49.030757787 +0000
+++ /tmp/workspace/generated-lookml/user_journey/views/events_daily.view.lkml	1970-01-01 00:00:00.000000000 +0000
@@ -1,71 +0,0 @@
-view: events_daily {
-  sql_table_name: `mozdata.messaging_system.events_daily`
-    ;;
-
-  dimension: addon_version {
-    type: string
-    sql: ${TABLE}.addon_version ;;
-  }
-
-  dimension: app_version {
-    type: string
-    sql: ${TABLE}.app_version ;;
-  }
-
-  dimension: city {
-    type: string
-    sql: ${TABLE}.city ;;
-  }
-
-  dimension: client_id {
-    type: string
-    sql: ${TABLE}.client_id ;;
-  }
-
-  dimension: country {
-    type: string
-    map_layer_name: countries
-    sql: ${TABLE}.country ;;
-  }
-
-  dimension: events {
-    type: string
-    sql: ${TABLE}.events ;;
-    hidden: yes
-  }
-
-  dimension: experiments {
-    hidden: yes
-    sql: ${TABLE}.experiments ;;
-  }
-
-  dimension: locale {
-    type: string
-    sql: ${TABLE}.locale ;;
-  }
-
-  dimension: normalized_channel {
-    type: string
-    sql: ${TABLE}.normalized_channel ;;
-  }
-
-  dimension: os {
-    type: string
-    sql: ${TABLE}.os ;;
-  }
-
-  dimension: sample_id {
-    type: number
-    sql: ${TABLE}.sample_id ;;
-  }
-
-  dimension: subdivision1 {
-    type: string
-    sql: ${TABLE}.subdivision1 ;;
-  }
-
-  dimension: submission_date {
-    type: date
-    sql: CAST(${TABLE}.submission_date AS TIMESTAMP) ;;
-  }
-}

Link to full diff

@github-actions
Copy link

Integration report for "this commit"

lookml.diff

Click to expand!
Only in /tmp/workspace/looker-hub/firefox_ios: dashboards
Only in /tmp/workspace/looker-hub/marketing: datagroups
Only in /tmp/workspace/looker-hub/search_private/datagroups: search_term_data_validation_reports_last_updated.datagroup.lkml
Only in /tmp/workspace/looker-hub/search_private/datagroups: search_term_sanitization_job_metadata_daily_last_updated.datagroup.lkml
Only in /tmp/workspace/looker-hub/: user_journey
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/ads/views/campaigns_monthly.view.lkml /tmp/workspace/generated-lookml/ads/views/campaigns_monthly.view.lkml
--- /tmp/workspace/looker-hub/ads/views/campaigns_monthly.view.lkml	2026-02-11 22:52:00.273074317 +0000
+++ /tmp/workspace/generated-lookml/ads/views/campaigns_monthly.view.lkml	2026-02-11 22:51:55.232031644 +0000
@@ -185,6 +185,21 @@
     type: sum
   }
 
+  measure: booked_rate {
+    sql: SAFE_DIVIDE(${booked_budget}, ${sold_quantity}) ;;
+    type: number
+  }
+
+  measure: cpc {
+    sql: SAFE_DIVIDE(${booked_budget}, ${budgeted_clicks}) ;;
+    type: number
+  }
+
+  measure: cpm {
+    sql: SAFE_DIVIDE(${booked_budget}, ${budgeted_impressions}) * 1000 ;;
+    type: number
+  }
+
   measure: total_delivered_revenue {
     sql: ${delivered_revenue} ;;
     type: sum
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/firefox_desktop/views/metric_definitions_firefox_desktop_active_users_view.view.lkml /tmp/workspace/generated-lookml/firefox_desktop/views/metric_definitions_firefox_desktop_active_users_view.view.lkml
--- /tmp/workspace/looker-hub/firefox_desktop/views/metric_definitions_firefox_desktop_active_users_view.view.lkml	2026-02-11 22:52:00.314074665 +0000
+++ /tmp/workspace/generated-lookml/firefox_desktop/views/metric_definitions_firefox_desktop_active_users_view.view.lkml	2026-02-11 22:51:55.747036002 +0000
@@ -8,6 +8,7 @@
   derived_table: {
     sql: SELECT
                 COUNTIF(is_dau) AS client_level_daily_active_users_v2,
+COALESCE(MIN(mozfun.bits28.days_since_seen(days_active_bits)), 30) < 3 AS active_in_last_3_days_legacy,
 
                 looker_base_fields_app_name,
 looker_base_fields_app_version,
@@ -215,6 +216,14 @@
     sql: ${TABLE}.client_level_daily_active_users_v2 ;;
   }
 
+  dimension: active_in_last_3_days_legacy {
+    group_label: "Metrics"
+    label: "3 Days Retention"
+    description: "Records whether a client submitted any pings (i.e. used Firefox) on any of the last 3 days. Uses legacy telemetry."
+    type: number
+    sql: ${TABLE}.active_in_last_3_days_legacy ;;
+  }
+
   dimension: app_name {
     sql: ${TABLE}.looker_base_fields_app_name ;;
     type: string
@@ -323,7 +332,7 @@
   }
 
   set: metrics {
-    fields: [client_level_daily_active_users_v2]
+    fields: [client_level_daily_active_users_v2, active_in_last_3_days_legacy]
   }
 
   parameter: aggregate_metrics_by {
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/firefox_desktop/views/metric_definitions_firefox_desktop_baseline_active_users_view.view.lkml /tmp/workspace/generated-lookml/firefox_desktop/views/metric_definitions_firefox_desktop_baseline_active_users_view.view.lkml
--- /tmp/workspace/looker-hub/firefox_desktop/views/metric_definitions_firefox_desktop_baseline_active_users_view.view.lkml	2026-02-11 22:52:00.314074665 +0000
+++ /tmp/workspace/generated-lookml/firefox_desktop/views/metric_definitions_firefox_desktop_baseline_active_users_view.view.lkml	2026-02-11 22:51:55.747036002 +0000
@@ -8,6 +8,7 @@
   derived_table: {
     sql: SELECT
                 COUNTIF(is_dau) AS client_level_daily_active_users_v2_glean,
+COALESCE(MIN(days_since_desktop_active), 30) < 3 AS active_in_last_3_days,
 
                 looker_base_fields_app_name,
 looker_base_fields_app_version,
@@ -215,6 +216,14 @@
     sql: ${TABLE}.client_level_daily_active_users_v2_glean ;;
   }
 
+  dimension: active_in_last_3_days {
+    group_label: "Metrics"
+    label: "3 Days Retention"
+    description: "Records whether a client submitted any pings (i.e. used Firefox) on any of the last 3 days."
+    type: number
+    sql: ${TABLE}.active_in_last_3_days ;;
+  }
+
   dimension: app_name {
     sql: ${TABLE}.looker_base_fields_app_name ;;
     type: string
@@ -323,7 +332,7 @@
   }
 
   set: metrics {
-    fields: [client_level_daily_active_users_v2_glean]
+    fields: [client_level_daily_active_users_v2_glean, active_in_last_3_days]
   }
 
   parameter: aggregate_metrics_by {
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/marketing/datagroups/firefox_for_families_forecasted_expectations_last_updated.datagroup.lkml /tmp/workspace/generated-lookml/marketing/datagroups/firefox_for_families_forecasted_expectations_last_updated.datagroup.lkml
--- /tmp/workspace/looker-hub/marketing/datagroups/firefox_for_families_forecasted_expectations_last_updated.datagroup.lkml	2026-02-11 22:52:00.340074885 +0000
+++ /tmp/workspace/generated-lookml/marketing/datagroups/firefox_for_families_forecasted_expectations_last_updated.datagroup.lkml	1970-01-01 00:00:00.000000000 +0000
@@ -1,20 +0,0 @@
-# *Do not manually modify this file*
-
-# This file has been generated via https://github.com/mozilla/lookml-generator
-
-# Using a datagroup in an Explore: https://cloud.google.com/looker/docs/reference/param-explore-persist-with
-# Using a datagroup in a derived table: https://cloud.google.com/looker/docs/reference/param-view-datagroup-trigger
-
-datagroup: firefox_for_families_forecasted_expectations_last_updated {
-  label: "firefox_for_families_forecasted_expectations Last Updated"
-  sql_trigger: SELECT MAX(storage_last_modified_time)
-    FROM (
-        
-    SELECT MAX(storage_last_modified_time) AS storage_last_modified_time
-    FROM `mozdata`.`region-us`.INFORMATION_SCHEMA.TABLE_STORAGE
-    WHERE (table_schema = 'analysis' AND table_name = 'marketing_firefox_for_families_forecasted_expectations')
-
-    ) ;;
-  description: "Updates for firefox_for_families_forecasted_expectations when referenced tables are modified."
-  max_cache_age: "24 hours"
-}
\ No newline at end of file
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/namespaces.yaml /tmp/workspace/generated-lookml/namespaces.yaml
--- /tmp/workspace/looker-hub/namespaces.yaml	2026-02-11 22:52:01.100081319 +0000
+++ /tmp/workspace/generated-lookml/namespaces.yaml	2026-02-11 22:52:01.029080718 +0000
@@ -288,6 +288,15 @@
         booked_impressions:
           sql: ${budgeted_impressions}
           type: sum
+        booked_rate:
+          sql: SAFE_DIVIDE(${booked_budget}, ${sold_quantity})
+          type: number
+        cpc:
+          sql: SAFE_DIVIDE(${booked_budget}, ${budgeted_clicks})
+          type: number
+        cpm:
+          sql: SAFE_DIVIDE(${booked_budget}, ${budgeted_impressions}) * 1000
+          type: number
         total_delivered_revenue:
           sql: ${delivered_revenue}
           type: sum
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/search_private/datagroups/search_term_data_validation_reports_last_updated.datagroup.lkml /tmp/workspace/generated-lookml/search_private/datagroups/search_term_data_validation_reports_last_updated.datagroup.lkml
--- /tmp/workspace/looker-hub/search_private/datagroups/search_term_data_validation_reports_last_updated.datagroup.lkml	2026-02-11 22:52:00.389075299 +0000
+++ /tmp/workspace/generated-lookml/search_private/datagroups/search_term_data_validation_reports_last_updated.datagroup.lkml	1970-01-01 00:00:00.000000000 +0000
@@ -1,20 +0,0 @@
-# *Do not manually modify this file*
-
-# This file has been generated via https://github.com/mozilla/lookml-generator
-
-# Using a datagroup in an Explore: https://cloud.google.com/looker/docs/reference/param-explore-persist-with
-# Using a datagroup in a derived table: https://cloud.google.com/looker/docs/reference/param-view-datagroup-trigger
-
-datagroup: search_term_data_validation_reports_last_updated {
-  label: "search_term_data_validation_reports Last Updated"
-  sql_trigger: SELECT MAX(storage_last_modified_time)
-    FROM (
-        
-    SELECT MAX(storage_last_modified_time) AS storage_last_modified_time
-    FROM `moz-fx-data-shared-prod`.`region-us`.INFORMATION_SCHEMA.TABLE_STORAGE
-    WHERE (table_schema = 'search_terms_derived' AND table_name = 'search_term_data_validation_reports_v1')
-
-    ) ;;
-  description: "Updates for search_term_data_validation_reports when referenced tables are modified."
-  max_cache_age: "24 hours"
-}
\ No newline at end of file
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/search_private/datagroups/search_term_sanitization_job_metadata_daily_last_updated.datagroup.lkml /tmp/workspace/generated-lookml/search_private/datagroups/search_term_sanitization_job_metadata_daily_last_updated.datagroup.lkml
--- /tmp/workspace/looker-hub/search_private/datagroups/search_term_sanitization_job_metadata_daily_last_updated.datagroup.lkml	2026-02-11 22:52:00.389075299 +0000
+++ /tmp/workspace/generated-lookml/search_private/datagroups/search_term_sanitization_job_metadata_daily_last_updated.datagroup.lkml	1970-01-01 00:00:00.000000000 +0000
@@ -1,20 +0,0 @@
-# *Do not manually modify this file*
-
-# This file has been generated via https://github.com/mozilla/lookml-generator
-
-# Using a datagroup in an Explore: https://cloud.google.com/looker/docs/reference/param-explore-persist-with
-# Using a datagroup in a derived table: https://cloud.google.com/looker/docs/reference/param-view-datagroup-trigger
-
-datagroup: search_term_sanitization_job_metadata_daily_last_updated {
-  label: "search_term_sanitization_job_metadata_daily Last Updated"
-  sql_trigger: SELECT MAX(storage_last_modified_time)
-    FROM (
-        
-    SELECT MAX(storage_last_modified_time) AS storage_last_modified_time
-    FROM `moz-fx-data-shared-prod`.`region-us`.INFORMATION_SCHEMA.TABLE_STORAGE
-    WHERE (table_schema = 'search_terms_derived' AND table_name = 'sanitization_job_metadata_v2')
-
-    ) ;;
-  description: "Updates for search_term_sanitization_job_metadata_daily when referenced tables are modified."
-  max_cache_age: "24 hours"
-}
\ No newline at end of file
diff -x '.*' -bur --no-dereference --new-file /tmp/workspace/looker-hub/user_journey/views/events_daily.view.lkml /tmp/workspace/generated-lookml/user_journey/views/events_daily.view.lkml
--- /tmp/workspace/looker-hub/user_journey/views/events_daily.view.lkml	2026-02-11 22:52:00.393075333 +0000
+++ /tmp/workspace/generated-lookml/user_journey/views/events_daily.view.lkml	1970-01-01 00:00:00.000000000 +0000
@@ -1,71 +0,0 @@
-view: events_daily {
-  sql_table_name: `mozdata.messaging_system.events_daily`
-    ;;
-
-  dimension: addon_version {
-    type: string
-    sql: ${TABLE}.addon_version ;;
-  }
-
-  dimension: app_version {
-    type: string
-    sql: ${TABLE}.app_version ;;
-  }
-
-  dimension: city {
-    type: string
-    sql: ${TABLE}.city ;;
-  }
-
-  dimension: client_id {
-    type: string
-    sql: ${TABLE}.client_id ;;
-  }
-
-  dimension: country {
-    type: string
-    map_layer_name: countries
-    sql: ${TABLE}.country ;;
-  }
-
-  dimension: events {
-    type: string
-    sql: ${TABLE}.events ;;
-    hidden: yes
-  }
-
-  dimension: experiments {
-    hidden: yes
-    sql: ${TABLE}.experiments ;;
-  }
-
-  dimension: locale {
-    type: string
-    sql: ${TABLE}.locale ;;
-  }
-
-  dimension: normalized_channel {
-    type: string
-    sql: ${TABLE}.normalized_channel ;;
-  }
-
-  dimension: os {
-    type: string
-    sql: ${TABLE}.os ;;
-  }
-
-  dimension: sample_id {
-    type: number
-    sql: ${TABLE}.sample_id ;;
-  }
-
-  dimension: subdivision1 {
-    type: string
-    sql: ${TABLE}.subdivision1 ;;
-  }
-
-  dimension: submission_date {
-    type: date
-    sql: CAST(${TABLE}.submission_date AS TIMESTAMP) ;;
-  }
-}

Link to full diff

@mozza-wins mozza-wins added this pull request to the merge queue Feb 11, 2026
Merged via the queue into main with commit ac85efe Feb 11, 2026
18 checks passed
@mozza-wins mozza-wins deleted the molly/cpc branch February 11, 2026 23:06
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.

2 participants