BitBucket identity integration

Hi!

I’m trying to integrate my BitBucket account, but I’m getting an internal server error after being redirect back from Atlassian to my Sentry installation.

Is there a documentation I can check? Something else I need to install?

I’ve set the x-defaults.environment.BITBUCKET_CONSUMER_KEY and the x-defaults.environment.BITBUCKET_CONSUMER_SECRET on docker-compose.yaml. And added this to sentry.conf.py:

if 'BITBUCKET_CONSUMER_KEY' in os.environ:
    BITBUCKET_CONSUMER_KEY = env('BITBUCKET_CONSUMER_KEY')
    BITBUCKET_CONSUMER_SECRET = env('BITBUCKET_CONSUMER_SECRET')

Am I doing something wrong?