-
Notifications
You must be signed in to change notification settings - Fork 89
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
feat: improve Sentry logging #3086
Conversation
0040602
to
056d103
Compare
f90d792
to
71dc1c7
Compare
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.
sentry.pip disappeared in #2992 somehow.
Thank you! We can probably test it on our dev envs :)
Don't forget to add a changelog entry ;)
udata/sentry.py
Outdated
traces_sample_rate=sentry_sample_rate, | ||
# Experimental profiling | ||
_experiments={ | ||
'profiles_sample_rate': sentry_sample_rate, | ||
}, |
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 would say that we should log 100% of errors by default for now (and make it configurable) but only a portion of profiling indeed. Ignore this comment if this is what it does ;)
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.
Yes after some inquiry, this is only for perf so let's keep as it is.
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.
But: Sentry sample rate has been changed as an app config.
a74f591
to
65bf159
Compare
Indeed. Added a changelog entry. |
63aac74
to
f5d6359
Compare
f5d6359
to
b32101f
Compare
@@ -279,7 +281,7 @@ uritools==4.0.3 | |||
# via urlextract | |||
urlextract==0.14.0 | |||
# via -r requirements/install.in | |||
urllib3==1.25.11 | |||
urllib3==1.26.19 |
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 think you should compute pip-compile on all impacted dep files.
It should have gotten triggered by the pip-tool pre-commit hook.
I've updated its version in 5982e2a.
…ncies incompabilities
0c27a90
to
6afe805
Compare
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.
LGTM, nice work 👍
Closes datagouv/data.gouv.fr#1389:
SITE_ID
) and release info to SentrySENTRY_SAMPLE_RATE
Note:
This PR adds
sentry-sdk[flask]
as an install dependency. I'm not sure why it wasn't there before - let me know if this is a mistake!So since
sentry-sdk[flask]
depends onurllib3
andurllib3
depends onrequests
which were incompatible with newer versions ofsentry-sdk
, both pinned versions ofurllib3
andrequests
have been updated in this PR.