Changeset a183a42 for fedd/deter


Ignore:
Timestamp:
Aug 14, 2014 8:15:56 AM (10 years ago)
Author:
Ted Faber <faber@…>
Branches:
master
Children:
f74e3a1
Parents:
b2a4214
Message:

Allow data to work w/o full fedid support

File:
1 edited

Legend:

Unmodified
Added
Removed
  • fedd/deter/topdl.py

    rb2a4214 ra183a42  
    77from string import join
    88
    9 from fedid import fedid as fedid_class
     9try:
     10    from fedid import fedid as fedid_class
     11except ImportError:
     12    class fedid_class:
     13        '''
     14        Dummy class to allow most of the topdl function when m2crypto and asn1
     15        are not around
     16        '''
     17        def __init__(self, hexstr=None):
     18            if hexstr is not None: self.data = hexstr
     19            else: self.data = "default data"
     20
     21        def get_bits(self):
     22            return self.data
    1023
    1124class base:
Note: See TracChangeset for help on using the changeset viewer.