[Twisted-Python] async returns from DefaultAuthorizer.addIdentity

Glyph Lefkowitz glyph at twistedmatrix.com
Sat Sep 28 04:29:07 EDT 2002


On 27 Sep 2002 17:06:47 -0700, Kevin Turner <acapnotic at twistedmatrix.com> wrote:
> On Fri, 2002-09-27 at 15:14, Kevin Turner wrote:
> > Authorizer.addCallback's 
> Authorizer.addIdentity, I mean.
> 
> > But returning a defer.fail makes
> > test_cred.AuthorizerTestCase.test_addIdent fail, as it has an
> > assertRaises in there.
> 
> and code depends on this synchronous behaviour, including
> perspective.makeIdentity, which is used in in many .tap-builders'
> updateApplication, also handled synchronously.

Not that this isn't an error, but... from what I can see, makeIdentity's
results are thrown away by the caller everywhere it's being called.  I don't
think it would break too terribly much to change it.  (The unit tests may just
be overzealous.)

dbcred seems to return the documented value from this, so in order to get the
unit tests to work for a DatabaseAuthorizer we're going to have to fix it
anyway.

-- 
 |    <`'>    |  Glyph Lefkowitz: Traveling Sorcerer   |
 |   < _/ >   |  Lead Developer,  the Twisted project  |
 |  < ___/ >  |      http://www.twistedmatrix.com      |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://twistedmatrix.com/pipermail/twisted-python/attachments/20020928/6402a808/attachment.pgp 


More information about the Twisted-Python mailing list