diff --git a/coolamqp/attaches/agroup.py b/coolamqp/attaches/agroup.py index 2e3f3440b7939ef14788b8fdbfcaad24fe889f2f..3ccc032a85ed6b64e11e12e7218d72380ff4e775 100644 --- a/coolamqp/attaches/agroup.py +++ b/coolamqp/attaches/agroup.py @@ -65,10 +65,8 @@ class AttacheGroup(Attache): for attache in self.attaches: if not attache.cancelled: - print('Attaching', attache) attache.attach(connection) else: - print('lol wut') raise Exception diff --git a/coolamqp/attaches/channeler.py b/coolamqp/attaches/channeler.py index a892b751dac87184c7eeaada419bf44238cd6732..74fb96d10619bf155c43247a985e49c3da8a1b17 100644 --- a/coolamqp/attaches/channeler.py +++ b/coolamqp/attaches/channeler.py @@ -138,7 +138,6 @@ class Channeler(Attache): self.connection = None self.channel_id = None - print(self, 'pwned with', payload) if isinstance(payload, ChannelClose): logger.debug('Channel closed: %s %s', payload.reply_code, payload.reply_text) diff --git a/coolamqp/attaches/publisher.py b/coolamqp/attaches/publisher.py index 147df0fc5705a95d3700f42fafbc1da8879bb7d1..5266e2ec09a820145265cffffce133d62f9ff28c 100644 --- a/coolamqp/attaches/publisher.py +++ b/coolamqp/attaches/publisher.py @@ -98,7 +98,6 @@ class Publisher(Channeler, Synchronized): @Synchronized.synchronized def on_fail(self): self.state = ST_OFFLINE - print('Publisher is FAILED') def _pub(self, message, exchange_name, routing_key): """ @@ -156,8 +155,6 @@ class Publisher(Channeler, Synchronized): """ assert self.mode == Publisher.MODE_CNPUB - print('Got %s with dt=%s' % (payload, payload.delivery_tag)) - if isinstance(payload, BasicAck): self.tagger.ack(payload.delivery_tag, payload.multiple) elif isinstance(payload, BasicNack): diff --git a/coolamqp/attaches/utils.py b/coolamqp/attaches/utils.py index 9989ca77f47edc846386c44312849dbd9348372c..74d0aaa9a06e3a19ec8885dc3a92847fc334ece7 100644 --- a/coolamqp/attaches/utils.py +++ b/coolamqp/attaches/utils.py @@ -155,8 +155,6 @@ class AtomicTagger(object): # Oh, I know the range! stop = len(self.tags) - print('Range computed of %s:%s' % (start, stop)) - items = self.tags[start:stop] del self.tags[start:stop] diff --git a/coolamqp/framing/compilation/content_property.py b/coolamqp/framing/compilation/content_property.py index 73732e443079dd9fa83f59b1d7679ea3f2ef1c36..9551695245acaa8f62871a3f89b5a08e67fe1457 100644 --- a/coolamqp/framing/compilation/content_property.py +++ b/coolamqp/framing/compilation/content_property.py @@ -89,7 +89,7 @@ def _compile_particular_content_property_list_class(zpf, fields): mod.append(u'\n def write_to(self, buf):\n') mod.append(u' buf.write(') repred_zpf = repr(zpf) - if not zpf.startswith('b'): + if not zpf.startswith(b'b'): repred_zpf = 'b' + repred_zpf mod.append(repred_zpf) mod.append(u')\n') diff --git a/coolamqp/uplink/connection/connection.py b/coolamqp/uplink/connection/connection.py index 426804257177c6cb953ab37af963d96a4af7848f..98aa3e74df4c79f95ce7788fda0741313ada87e7 100644 --- a/coolamqp/uplink/connection/connection.py +++ b/coolamqp/uplink/connection/connection.py @@ -84,7 +84,6 @@ class Connection(object): def on_connected(self): """Called by handshaker upon reception of final connection.open-ok""" - print(self.free_channels) self.state = ST_ONLINE while len(self.callables_on_connected) > 0: @@ -104,7 +103,6 @@ class Connection(object): try: sock.connect((self.node_definition.host, self.node_definition.port)) except socket.error as e: - print(e) time.sleep(0.5) # Connection refused? Very bad things? else: break @@ -170,11 +168,9 @@ class Connection(object): Called by ListenerThread. """ - print('We are GOING DOOOWN') self.on_fail() # it does not make sense to prolong the agony if isinstance(payload, ConnectionClose): - print(payload.reply_code, payload.reply_text) self.send([AMQPMethodFrame(0, ConnectionCloseOk())]) elif isinstance(payload, ConnectionCloseOk): self.send(None) @@ -206,11 +202,6 @@ class Connection(object): :param frame: AMQPFrame that was received """ - if isinstance(frame, AMQPMethodFrame): # temporary, for debugging - print('RECEIVED', frame.payload.NAME) - else: - print('RECEIVED ', frame) - watch_handled = False # True if ANY watch handled this # ==================== process per-channel watches @@ -249,7 +240,7 @@ class Connection(object): self.any_watches.append(watch) if not watch_handled: - logger.critical('Unhandled frame %s', frame) + logger.warn('Unhandled frame %s', frame) def watchdog(self, delay, callback): """ diff --git a/coolamqp/uplink/handshake.py b/coolamqp/uplink/handshake.py index 4c8bf1e6fdfdad717af656fe0b6087387dbc4004..18edb52b54751c4f08f43783b7f138b712d4aea6 100644 --- a/coolamqp/uplink/handshake.py +++ b/coolamqp/uplink/handshake.py @@ -94,7 +94,6 @@ class Handshaker(object): def on_connection_tune(self, payload): self.connection.frame_max = payload.frame_max self.connection.heartbeat = min(payload.heartbeat, self.heartbeat) - print('Selected', payload.channel_max, 'channels') for channel in six.moves.xrange(1, (65535 if payload.channel_max == 0 else payload.channel_max)+1): self.connection.free_channels.append(channel) diff --git a/coolamqp/uplink/listener/socket.py b/coolamqp/uplink/listener/socket.py index ffd56372ee8eddb44ad45b938c227060f819de42..e2fd2a8b83e90556cb4c84e49111dca827f828e3 100644 --- a/coolamqp/uplink/listener/socket.py +++ b/coolamqp/uplink/listener/socket.py @@ -133,7 +133,6 @@ class BaseSocket(object): if len(self.priority_queue) > 0: # We can send a priority pack - print('Deploying priority data') self.data_to_send.appendleft(self.priority_queue.popleft()) def fileno(self):