[Twisted-Python] Interface.adaptWith and Interface.__adapt__

Clark C. Evans twisted-python@twistedmatrix.com
Sat, 7 Jun 2003 18:46:35 +0000


On Thu, Jun 05, 2003 at 01:59:44AM -0400, Glyph Lefkowitz wrote:
| As I understand it, PEP 246 cannot be implemented without raising 
| exceptions in __adapt__. 

PEP 246 does not require exceptions in __adapt__, it does require
that the caller of adapt catch TypeError.  Perhaps this isn't
clearly documented, but is definately part of the reference
implementation.

Best,

Clark