(identity, all_feature_states, trait_models=None)
| 37 | |
| 38 | |
| 39 | def identify_integrations(identity, all_feature_states, trait_models=None): # type: ignore[no-untyped-def] |
| 40 | for integration in IDENTITY_INTEGRATIONS: |
| 41 | config = getattr(identity.environment, integration.get("relation_name"), None) # type: ignore[arg-type] |
| 42 | if config and not config.deleted: |
| 43 | wrapper = integration.get("wrapper") |
| 44 | wrapper_instance = wrapper(config) # type: ignore[call-arg,misc] |
| 45 | user_data = wrapper_instance.generate_user_data( |
| 46 | identity=identity, |
| 47 | feature_states=all_feature_states, |
| 48 | trait_models=trait_models, |
| 49 | ) |
| 50 | wrapper_instance.identify_user_async(data=user_data) |
searching dependent graphs…