8000 Fix Quart integration for Quart 0.19.4 (#2516) · getsentry/sentry-python@5c17491 · GitHub
[go: up one dir, main page]

8000
Skip to content

Commit 5c17491

Browse files
authored
Fix Quart integration for Quart 0.19.4 (#2516)
* is_coroutine_function was removed from quart, taking from asyncio directly
1 parent b3ccf96 commit 5c17491

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

sentry_sdk/integrations/quart.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
from __future__ import absolute_import
22

3+
import asyncio
34
import inspect
45
import threading
56

@@ -45,7 +46,6 @@
4546
request_started,
4647
websocket_started,
4748
)
48-
from quart.utils import is_coroutine_function # type: ignore
4949
except ImportError:
5050
raise DidNotEnable("Quart is not installed")
5151
else:
@@ -113,7 +113,9 @@ def _sentry_route(*args, **kwargs):
113113
def decorator(old_func):
114114
# type: (Any) -> Any
115115

116-
if inspect.isfunction(old_func) and not is_coroutine_function(old_func):
116+
if inspect.isfunction(old_func) and not asyncio.iscoroutinefunction(
117+
old_func
118+
):
117119

118120
@wraps(old_func)
119121
def _sentry_func(*args, **kwargs):

0 commit comments

Comments
 (0)
0