Your message dated Mon, 20 Oct 2014 20:34:36 +0000 with message-id <544571DC.1030004@nirgal.com> and subject line Re: python-socksipy: Exceptions take only one parameter, don't give 2! has caused the Debian Bug report #748195, regarding python-socksipy: Exceptions take only one parameter, don't give 2! to be marked as done. This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact owner@bugs.debian.org immediately.) -- 748195: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=748195 Debian Bug Tracking System Contact owner@bugs.debian.org with problems
--- Begin Message ---
- To: Debian Bug Tracking System <submit@bugs.debian.org>
- Subject: python-socksipy: Exceptions take only one parameter, don't give 2!
- From: Jean-Michel Nirgal Vourgère <jmv_deb@nirgal.com>
- Date: Thu, 15 May 2014 11:04:51 +0200
- Message-id: <53748333.20402@nirgal.com>
Package: python-socksipy Version: 1.0-1 Severity: minor Tags: patch Dear Maintainer, When a connection can't be established an exception is raised. This is good. But exception __init__ take only one argument, and there are some places in the code where 2 are given, resulting in TypeError exception being raised, insteed of Socks5Error or simmilar.This is quite unfriendly, and obviously not what was intended by the author. Traceback (most recent call last): (...) File "/usr/lib/python2.7/dist-packages/socks.py", line 369, in connect self.__negotiatesocks5(destpair[0],destpair[1]) File "/usr/lib/python2.7/dist-packages/socks.py", line 236, in __negotiatesocks5 raise Socks5Error(ord(resp[1]),_generalerrors[ord(resp[1])]) TypeError: __init__() takes exactly 2 arguments (3 given) Attached is a patch. After patching, the proper exception is raised: Traceback (most recent call last): (...) File "/usr/lib/python2.7/dist-packages/socks.py", line 369, in connect self.__negotiatesocks5(destpair[0],destpair[1]) File "/usr/lib/python2.7/dist-packages/socks.py", line 236, in __negotiatesocks5 raise Socks5Error((ord(resp[1]),_generalerrors[ord(resp[1])])) socks.Socks5Error: (4, 'bad proxy type') Thank you for maintaining that package :) -- System Information: Debian Release: 7.5 APT prefers stable APT policy: (500, 'stable') Architecture: amd64 (x86_64) Kernel: Linux 3.2.0-4-amd64 (SMP w/1 CPU core) Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages python-socksipy depends on: ii python 2.7.3-4+deb7u1 ii python-central 0.6.17 python-socksipy recommends no packages. python-socksipy suggests no packages. -- no debconf information--- /usr/lib/python2.7/dist-packages/socks.py.orig 2006-10-25 22:19:26.000000000 +0200 +++ /usr/lib/python2.7/dist-packages/socks.py 2014-05-15 10:44:49.000000000 +0200 @@ -196,7 +196,7 @@ if authstat[1] != "\x00": # Authentication failed self.close() - raise Socks5AuthError,((3,_socks5autherrors[3])) + raise Socks5AuthError((3,_socks5autherrors[3])) # Authentication succeeded else: # Reaching here is always bad @@ -233,9 +233,9 @@ # Connection failed self.close() if ord(resp[1])<=8: - raise Socks5Error(ord(resp[1]),_generalerrors[ord(resp[1])]) + raise Socks5Error((ord(resp[1]),_generalerrors[ord(resp[1])])) else: - raise Socks5Error(9,_generalerrors[9]) + raise Socks5Error((9,_generalerrors[9])) # Get the bound address/port elif resp[3] == "\x01": boundaddr = self.__recvall(4)
--- End Message ---
--- Begin Message ---
- To: 748195-done@bugs.debian.org
- Subject: Re: python-socksipy: Exceptions take only one parameter, don't give 2!
- From: Jean-Michel Nirgal Vourgère <jmv_deb@nirgal.com>
- Date: Mon, 20 Oct 2014 20:34:36 +0000
- Message-id: <544571DC.1030004@nirgal.com>
Version: 1.02-1 This bug has been fixed upstream, and in sid. Thank you :)Attachment: signature.asc
Description: OpenPGP digital signature
--- End Message ---