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

Release snowplow media player/0.9.1 #83

Merged
merged 3 commits into from
Oct 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
snowplow-media-player 0.9.1 (2024-10-23)
---------------------------------------
## Summary
This patch release adds app_id as a new field in some of the derived tables and includes a bug fix related to user identification handling in ad_views.

## Features
- Introduced app_id field across some of the derived tables to improve application-level analytics

## Fix
- Optimized user_id aggregation, changed from GROUP BY to MAX(user_id) in queries in ad_view, because it could cause duplicates in an edge case.

## Upgrading
To upgrade, update the snowplow-media-player version in your `packages.yml` file. Please note:
- The new app_id field will be populated for new data points automatically
- Although this is a non-breaking change, historical data will require a [full refresh](https://docs.snowplow.io/docs/modeling-your-data/modeling-your-data-with-dbt/dbt-operation/full-or-partial-refreshes/) to include app_id values, if needed

snowplow-media-player 0.9.0 (2024-10-15)
---------------------------------------
## Summary
Expand Down
2 changes: 1 addition & 1 deletion dbt_project.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: 'snowplow_media_player'
version: '0.9.0'
version: '0.9.1'
config-version: 2

require-dbt-version: ['>=1.4.0', '<2.0.0']
Expand Down

Large diffs are not rendered by default.

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion integration_tests/dbt_project.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: 'snowplow_media_player_integration_tests'
version: '0.9.0'
version: '0.9.1'
config-version: 2

profile: 'integration_tests'
Expand Down
2 changes: 2 additions & 0 deletions models/base/scratch/base_scratch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ models:
description: '{{ doc("col_original_session_identifier") }}'
- name: session_identifier
description: '{{ doc("col_session_identifier") }}'
- name: app_id
description: '{{doc("col_app_id")}}'
- name: user_identifier
description: '{{ doc("col_user_identifier") }}'
- name: media_identifier
Expand Down
2 changes: 2 additions & 0 deletions models/media_ad_views/media_ad_views.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ models:
description: '{{ doc("col_user_id")}}'
- name: session_identifier
description: '{{ doc("col_session_identifier")}}'
- name: app_id
description: '{{doc("col_app_id")}}'
- name: play_id
description: '{{ doc("col_play_id")}}'
- name: ad_break_id
Expand Down
2 changes: 2 additions & 0 deletions models/media_ad_views/scratch/base_scratch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ models:
description: '{{ doc("col_user_id")}}'
- name: session_identifier
description: '{{ doc("col_session_identifier")}}'
- name: app_id
description: '{{doc("col_app_id")}}'
- name: domain_sessionid_array
description: '{{ doc("col_domain_sessionid_array") }}'
- name: play_id
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ events_this_run as (
,ev.media_identifier
,ev.user_identifier
,ev.session_identifier
,ev.user_id
,ev.app_id
,ev.play_id
,ev.media_ad_break__break_id as ad_break_id
,ev.media_ad__ad_id as ad_id
Expand All @@ -57,7 +57,8 @@ events_this_run as (
{%- endif -%}
{% endfor -%}
{%- endif %}


,max(ev.user_id) as user_id
,max(ev.media_label) as media_label
,max(ev.media_ad_break__name) as ad_break_name
,max(ev.media_ad_break__break_type) as ad_break_type
Expand All @@ -80,9 +81,9 @@ events_this_run as (
,{{ snowplow_utils.get_string_agg('original_session_identifier', 'ev', is_distinct=True) }} as domain_sessionid_array

from events_this_run as ev

{{ dbt_utils.group_by(n=9+(var('snowplow__ad_views_passthroughs', [])|length)) }}


)

select
Expand All @@ -93,6 +94,7 @@ select
,p.media_label
,p.user_identifier
,p.session_identifier
,p.app_id
,p.domain_sessionid_array
,p.user_id
,p.play_id
Expand Down
2 changes: 2 additions & 0 deletions models/media_base/media_base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ models:
description: '{{ doc("col_media_label") }}'
- name: session_identifier
description: '{{ doc("col_session_identifier") }}'
- name: app_id
description: '{{doc("col_app_id")}}'
- name: domain_sessionid_array
description: '{{ doc("col_domain_sessionid_array") }}'
- name: user_identifier
Expand Down
2 changes: 2 additions & 0 deletions models/media_base/scratch/base_scratch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ models:
description: '{{ doc("col_media_label") }}'
- name: session_identifier
description: '{{ doc("col_session_identifier") }}'
- name: app_id
description: '{{doc("col_app_id")}}'
- name: domain_sessionid_array
description: '{{ doc("col_domain_sessionid_array") }}'
- name: user_identifier
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ events_this_run as (
,i.player_id
,i.media_label
,i.session_identifier
,i.app_id
,i.user_identifier
,i.user_id
,i.platform
Expand Down Expand Up @@ -86,7 +87,7 @@ events_this_run as (

from events_this_run as i

{{ dbt_utils.group_by(n=17+(var('snowplow__base_passthroughs', [])|length)) }}
{{ dbt_utils.group_by(n=18+(var('snowplow__base_passthroughs', [])|length)) }}

)

Expand Down Expand Up @@ -206,6 +207,7 @@ select
d.player_id,
d.media_label,
d.session_identifier,
d.app_id,
d.domain_sessionid_array,
d.user_identifier,
d.user_id,
Expand Down
2 changes: 2 additions & 0 deletions models/media_plays/media_plays.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ models:
description: '{{ doc("col_media_label") }}'
- name: session_identifier
description: '{{ doc("col_session_identifier") }}'
- name: app_id
description: '{{doc("col_app_id")}}'
- name: domain_sessionid_array
description: '{{ doc("col_domain_sessionid_array") }}'
- name: user_identifier
Expand Down
Loading