Page MenuHomeSoftware Heritage

Add sentry integration to swh-deposit
ClosedPublic

Authored by vlorentz on Dec 11 2019, 3:47 PM.

Details

Reviewers
ardumont
Group Reviewers
Reviewers

Diff Detail

Repository
rDDEP Push deposit
Branch
sentry
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 9851
Build 14539: tox-on-jenkinsJenkins
Build 14538: arc lint + arc unit

Event Timeline

vlorentz created this revision.Dec 11 2019, 3:47 PM
ardumont added inline comments.
swh/deposit/tests/test_gunicorn_config.py
9

the more the merrier ;)

(You've got 2 copyright headers)

vlorentz updated this revision to Diff 8617.Dec 12 2019, 1:24 PM

remove extra copyright header

vlorentz marked an inline comment as done.Dec 12 2019, 1:24 PM

I've no idea what this allows to do.

Can you please enlighten me?

swh/deposit/tests/test_gunicorn_config.py
14

jsyk, pytest-mock (extra dep though, fixture is named mocker) has started to be used as well [1].
Maybe this could be set within a fixture using pytest-mock.

[1] https://forge.softwareheritage.org/source/swh-loader-core/browse/master/swh/loader/package/npm/tests/test_tasks.py$7-8

25

jsyk, there is the pytest's monkeypatch fixture we started using consistently now [1]

[1] https://forge.softwareheritage.org/source/swh-loader-core/browse/master/conftest.py$44

I've no idea what this allows to do.

Can you please enlighten me?

see https://forge.softwareheritage.org/D2418#change-CNJs5ITmJ36y

vlorentz updated this revision to Diff 8758.Dec 17 2019, 6:53 PM

change branch name

ardumont accepted this revision.Dec 17 2019, 7:25 PM

I stil don't see much what that is, even following the other diff.
i had a glimpse of the sentry ui and i quite like it

so ok, i guess.

This revision is now accepted and ready to land.Dec 17 2019, 7:25 PM

It defines a function that gets called by gunicorn workers when they start. This function calls sentry_sdk.init() so it hooks itself in exception handlers and other places