Beispiel #1
0
def _warn_or_exception(value, cause=None):
    '''output warning or Exception depending on -W'''
    if warnings_action == 'ignore':
        pass
    elif warnings_action == 'error':
        if cause:
            raise MetaDataException(value) from cause
        else:
            raise MetaDataException(value)
    else:
        logging.warning(value)
Beispiel #2
0
 def _resolve_description_link(appid):
     if appid in apps:
         return "fdroid.app:" + appid, apps[appid].Name
     raise MetaDataException("Cannot resolve app id " + appid)
Beispiel #3
0
 def resolve_description_link(self, appid):
     if appid in self.apps:
         if self.apps[appid].Name:
             return "fdroid.app:" + appid, self.apps[appid].Name
     raise MetaDataException(
         _('Cannot resolve application ID {appid}').format(appid=appid))
Beispiel #4
0
 def resolve_description_link(self, appid):
     if appid in self.apps:
         if self.apps[appid].Name:
             return "fdroid.app:" + appid, self.apps[appid].Name
     raise MetaDataException("Cannot resolve app id " + appid)