Opened 12 years ago

Last modified 11 years ago

#740 defect closed fixed (fixed)

twisted.cred.portal.IRealm docstring for parameters

Reported by: thomasvs Owned by:
Priority: high Milestone:
Component: Keywords:
Cc: radix, teratorn, hypatia, thomasvs Branch:


Attachments (1)

issue740.patch (650 bytes) - added by thomasvs 12 years ago.

Download all attachments as: .zip

Change History (7)

comment:1 Changed 12 years ago by thomasvs

this docstring is missing argument descriptions.
attaching patch.

Changed 12 years ago by thomasvs

comment:2 Changed 12 years ago by exarkun

There should certainly be a docstring for this.  The docstring in this patch
isn't totally accurate though.  cred is useful for more than just pb.  In the
case of a PB realm, the types described in the patch are correct, but in the
case of a realm for any other protocol, they are not.

I'm not sure what a better doc string would look like, but it should cover these

  1) avatarId is generally a string, but not necessarily one.  The realm,
credentials checkers, and client code need to come to an agreement on this

  2) The realm is essentially an application-specific object.  It is often None
and ignored, but when it is necessary for the realm to initiate communications
with the client, rather than (or in addition to) the reverse, it is useful to
create a client object of some sort and pass it as the parameter for the mind.

comment:3 Changed 12 years ago by teratorn

Any progress on this?

comment:4 Changed 11 years ago by radix

exarkun meant to say "mind", not "realm" at the beginning of his point 2.

comment:5 Changed 11 years ago by radix

closing, there are quite sufficient argument descriptions in the docstring 
as it stands. maybe someone added them and forgot to close this

comment:6 Changed 5 years ago by <automation>

  • Owner hypatia deleted
Note: See TracTickets for help on using tickets.