mozilla-services / shavar

Tracking Protection update service for Firefox based on Safe Browsing protocol
Mozilla Public License 2.0
20 stars 10 forks source link

Update raven to sentry-sdk #149

Closed say-yawn closed 4 years ago

say-yawn commented 4 years ago

About this PR

Fix #150

Practical Tests

Setup a dev Sentry account and get a dsn

If you do not want to create one, you are welcome to ping me for the dsn I setup for testing Shavar. Set the environment variable SENTRY_DSN with the test dsn.

Check that the issues with error message Invalid RANGE "<TIMESTAMP> is properly grouped together

  1. Execute the following command: curl -d "mozstd-trackwhite-digest256;a:9-3;" "localhost:8080/downloads?appver=76.0&pver=2.2"ps
  2. Check that an issue with error message Invalid RANGE "9-3;" for mozstd-trackwhite-digest256 is logged on Sentry
  3. Execute the following command: curl -d "mozstd-trackwhite-digest256;a:1234567890-3;" "localhost:8080/downloads?appver=76.0&pver=2.2"
  4. Check that issue is also logged in Sentry by increasing the event count AND NOT by creating a new event
  5. If a new event is created, merge the two issues and try again with a different int value and check that event count is increased instead of creating a new event on Sentry.

Check that the issues with error message Invalid LISTINFO is properly grouped together

  1. Follow the previous test but use the following command: curl -d "mozstd-trackwhite-digest256;a:1234567890-3:;" "localhost:8080/downloads?appver=76.0&pver=2.2"
  2. Test again with different data payload such as: curl -d "mozstd-trackwhite-digest256;a:1234567890-3:a:123-543:;" "localhost:8080/downloads?appver=76.0&pver=2.2"

NOTE TO CKOLOS

@ckolos, when this is merged to staging following updates are needed on https://github.com/mozilla-services/cloudops-deployment/blob/master/projects/shavar/puppet/modules/shavar_server/templates/shavar.ini.erb: