[Patches] [ python-Patches-487458 ] bugfix and extension to Lib/asyncore.py
noreply@sourceforge.net
noreply@sourceforge.net
Thu, 13 Dec 2001 11:09:21 -0800
Patches item #487458, was opened at 2001-11-30 03:14
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=487458&group_id=5470
Category: Library (Lib)
Group: None
Status: Open
>Resolution: Later
>Priority: 5
Submitted By: Hye-Shik Chang (perky)
Assigned to: Jeremy Hylton (jhylton)
Summary: bugfix and extension to Lib/asyncore.py
Initial Comment:
fix: asyncore of 2.2b2+ fails to initialize when passed
'sock' is listening.
extension(or bugfix?): more flexible handling own map
----------------------------------------------------------------------
>Comment By: Jeremy Hylton (jhylton)
Date: 2001-12-13 11:09
Message:
Logged In: YES
user_id=31392
I'm not comfortable making changes like this with only the
release candidate for testing. I think we should postpone
until 2.3.
----------------------------------------------------------------------
Comment By: Hye-Shik Chang (perky)
Date: 2001-12-04 21:09
Message:
Logged In: YES
user_id=55188
Oops! sorry. It was a mistake.
changed to corrected patch.
----------------------------------------------------------------------
Comment By: Hye-Shik Chang (perky)
Date: 2001-12-03 20:14
Message:
Logged In: YES
user_id=55188
On the ENOTCONN error:
the error will be raised only if 'sock' was bound outside.
(even if self.accepting get set)
but using out-bound socket is unavoidable for some server
models. and I and some co-workers are using it.
How about this way instead of previous patch?
if not self.accepting:
self.addr = sock.getpeername()
On passing maps:
some part of asyncore supports using own socket map.
(__init__, add_channel, del_channel), but when
__init__ registers socket into map which passed by
argument, asyncore can't del_channel from own map and
it will raises KeyError because asyncore.socket_map
doesn't have such fileno.
And, current version of asynchat doesn't support
to use another maps.
----------------------------------------------------------------------
Comment By: Martin v. Löwis (loewis)
Date: 2001-12-02 03:03
Message:
Logged In: YES
user_id=21627
On the ENOTCONN error: Shouldn't self.accepting get set if
the socket is listening? But then, the socket may not be
even listening?
On passing maps: Can you please explain why you use self.map
if it is None? I had expected that you use socket_map in
this case.
----------------------------------------------------------------------
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=487458&group_id=5470