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

Add GA session_id to stub attribution data (Fixes #12355) #12794

Merged
merged 5 commits into from
Mar 7, 2023

Conversation

alexgibson
Copy link
Member

@alexgibson alexgibson commented Feb 23, 2023

One-line summary

  • Adds a new session_id parameter to stub attribution that contains the GA session ID.
  • Renames visit_id to client_id as to be more technically correct / less confusing.

Significant changes and points to review

This change has already been tested end-to-end by QA against demo3, so code-level review should be all that's really required here. If you would like to manually test things still, there are testing steps below for the bedrock side of things.

Issue / Bugzilla link

#12355

Testing

  1. On a Windows machine, open https://www-demo3.allizom.org/en-US/
  2. Inspect cookies using dev tools and look for a cookie called moz-stub-attribution-code. The value should be a base64 string.
  3. Decode the cookie value and verify it has both a client_id and session_id parameter.

@willdurand
Copy link
Member

Hey, so this PR has been verified by QA and we update the stub service on production. Alex, you can go ahead with this PR now, thank you!

@alexgibson alexgibson added P2 Second level priority - Should have Needs Review Awaiting code review Review: XS Code review time: up to 30min labels Mar 3, 2023
@alexgibson alexgibson marked this pull request as ready for review March 3, 2023 09:28
Copy link
Contributor

@stephaniehobson stephaniehobson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few lingering references to visit ID but nothing blocking.

tests/unit/spec/base/stub-attribution.js Outdated Show resolved Hide resolved
tests/unit/spec/base/stub-attribution.js Show resolved Hide resolved
tests/unit/spec/base/stub-attribution.js Outdated Show resolved Hide resolved
alexgibson and others added 3 commits March 7, 2023 09:22
Co-authored-by: Stephanie Hobson <sjhobson@gmail.com>
Co-authored-by: Stephanie Hobson <sjhobson@gmail.com>
@codecov
Copy link

codecov bot commented Mar 7, 2023

Codecov Report

Patch coverage has no change and project coverage change: +0.12 🎉

Comparison is base (e868d1e) 76.75% compared to head (7f5b617) 76.88%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #12794      +/-   ##
==========================================
+ Coverage   76.75%   76.88%   +0.12%     
==========================================
  Files         144      144              
  Lines        7674     7669       -5     
==========================================
+ Hits         5890     5896       +6     
+ Misses       1784     1773      -11     
Impacted Files Coverage Δ
bedrock/firefox/views.py 91.55% <ø> (ø)
bedrock/mozorg/templatetags/misc.py 100.00% <0.00%> (+2.66%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@alexgibson alexgibson merged commit abad2db into mozilla:main Mar 7, 2023
@alexgibson alexgibson deleted the ga-visit-id branch March 7, 2023 09:39
@stephaniehobson stephaniehobson removed the Needs Review Awaiting code review label Jul 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P2 Second level priority - Should have Review: XS Code review time: up to 30min
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants