-
Notifications
You must be signed in to change notification settings - Fork 549
feat: Integration for Chalice #779
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I notice that some stuff here is duplicated from aws lambda integration, that should not be necessary
tox.ini
Outdated
@@ -69,8 +69,9 @@ envlist = | |||
{py2.7,py3.7,py3.8}-sqlalchemy-{1.2,1.3} | |||
|
|||
py3.7-spark | |||
|
|||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please undo this change
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you resolve the last issue about copypasted code from chalice, and add a __init__
in tests/integrations/chalice
that calls importorskip
(like in other integrations), otherwise the base testsuite does not pass (see travis CI)
sentry_sdk/integrations/chalice.py
Outdated
reraise(*exc_info) | ||
|
||
|
||
old_get_view_function_response = Chalice._get_view_function_response |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please don't have a global backup of the view function response, this will break if multiple libraries monkeypatch chalice
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
add this in setup_once().
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Regarding the tests, these fail because the parameters of the context '_max_runtime' arrive null, so this line
configured_time = ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
almost there, please fix the linting errors (run make lint
locally)
@untitaker you now have permissions to push to our fork. We're already using |
fwiw, Chalice does have a stub file for type hinting, It shouldn't be necessary to ignore the import to resolve this error: https://travis-ci.com/github/getsentry/sentry-python/jobs/382832642#L249-L251 |
Yes but we can't install all optional dependencies at once when type
checking. Also we should not rely on those stubs as they are wrong (eg
flask, celery) or change between versions.
Technically we would have to typecheck for each entry in the cross product
of all versions of frameworks we support.
…On Wed, Sep 9, 2020 at 8:24 PM Matin Tamizi ***@***.***> wrote:
fwiw, Chalice *does* have a stub file for type hinting, app.pyi
<https://github.com/aws/chalice/blob/master/chalice/app.pyi>, and
includes py.typed
<https://github.com/aws/chalice/blob/master/chalice/py.typed>.
It shouldn't be necessary to ignore the import to resolve this error:
https://travis-ci.com/github/getsentry/sentry-python/jobs/382832642#L249-L251
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#779 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAGMPRPE25BU3WHBK476NGLSE7B7JANCNFSM4P2ODGZA>
.
|
This is a proposal for the integration of Chalice in Sentry