1
0
mirror of https://gitlab.com/fdroid/fdroidserver.git synced 2024-11-04 22:40:12 +01:00

Replace legacy prints by debug logs

This commit is contained in:
Daniel Martí 2014-01-27 17:16:01 +01:00
parent 1e3c2eee25
commit 12506ce21d

View File

@ -19,6 +19,7 @@
import os, re, glob import os, re, glob
import cgi import cgi
import logging
class MetaDataException(Exception): class MetaDataException(Exception):
def __init__(self, value): def __init__(self, value):
@ -642,8 +643,8 @@ def write_metadata(dest, app):
if pf == key: if pf == key:
mf.write("%s\n" % comment) mf.write("%s\n" % comment)
written += 1 written += 1
#if options.verbose and written > 0: if written > 0:
#print "...writing comments for " + (key if key else 'EOF') logging.debug("...writing comments for " + (key if key else 'EOF'))
def writefield(field, value=None): def writefield(field, value=None):
writecomments(field) writecomments(field)
@ -711,8 +712,7 @@ def write_metadata(dest, app):
if not value: if not value:
return return
value = 'yes' value = 'yes'
#if options.verbose: logging.debug("...writing {0} : {1}".format(key, value))
#print "...writing {0} : {1}".format(key, value)
outline = ' %s=' % key outline = ' %s=' % key
outline += '&& \\\n '.join([s.lstrip() for s in value.split('&& ')]) outline += '&& \\\n '.join([s.lstrip() for s in value.split('&& ')])
outline += '\n' outline += '\n'