Skip to content

Conversation

asajjad2
Copy link
Contributor

@asajjad2 asajjad2 commented Oct 3, 2025

What are the relevant tickets?

#8421

Description (What does it do?)

This PR updates our bulk HubSpot contact sync to reflect our SCIM-based provisioning. Historically we filtered bulk “create --users” by requiring a social_auth record, which made sense when most real users logged in interactively. Since SCIM now provisions many legitimate users without social_auth, those users were excluded from bulk syncs and not synced to hubspot.

We now select users with is_active=True, a valid email, and global_id present, replacing the social_auth check. This aligns bulk backfills with registration and --ids flows and ensures SCIM-provisioned users are included.

How can this be tested?

  1. Run python manage.py sync_db_to_hubspot create --users and verify:
    • New contacts are created for active users with valid emails and global_id (no social auth object needed).
    • hubspot_sync_datetime is set on success.

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.

1 participant