Skip to content

Instantly share code, notes, and snippets.

@ethanmiller
Created May 11, 2011 15:58
Show Gist options
  • Save ethanmiller/966741 to your computer and use it in GitHub Desktop.
Save ethanmiller/966741 to your computer and use it in GitHub Desktop.
django-sentry urlopen args
diff --git a/sentry/client/base.py b/sentry/client/base.py
index 3c5fad3..e237c86 100644
--- a/sentry/client/base.py
+++ b/sentry/client/base.py
@@ -149,7 +149,12 @@ class SentryClient(object):
"Sends the message to the server."
if settings.REMOTE_URL:
for url in settings.REMOTE_URL:
- message = base64.b64encode(simplejson.dumps(kwargs).encode('zlib'))
+ data = base64.b64encode(simplejson.dumps(kwargs).encode('zlib'))
+ import urllib
+ message = urllib.urlencode({
+ 'data' : data,
+ 'format' : 'json',
+ 'key' : conf.KEY})
timestamp = time.time()
signature = get_signature(message, timestamp)
headers={
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment