Skip to content

Commit 1982a1f

Browse files
committed
Add connection error to ignore list for sentry
1 parent 6c0b4cb commit 1982a1f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

backend/exifoo/api.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
from contextlib import asynccontextmanager
44

55
import sentry_sdk
6+
import httpx
67
from fastapi import FastAPI
78
from fastapi.middleware.cors import CORSMiddleware
89
from fastapi.responses import JSONResponse
@@ -25,6 +26,7 @@
2526

2627

2728
sentry_sdk.init(
29+
ignore_errors=[httpx.ConnectError, ConnectionError],
2830
dsn=os.getenv("SENTRY_DSN"),
2931
# Set traces_sample_rate to 1.0 to capture 100%
3032
# of transactions for tracing.

0 commit comments

Comments
 (0)