[Twisted-Python] resource.render_METHOD

Christopher Armstrong radix at twistedmatrix.com
Tue Mar 2 09:44:10 MST 2004


Richard.Townsend at edl.uk.eds.com wrote:
> I notice that if a resource receives a request it doesn't handle, then an
> UnsupportedMethod exception is raised. This returns HTML to the client
> containing a message that uses UnsupportedMethod.allowedMethods. This
> defaults to an empty tuple. 

> Is there a neater way to do this?

Hmm. I suppose render() could grope through methods on self to find all 
'render_FOO' methods when an exception occurs.. OTOH, we could just get 
rid of the allowed methods reporting. What's the use?

-- 
  Twisted | Christopher Armstrong: International Man of Twistery
   Radix  |          Release Manager,  Twisted Project
---------+           http://radix.twistedmatrix.com/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 256 bytes
Desc: OpenPGP digital signature
URL: </pipermail/twisted-python/attachments/20040302/172f9265/attachment.sig>


More information about the Twisted-Python mailing list