Commits

Jason R. Coombs committed e4cbd4d

Removed deprecated arguments to ServerConnection.connect.

Comments (0)

Files changed (3)

+4.0
+===
+
+* Removed deprecated arguments to ServerConnection.connect. See notes on the
+  3.3 release on how to use the connect_factory parameter if your application
+  requires ssl, ipv6, or other connection customization.
+
 3.6.1
 =====
 
     # save the method args to allow for easier reconnection.
     @irc_functools.save_method_args
     def connect(self, server, port, nickname, password=None, username=None,
-            ircname=None, localaddress="", localport=0, ssl=False, ipv6=False,
-            connect_factory=connection.Factory()):
+            ircname=None, connect_factory=connection.Factory()):
         """Connect/reconnect to a server.
 
         Arguments:
             connect_factory -- A callable that takes the server address and
                 returns a connection (with a socket interface).
 
-        Deprecated Arguments:
-            localaddress -- Bind the connection to a specific local IP address.
-            localport -- Bind the connection to a specific local port.
-            ssl -- Enable support for ssl.
-            ipv6 -- Enable support for ipv6.
-
         This function can be called to reconnect a closed connection.
 
         Returns the ServerConnection object.
         log.debug("connect(server=%r, port=%r, nickname=%r, ...)", server,
             port, nickname)
 
-        if localaddress or localport or ssl or ipv6:
-            warnings.warn("localaddress, localport, ssl, and ipv6 parameters "
-                "are deprecated. Use connect_factory instead.",
-                DeprecationWarning)
-            connect_factory.from_legacy_params(localaddress, localport, ssl,
-                ipv6)
-
         if self.connected:
             self.disconnect("Changing servers")
 

irc/tests/test_client.py

 	server.connect('foo', 6667, 'bestnick')
 	with pytest.raises(ValueError):
 		server.privmsg('#best-channel', 'You are great\nSo are you')
-
-@mock.patch('irc.connection.socket')
-def test_connect_with_legacy_params(socket_mod):
-	server = irc.client.IRC().server()
-	server.connect('foo', 6667, 'bestnick', ipv6=True)