debian/lib/python/debian_linux/gencontrol.py: Delete broken methods

MakeFlags.__repr__ references a "flags" type (probably meant to be
MakeFlags).  Gencontrol.write_config references the "file" type which
was removed in Python 3.  Clearly neither of these methods are
actually used, so delete them.
This commit is contained in:
Ben Hutchings 2018-10-01 21:56:28 +01:00
parent 8cafaf07ae
commit 8b0aacdc26
2 changed files with 1 additions and 9 deletions

1
debian/changelog vendored
View File

@ -10,6 +10,7 @@ linux (4.19~rc6-1~exp1) UNRELEASED; urgency=medium
instead of editing path
* debian/bin, debian/lib/python: Clean up imports based on pyflakes report
* debian/bin, debian/lib/python: Delete write-only vars reported by pyflakes
* debian/lib/python/debian_linux/gencontrol.py: Delete broken methods
-- Ben Hutchings <ben@decadent.org.uk> Thu, 20 Sep 2018 02:40:54 +0100

View File

@ -65,10 +65,6 @@ class Makefile(object):
class MakeFlags(dict):
def __repr__(self):
repr = super(flags, self).__repr__()
return "%s(%s)" % (self.__class__.__name__, repr)
def __str__(self):
return ' '.join("%s='%s'" % i for i in sorted(self.items()))
@ -372,11 +368,6 @@ class Gencontrol(object):
self.write_control(packages.values())
self.write_makefile(makefile)
def write_config(self):
f = file("debian/config.dump", 'w')
self.config.write(f)
f.close()
def write_control(self, list, name='debian/control'):
self.write_rfc822(codecs.open(name, 'w', 'utf-8'), list)