[fedmsg] Update encoding patch.

Ralph Bean ralph at fedoraproject.org
Thu Jul 24 17:26:13 UTC 2014


commit 88c7e845d9324ef5cbb46d013bb3edc37992b392
Author: Ralph Bean <rbean at redhat.com>
Date:   Thu Jul 24 13:26:05 2014 -0400

    Update encoding patch.

 fedmsg-encoding.patch |   22 ++++++++++++++++------
 fedmsg.spec           |    5 ++++-
 2 files changed, 20 insertions(+), 7 deletions(-)
---
diff --git a/fedmsg-encoding.patch b/fedmsg-encoding.patch
index 0c07bdb..43eb563 100644
--- a/fedmsg-encoding.patch
+++ b/fedmsg-encoding.patch
@@ -1,15 +1,15 @@
-From 78942e0063dfe42135ad96ffab5eedf2447dfde5 Mon Sep 17 00:00:00 2001
+From 1ab33b10752e869ddf9bc4be14fb4f3235718536 Mon Sep 17 00:00:00 2001
 From: Ralph Bean <rbean at redhat.com>
 Date: Thu, 24 Jul 2014 12:18:29 -0400
-Subject: [PATCH 2/2] Use fedmsg.encoding here so we can encode
+Subject: [PATCH] Use fedmsg.encoding here so we can encode
  moksha.hub.zeromq.ZMQMessage objects.
 
 ---
- fedmsg/consumers/__init__.py | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
+ fedmsg/consumers/__init__.py | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
 
 diff --git a/fedmsg/consumers/__init__.py b/fedmsg/consumers/__init__.py
-index 3e9edcd..a1b92b5 100644
+index 3e9edcd..562abd6 100644
 --- a/fedmsg/consumers/__init__.py
 +++ b/fedmsg/consumers/__init__.py
 @@ -30,6 +30,7 @@ import time
@@ -20,7 +20,17 @@ index 3e9edcd..a1b92b5 100644
  from fedmsg.replay import check_for_replay
  
  
-@@ -248,7 +249,7 @@ class FedmsgConsumer(moksha.hub.api.consumer.Consumer):
+@@ -161,6 +162,9 @@ class FedmsgConsumer(moksha.hub.api.consumer.Consumer):
+             return
+ 
+         last = data['message']['body']
++        if isinstance(last, basestring):
++            last = json.loads(last)
++
+         then = last['timestamp']
+         now = int(time.time())
+ 
+@@ -248,7 +252,7 @@ class FedmsgConsumer(moksha.hub.api.consumer.Consumer):
          if self.status_filename:
              with self.status_lock:
                  with open(self.status_filename, 'w') as f:
diff --git a/fedmsg.spec b/fedmsg.spec
index fd1927d..1fdeae0 100644
--- a/fedmsg.spec
+++ b/fedmsg.spec
@@ -5,7 +5,7 @@
 
 Name:           fedmsg
 Version:        0.9.1
-Release:        2%{?dist}
+Release:        3%{?dist}
 Summary:        Tools for Fedora Infrastructure real-time messaging
 Group:          Applications/Internet
 License:        LGPLv2+
@@ -297,6 +297,9 @@ fi
 %config(noreplace) %{_sysconfdir}/fedmsg.d/gateway.py*
 
 %changelog
+* Thu Jul 24 2014 Ralph Bean <rbean at redhat.com> - 0.9.1-3
+- Update patch.
+
 * Thu Jul 24 2014 Ralph Bean <rbean at redhat.com> - 0.9.1-2
 - Bring in two patches from upstream to fix issues on el7.
 


More information about the scm-commits mailing list