[Collab-qa-commits] r1935 - udd/udd
Andreas Tille
tille at alioth.debian.org
Fri Apr 15 06:06:45 UTC 2011
Author: tille
Date: 2011-04-15 06:06:39 +0000 (Fri, 15 Apr 2011)
New Revision: 1935
Modified:
udd/udd/ftpnew_gatherer.py
Log:
Ignore more undocumented fields in control file but enable printing them in debug mode
Modified: udd/udd/ftpnew_gatherer.py
===================================================================
--- udd/udd/ftpnew_gatherer.py 2011-04-14 17:20:06 UTC (rev 1934)
+++ udd/udd/ftpnew_gatherer.py 2011-04-15 06:06:39 UTC (rev 1935)
@@ -57,6 +57,22 @@
'Python-Version')
# + startswith('Npp-')
+# These fields are not documented (to my knowledge) but just occure from
+# time to time in control files
+# Just suppress warnings about these
+if DEBUG == 0:
+ IGNORED_UNKNOWN_FIELDS = ('Original-Maintainer',
+ 'Multi-Arch',
+ 'Python3-Version',
+ 'Gstreamer-Elements',
+ 'Gstreamer-Version',
+ 'Built-Using',
+ 'Package-Type',
+ 'Ruby-Versions'
+ )
+else:
+ IGNORED_UNKNOWN_FIELDS = ()
+
dependencies_to_accept = ( 'Depends', 'Recommends', 'Suggests', 'Enhances', 'Pre-Depends',
'Breaks', 'Replaces', 'Provides', 'Conflicts')
@@ -422,7 +438,7 @@
print >>srco, "%s: %s" % (field, value)
else:
# Don't warn about Original-Maintainer field
- if not field in ('Original-Maintainer', 'Multi-Arch', 'Python3-Version', 'Gstreamer-Elements', 'Gstreamer-Version'):
+ if not field in IGNORED_UNKNOWN_FIELDS:
print >>stderr, "Unknown field in %s: %s" % (srcpkg.s['Source'], field)
print >>srco, "*%s: %s" % (field, value)
continue
More information about the Collab-qa-commits
mailing list