[Zope-Coders] Re: CVS: Zope/ZServer/medusa - asnycore.py:1.16.12.2

Matt Behrens matt@zigg.com
Thu, 20 Jun 2002 11:52:52 -0400


On Thu, Jun 20, 2002 at 11:18:02AM -0400, zope-checkins-request@zope.org wrote:

> Message: 2
> Date: Thu, 20 Jun 2002 10:03:05 -0400
> To: Brian Lloyd <brian@zope.com>
> Cc: zope-checkins@zope.org
> Subject: Re: [Zope-Checkins] CVS: Zope/ZServer/medusa - asyncore.py:1.16.12.2
> From: "Fred L. Drake, Jr." <fdrake@acm.org>
> 
> Brian Lloyd writes:
>  > +    # HACK by ZC: this hack also appears in ZServer.__init__, but it
>  > +    # doesn't get installed if someone uses medusa directly (as they
>  > +    # would when running the monitor client. This ensures that the
>  > +    # compatibility hack is installed. Hopefully this (and any other)
>  > +    # hacks can go away when we move to Python 2.2.
>  > +    if not hasattr(fcntl, 'F_GETFL'):
>  > +        import FCNTL
>  > +        fcntl.F_GETFL = FCNTL.F_GETFL
>  > +        fcntl.F_SETFL = FCNTL.F_SETFL
> 
> So *why* isn't the ZServer.__init__ version getting run when using
> ZServer.medusa?  That sounds like a bug.  Does the ZServer/ directory
> get put on sys.path directly in some case?

cd ZServer/medusa
python2.1 monitor_client.py localhost 8099

Therefore __init__.py won't be called.  That's what we're fixing
today :-)