AttributeError: 'Scope' object has no attribute 'set_user'

Hi guys, i am a noob student trying to figure out how to use sentry. Actually it s pretty easy besides the fact that i am getting a AttributeError: ‘Scope’ object has no attribute ‘set_user’
when attempting to apply the

with configure_scope() as scope:
scope.set_users({“email: " blablabla.com”})

method.

Any tips would be helpful or pointers to solve the question

1 Like

Hi,

In Python it’s just a property you have to set:

with configure_scope() as scope:
    scope.user = {"email": "foo@blablabla.com"}

I just created a fix for the docs: https://github.com/getsentry/sentry-docs/pull/372

Thanks pal