Self-hosted sentry not receiving errors

I set up self-hosted sentry on AWS EC2 via docker.
It seems sentry is all working fine. I can create an organisation, user, project and so on.

I want to use this self-hosted sentry to connect with my multiple projects which are mostly python-django. I am trying to send some test errors but it seems my sentry is not receiving any of them.

>>> from sentry_sdk import capture_message
>>> capture_message('test')

On my local I ran the above code and it’s not showing on sentry.
I tried raven and it didn’t work either.