getsentry / raven-python

Raven is the legacy Python client for Sentry (getsentry.com) — replaced by sentry-python
https://sentry.io
BSD 3-Clause "New" or "Revised" License
1.68k stars 657 forks source link

JSON data getting very escaped #995

Open tomhamiltonstubber opened 7 years ago

tomhamiltonstubber commented 7 years ago

We're getting JSON data like:

{
  'contractors': [{
    'id': 456789,
    'name': 'John Smith'
  }],
  'date': '2017-1-1T00:00:00Z',
  'description': 'GCSE Exam',
  'recipients': [{
    'client_name': 'Brain Johnson',
    'id': 123456,
    'name': 'Cara Johnson'}],
  'reference': [12345, 56789],
}

coming through to Sentry like:

[{
  "'items'": [{
    "'date'": "'\\'\"u\\\\\\'datetime.datetime(2017, 1, 1, 0, 0, tzinfo=<UTC>)\\\\\\'\"\\''",
    "'contractors'": "'\\'\\\\\\'[{u\"\\\\\\\\\\\\\\'\\\\\\\\\\\\\\'name\\\\\\\\\\\\\\'\\\\\\\\\\\\\\'\": u\"\\\\\\\\\\\\\\'\\\\\\\\\\\\\\'John Smith\\\\\\\\\\\\\\'\\\\\\\\\\\\\\'\", u\"\\\\\\\\\\\\\\'\\\\\\\\\\\\\\'id\\\\\\\\\\\\\\'\\\\\\\\\\\\\\'\": u\"\\\\\\\\\\\\\\'456789\\\\\\\\\\\\\\'\"}]\\\\\\'\\''",
    "'recipients'": "'\\'\\\\\\'[{u\"\\\\\\\\\\\\\\'\\\\\\\\\\\\\\'name\\\\\\\\\\\\\\'\\\\\\\\\\\\\\'\": u\"\\\\\\\\\\\\\\'\\\\\\\\\\\\\\'Brain Johnson\\\\\\\\\\\\\\'\\\\\\\\\\\\\\'\", u\"\\\\\\\\\\\\\\'\\\\\\\\\\\\\\'...",
    "'description'": "'\\'\\\\\\'u\"\\\\\\\\\\\\\\'GCSE Exam\\\\\\\\\\\\\\'\"\\\\\\'\\''",
    "'reference'": "'\"\\'[12345, 56789]\\'\"'"
  }]
}]

Let me know if you need any more details.

rowanseymour commented 6 years ago

Same here.. if I call

client.captureMessage("test message", extra={"a": {"b": ["c"]}})

my Sentry report looks like:

captura de pantalla 2018-05-10 a la s 09 43 47