Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Remove force_binary

  • Loading branch information...
commit 9b9795628074faa1007c052c829319fe18ae4649 1 parent a42dd90
@gmr gmr authored
Showing with 4 additions and 7 deletions.
  1. +4 −7 pika/connection.py
View
11 pika/connection.py
@@ -651,7 +651,7 @@ def add_timeout(self, deadline, callback_method):
"""
raise NotImplementedError
- def channel(self, on_open_callback, channel_number=None, force_binary=False):
+ def channel(self, on_open_callback, channel_number=None):
"""Create a new channel with the next available channel number or pass
in a channel number to use. Must be non-zero if you would like to
specify but it is recommended that you let Pika manage the channel
@@ -660,15 +660,13 @@ def channel(self, on_open_callback, channel_number=None, force_binary=False):
:param method on_open_callback: The callback when the channel is opened
:param int channel_number: The channel number to use, defaults to the
next available.
- :param bool force_binary: Prevents channel from autodetecting unicode
:rtype: pika.channel.Channel
"""
if not channel_number:
channel_number = self._next_channel_number()
self._channels[channel_number] = self._create_channel(channel_number,
- on_open_callback,
- force_binary)
+ on_open_callback)
self._add_channel_callbacks(channel_number)
self._channels[channel_number].open()
return self._channels[channel_number]
@@ -937,16 +935,15 @@ def _connect(self):
warnings.warn('This method is deprecated, use Connection.connect',
DeprecationWarning)
- def _create_channel(self, channel_number, on_open_callback, force_binary):
+ def _create_channel(self, channel_number, on_open_callback):
"""Create a new channel using the specified channel number and calling
back the method specified by on_open_callback
:param int channel_number: The channel number to use
:param method on_open_callback: The callback when the channel is opened
- :param bool force_binary: Prevents channel from autodetecting unicode
"""
- return channel.Channel(self, channel_number, on_open_callback, force_binary)
+ return channel.Channel(self, channel_number, on_open_callback)
def _create_heartbeat_checker(self):
"""Create a heartbeat checker instance if there is a heartbeat interval
Please sign in to comment.
Something went wrong with that request. Please try again.