Port check-mir to Python 3

This commit is contained in:
Stefano Rivera 2019-09-04 13:08:11 -03:00
parent 2a0bffc2a0
commit 071ff40f20
3 changed files with 5 additions and 6 deletions

View File

@ -1,4 +1,4 @@
#!/usr/bin/python
#!/usr/bin/python3
#
# Check components of build dependencies and warn about universe/multiverse
# ones, for a package destined for main/restricted
@ -21,8 +21,6 @@
# this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
from __future__ import print_function
import sys
import optparse
import os.path
@ -103,7 +101,7 @@ def check_binary_dependencies(apt_cache, control):
print('\nChecking support status of binary dependencies...')
while True:
try:
control.next()
next(control)
except StopIteration:
break
@ -141,7 +139,7 @@ def main():
# get build dependencies from debian/control
control = apt.apt_pkg.TagFile(open('debian/control'))
control.next()
next(control)
unsupported_build_deps = check_build_dependencies(apt_cache, control)
unsupported_binary_deps = check_binary_dependencies(apt_cache, control)

1
debian/control vendored
View File

@ -63,6 +63,7 @@ Depends:
python-lazr.restfulclient,
python-ubuntutools,
python3,
python3-apt,
python3-distro-info,
python3-httplib2,
python3-launchpadlib,

View File

@ -19,6 +19,7 @@ if sys.version_info[0] >= 3:
scripts = [
'backportpackage',
'bitesize',
'check-mir',
'check-symbols',
'dch-repeat',
'grab-merge',
@ -36,7 +37,6 @@ if sys.version_info[0] >= 3:
]
else:
scripts = [
'check-mir',
'grep-merges',
'hugdaylist',
'import-bug-from-debian',