On Wed, Aug 16, 2000 at 12:28:06PM -0500, Brandon wrote:
> 
> > Actually, you *can* just give a KHK or KSK (depending on what is
> > default).  But you have to use the full form for other types.
> 
> I don't see why you can't have a request function which takes a string and
> converts it to the full form.

This could be done, but it would be extremely kludgey.  The main
problem is that there is no way in Python to determine the type of an
arbitrary object (Python usage of object).  You can determine the
*class* of an instance, but you can't easily tell the difference
between a tuple and a string share most of their legal operations.  I
have figured out one way to tell the difference between a tuple or a
string.  Some example code is below:

def conv(key):
        try:
                foo = key + 'foo'
        except:
                return key
        return (key, None, 'KSK')       

That's a real kludge, but it is the only way to do it.

-- 
Travis Bemann
Sendmail is still screwed up on my box.
My email address is really bemann at execpc.com.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 1252 bytes
Desc: not available
URL: 
<https://emu.freenetproject.org/pipermail/devl/attachments/20000816/3d85db0e/attachment.pgp>

Reply via email to