Skip to content

Cannot make Sentry work with Google Cloud Function (python 3.9) #1666

Description

@NicolasMarlier

How do you use Sentry?

Sentry Saas (sentry.io)

Version

1.9.10

Steps to Reproduce

# main.py
import sentry_sdk
from sentry_sdk.integrations.gcp import GcpIntegration

sentry_sdk.init(
    dsn="https://***@***.ingest.sentry.io/***",
    integrations=[GcpIntegration()]
)

def main(request):
    return 1 / 0
# requirements.txt
sentry-sdk==1.9.10
# deploy.sh
gcloud functions deploy test_gcf_sentry \
--trigger-http \
--runtime=python39 \
--entry-point=main \
--memory=1GB \
--security-level=secure-always \
--region=europe-west1

Expected Result

Exception should be ingested in Sentry interface

Actual Result

Exception does not appear in Sentry interface

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions