signal handling oddity
m at moshez.org
Mon Jun 9 17:00:13 CEST 2003
On Mon, 09 Jun 2003, "Justin Johnson" <justinjohnson at fastmail.fm> wrote:
> Yeah, I was using twisted before for this server and it did handle
> control-c correctly. I was having problems getting authentication to
> work though, so I ended up moving to SimpleXMLRPCServer and adding some
> other code to get basic authentication to work. I'm just not familiar
> enough with twisted to know what to subclass/override, etc... to get
> simple user/password authentication to work.
Well, probably in the render() method of your resource, you do
the checking of request.headers (there's no problem doing it
manually), and if they're ok you call the parent's render()
and otherwise you return a 401.
Moshe Zadka -- http://moshez.org/
Buffy: I don't like you hanging out with someone that... short.
Riley: Yeah, a lot of young people nowadays are experimenting with shortness.
Agile Programming Language -- http://www.python.org/
More information about the Python-list