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

feat: add UserSignUpMeta model #4113

Closed
wants to merge 5 commits into from

Conversation

matthewelwell
Copy link
Contributor

Thanks for submitting a PR! Please check the boxes below:

  • I have run pre-commit to check linting
  • I have added information to docs/ if required so people know about the feature!
  • I have filled in the "Changes" section below?
  • I have filled in the "How did you test this code" section below?
  • I have used a Conventional Commit title for this Pull Request

Changes

As part of a request from the marketing team we need to capture, and send to Hubspot, information about how the user arrived at Flagsmith when a new user signs up. For example, when clicking on a google ad, the website receives a query string that the FE then adds to a cookie.

This PR adds logic to retrieve the data from that cookie and store it in a new model which is then (TODO) used to send the correct attribution data to Hubspot.

How did you test this code?

TODO

Copy link

vercel bot commented Jun 5, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

3 Ignored Deployments
Name Status Preview Comments Updated (UTC)
docs ⬜️ Ignored (Inspect) Visit Preview Jun 6, 2024 10:43am
flagsmith-frontend-preview ⬜️ Ignored (Inspect) Visit Preview Jun 6, 2024 10:43am
flagsmith-frontend-staging ⬜️ Ignored (Inspect) Visit Preview Jun 6, 2024 10:43am

@matthewelwell matthewelwell changed the title Add UserSignUpMeta model feat: add UserSignUpMeta model Jun 5, 2024
@github-actions github-actions bot added the api Issue related to the REST API label Jun 5, 2024
Copy link
Contributor

github-actions bot commented Jun 5, 2024

Uffizzi Ephemeral Environment deployment-52680

☁️ https://app.uffizzi.com/github.com/Flagsmith/flagsmith/pull/4113

📄 View Application Logs etc.

What is Uffizzi? Learn more!

Copy link
Contributor

@zachaysan zachaysan left a comment

Choose a reason for hiding this comment

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

Overall approach looks great. I'd have marked this PR as approved but according to the PR description there are testing and other TODOs that need to land first.

('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('created_at', models.DateTimeField(auto_now_add=True)),
('updated_at', models.DateTimeField(auto_now=True)),
('json_meta', models.TextField()),
Copy link
Contributor

Choose a reason for hiding this comment

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

It's too bad we can't use a json field here due to other databases

@github-actions github-actions bot added feature New feature or request and removed feature New feature or request labels Jun 6, 2024
Copy link

codecov bot commented Jun 6, 2024

Codecov Report

Attention: Patch coverage is 95.58824% with 3 lines in your changes missing coverage. Please review.

Project coverage is 96.44%. Comparing base (1852d94) to head (c784a9d).
Report is 11 commits behind head on main.

Files Patch % Lines
api/custom_auth/serializers.py 76.92% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4113      +/-   ##
==========================================
- Coverage   96.44%   96.44%   -0.01%     
==========================================
  Files        1149     1150       +1     
  Lines       37596    37669      +73     
==========================================
+ Hits        36259    36329      +70     
- Misses       1337     1340       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@matthewelwell
Copy link
Contributor Author

Closing as this was a failed attempt at getting around Hubspots uselessness. We will need to develop a custom form in hubspot and use that to create the contacts instead of using their native APIs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Issue related to the REST API feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants