stream-django icon indicating copy to clipboard operation
stream-django copied to clipboard

Create Reference function is inconsistent across different Stream clients

Open sksin28 opened this issue 6 years ago • 0 comments

The create_model_reference function creates a reference using model name. This is inconsistent as compared to other Stream clients.

For example, an activity added using stream-django results in actor reference being account.user:123 (based on model). In other Stream clients (such as stream-js or stream-python), the reference for user will be SU:123. This results in failure of data enrichment when using different Stream Clients.

Python- https://github.com/GetStream/stream-python/blob/35eec2162d2ef25411f4d76eeef078f98a2893a5/stream/users.py#L10 JS- https://github.com/GetStream/stream-js/blob/a22255b2e3b0da0b19f7e5b2597b1f253e3e4a1c/src/lib/user.js#L25

Our use case is using Django backend to add activities and use React Native as front end to render. But this results in issues related to enrichment.

sksin28 avatar Jan 24 '19 12:01 sksin28