Merge lp:~brian-murray/ubuntu-archive-tools/more-python3 into lp:ubuntu-archive-tools
- more-python3
- Merge into trunk
Proposed by
Brian Murray
Status: | Merged |
---|---|
Merged at revision: | 1400 |
Proposed branch: | lp:~brian-murray/ubuntu-archive-tools/more-python3 |
Merge into: | lp:ubuntu-archive-tools |
Diff against target: |
661 lines (+60/-114) 27 files modified
architecture-mismatches (+1/-3) archive-cruft-check (+1/-3) bootstrap-package (+1/-2) copy-report (+3/-5) derive-distribution (+5/-9) get-distro-update-metrics (+3/-3) import-blacklist (+1/-3) iso-deb-size-compare (+4/-6) kernel-overrides (+4/-8) kernel_series.py (+8/-11) list-builds-on-tracker (+1/-1) nbs-report (+1/-3) orphaned-sources (+3/-7) package-subscribers (+1/-3) packageset-report (+1/-1) pocket-mismatches (+1/-3) point-release-snapshot (+1/-3) post-amis-to-iso-tracker (+1/-3) post-image-to-iso-tracker (+1/-1) priority-mismatches (+2/-4) promote-to-release (+1/-3) publish-image-set (+5/-7) queuediff (+5/-8) regression-proposed-bug-search (+2/-7) rescore-ppa-builds (+1/-3) sync-blacklist (+1/-3) utils.py (+1/-1) |
To merge this branch: | bzr merge lp:~brian-murray/ubuntu-archive-tools/more-python3 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Łukasz Zemczak | Pending | ||
Steve Langasek | Pending | ||
Review via email: mp+393198@code.launchpad.net |
Commit message
Move more tools to python3.
Description of the change
To post a comment you must log in.
- 1420. By Brian Murray
-
move package-subscribers to python3
- 1421. By Brian Murray
-
move priority-mismatches to python3
- 1422. By Brian Murray
-
move point-release-
snapshot to python3 - 1423. By Brian Murray
-
switch shebang for priority-mismatches and point-release-
snapshot - 1424. By Brian Murray
-
move pocket-mismatches to python3
- 1425. By Brian Murray
-
move kernel_series.py to python3
- 1426. By Brian Murray
-
move copy-report to python3
- 1427. By Brian Murray
-
Move architecture-
mismatches to python3
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'architecture-mismatches' | |||
2 | --- architecture-mismatches 2020-01-25 02:19:13 +0000 | |||
3 | +++ architecture-mismatches 2020-11-02 20:20:51 +0000 | |||
4 | @@ -1,4 +1,4 @@ | |||
6 | 1 | #!/usr/bin/env python2.7 | 1 | #!/usr/bin/python3 |
7 | 2 | 2 | ||
8 | 3 | # Check for override mismatches between architectures | 3 | # Check for override mismatches between architectures |
9 | 4 | # Copyright (C) 2005, 2008, 2009, 2010, 2011, 2012 Canonical Ltd. | 4 | # Copyright (C) 2005, 2008, 2009, 2010, 2011, 2012 Canonical Ltd. |
10 | @@ -18,8 +18,6 @@ | |||
11 | 18 | # along with this program; if not, write to the Free Software | 18 | # along with this program; if not, write to the Free Software |
12 | 19 | # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 19 | # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
13 | 20 | 20 | ||
14 | 21 | from __future__ import print_function | ||
15 | 22 | |||
16 | 23 | import atexit | 21 | import atexit |
17 | 24 | from collections import defaultdict | 22 | from collections import defaultdict |
18 | 25 | import csv | 23 | import csv |
19 | 26 | 24 | ||
20 | === modified file 'archive-cruft-check' | |||
21 | --- archive-cruft-check 2020-01-25 02:19:13 +0000 | |||
22 | +++ archive-cruft-check 2020-11-02 20:20:51 +0000 | |||
23 | @@ -1,9 +1,7 @@ | |||
25 | 1 | #! /usr/bin/python2.7 | 1 | #! /usr/bin/python3 |
26 | 2 | # Copyright 2009-2012 Canonical Ltd. This software is licensed under the | 2 | # Copyright 2009-2012 Canonical Ltd. This software is licensed under the |
27 | 3 | # GNU Affero General Public License version 3. | 3 | # GNU Affero General Public License version 3. |
28 | 4 | 4 | ||
29 | 5 | from __future__ import print_function | ||
30 | 6 | |||
31 | 7 | from collections import defaultdict | 5 | from collections import defaultdict |
32 | 8 | import logging | 6 | import logging |
33 | 9 | import optparse | 7 | import optparse |
34 | 10 | 8 | ||
35 | === modified file 'bootstrap-package' | |||
36 | --- bootstrap-package 2020-01-25 02:19:13 +0000 | |||
37 | +++ bootstrap-package 2020-11-02 20:20:51 +0000 | |||
38 | @@ -1,4 +1,4 @@ | |||
40 | 1 | #! /usr/bin/python2.7 | 1 | #! /usr/bin/python3 |
41 | 2 | 2 | ||
42 | 3 | # Copyright (C) 2016 Canonical Ltd. | 3 | # Copyright (C) 2016 Canonical Ltd. |
43 | 4 | # Author: Colin Watson <cjwatson@ubuntu.com> | 4 | # Author: Colin Watson <cjwatson@ubuntu.com> |
44 | @@ -17,7 +17,6 @@ | |||
45 | 17 | 17 | ||
46 | 18 | """Bootstrap a package build using injected build-dependencies.""" | 18 | """Bootstrap a package build using injected build-dependencies.""" |
47 | 19 | 19 | ||
48 | 20 | from __future__ import print_function | ||
49 | 21 | import sys | 20 | import sys |
50 | 22 | 21 | ||
51 | 23 | from optparse import ( | 22 | from optparse import ( |
52 | 24 | 23 | ||
53 | === modified file 'copy-report' | |||
54 | --- copy-report 2020-01-25 02:19:13 +0000 | |||
55 | +++ copy-report 2020-11-02 20:20:51 +0000 | |||
56 | @@ -1,4 +1,4 @@ | |||
58 | 1 | #! /usr/bin/env python2.7 | 1 | #! /usr/bin/python3 |
59 | 2 | 2 | ||
60 | 3 | from __future__ import print_function | 3 | from __future__ import print_function |
61 | 4 | 4 | ||
62 | @@ -11,10 +11,8 @@ | |||
63 | 11 | import shutil | 11 | import shutil |
64 | 12 | import subprocess | 12 | import subprocess |
65 | 13 | import tempfile | 13 | import tempfile |
70 | 14 | try: | 14 | |
71 | 15 | from urllib.parse import unquote | 15 | from urllib.parse import unquote |
68 | 16 | except ImportError: | ||
69 | 17 | from urllib import unquote | ||
72 | 18 | 16 | ||
73 | 19 | import apt_pkg | 17 | import apt_pkg |
74 | 20 | from launchpadlib.launchpad import Launchpad | 18 | from launchpadlib.launchpad import Launchpad |
75 | 21 | 19 | ||
76 | === modified file 'derive-distribution' | |||
77 | --- derive-distribution 2020-01-25 02:19:13 +0000 | |||
78 | +++ derive-distribution 2020-11-02 20:20:51 +0000 | |||
79 | @@ -1,4 +1,4 @@ | |||
81 | 1 | #! /usr/bin/python2.7 | 1 | #! /usr/bin/python3 |
82 | 2 | 2 | ||
83 | 3 | # Copyright (C) 2014 Canonical Ltd. | 3 | # Copyright (C) 2014 Canonical Ltd. |
84 | 4 | # Author: Colin Watson <cjwatson@ubuntu.com> | 4 | # Author: Colin Watson <cjwatson@ubuntu.com> |
85 | @@ -19,8 +19,6 @@ | |||
86 | 19 | 19 | ||
87 | 20 | """Copy a subset of one distribution into a derived distribution.""" | 20 | """Copy a subset of one distribution into a derived distribution.""" |
88 | 21 | 21 | ||
89 | 22 | from __future__ import print_function | ||
90 | 23 | |||
91 | 24 | import atexit | 22 | import atexit |
92 | 25 | from collections import OrderedDict | 23 | from collections import OrderedDict |
93 | 26 | from contextlib import closing, contextmanager | 24 | from contextlib import closing, contextmanager |
94 | @@ -33,10 +31,8 @@ | |||
95 | 33 | import sys | 31 | import sys |
96 | 34 | import tempfile | 32 | import tempfile |
97 | 35 | import time | 33 | import time |
102 | 36 | try: | 34 | |
103 | 37 | from urllib.request import urlopen | 35 | from urllib.request import urlopen |
100 | 38 | except ImportError: | ||
101 | 39 | from urllib2 import urlopen | ||
104 | 40 | 36 | ||
105 | 41 | import apt_pkg | 37 | import apt_pkg |
106 | 42 | from dateutil import parser as dateutil_parser | 38 | from dateutil import parser as dateutil_parser |
107 | @@ -217,7 +213,7 @@ | |||
108 | 217 | for inner_seed in germinator._inner_seeds(seed): | 213 | for inner_seed in germinator._inner_seeds(seed): |
109 | 218 | if inner_seed.name not in all_seeds: | 214 | if inner_seed.name not in all_seeds: |
110 | 219 | all_seeds[inner_seed.name] = inner_seed | 215 | all_seeds[inner_seed.name] = inner_seed |
112 | 220 | for seed in all_seeds.values(): | 216 | for seed in list(all_seeds.values()): |
113 | 221 | sources = seed._sourcepkgs | seed._build_sourcepkgs | 217 | sources = seed._sourcepkgs | seed._build_sourcepkgs |
114 | 222 | for source in sources: | 218 | for source in sources: |
115 | 223 | version = germinator._sources[source]["Version"] | 219 | version = germinator._sources[source]["Version"] |
116 | @@ -275,7 +271,7 @@ | |||
117 | 275 | for source in germinator._sources: | 271 | for source in germinator._sources: |
118 | 276 | self._versions[source] = germinator._sources[source]["Version"] | 272 | self._versions[source] = germinator._sources[source]["Version"] |
119 | 277 | else: | 273 | else: |
121 | 278 | for flavour, seed_names in flavours.items(): | 274 | for flavour, seed_names in list(flavours.items()): |
122 | 279 | logging.info("Germinating for %s/%s/%s", flavour, suite, arch) | 275 | logging.info("Germinating for %s/%s/%s", flavour, suite, arch) |
123 | 280 | self.germinateArchFlavour( | 276 | self.germinateArchFlavour( |
124 | 281 | germinator, suite, arch, flavour, structures[flavour], | 277 | germinator, suite, arch, flavour, structures[flavour], |
125 | 282 | 278 | ||
126 | === modified file 'get-distro-update-metrics' | |||
127 | --- get-distro-update-metrics 2020-01-25 02:19:13 +0000 | |||
128 | +++ get-distro-update-metrics 2020-11-02 20:20:51 +0000 | |||
129 | @@ -1,4 +1,4 @@ | |||
131 | 1 | #! /usr/bin/python2.7 | 1 | #! /usr/bin/python3 |
132 | 2 | # Copyright 2012 Canonical Ltd. | 2 | # Copyright 2012 Canonical Ltd. |
133 | 3 | # | 3 | # |
134 | 4 | # This script will write update metrics for a given Ubuntu release in CSV | 4 | # This script will write update metrics for a given Ubuntu release in CSV |
135 | @@ -25,7 +25,7 @@ | |||
136 | 25 | [key, {'Updates': X, 'Security': X, 'Total': X}] record. | 25 | [key, {'Updates': X, 'Security': X, 'Total': X}] record. |
137 | 26 | """ | 26 | """ |
138 | 27 | logging.info('Writing metrics by %s to %s', key_name.lower(), filename) | 27 | logging.info('Writing metrics by %s to %s', key_name.lower(), filename) |
140 | 28 | writer = csv.writer(open(filename, 'wb')) | 28 | writer = csv.writer(open(filename, 'w')) |
141 | 29 | writer.writerow([key_name, 'Updates', 'Security', 'Total']) | 29 | writer.writerow([key_name, 'Updates', 'Security', 'Total']) |
142 | 30 | for key, metrics in metrics: | 30 | for key, metrics in metrics: |
143 | 31 | writer.writerow( | 31 | writer.writerow( |
144 | @@ -105,7 +105,7 @@ | |||
145 | 105 | options.distribution, args[0]) | 105 | options.distribution, args[0]) |
146 | 106 | write_metrics_csv( | 106 | write_metrics_csv( |
147 | 107 | by_package_filename, 'Package', sorted( | 107 | by_package_filename, 'Package', sorted( |
149 | 108 | updates_by_package.items(), | 108 | list(updates_by_package.items()), |
150 | 109 | key=lambda m: m[1]['Total'], reverse=True)) | 109 | key=lambda m: m[1]['Total'], reverse=True)) |
151 | 110 | 110 | ||
152 | 111 | 111 | ||
153 | 112 | 112 | ||
154 | === modified file 'import-blacklist' | |||
155 | --- import-blacklist 2020-01-25 02:19:13 +0000 | |||
156 | +++ import-blacklist 2020-11-02 20:20:51 +0000 | |||
157 | @@ -1,4 +1,4 @@ | |||
159 | 1 | #!/usr/bin/python2.7 | 1 | #!/usr/bin/python3 |
160 | 2 | 2 | ||
161 | 3 | # Copyright (C) 2011 Iain Lane | 3 | # Copyright (C) 2011 Iain Lane |
162 | 4 | # Copyright (C) 2011 Stefano Rivera | 4 | # Copyright (C) 2011 Stefano Rivera |
163 | @@ -15,8 +15,6 @@ | |||
164 | 15 | # You should have received a copy of the GNU General Public License | 15 | # You should have received a copy of the GNU General Public License |
165 | 16 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | 16 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
166 | 17 | 17 | ||
167 | 18 | from __future__ import print_function, unicode_literals | ||
168 | 19 | |||
169 | 20 | from optparse import OptionParser | 18 | from optparse import OptionParser |
170 | 21 | import re | 19 | import re |
171 | 22 | 20 | ||
172 | 23 | 21 | ||
173 | === modified file 'iso-deb-size-compare' | |||
174 | --- iso-deb-size-compare 2020-01-25 02:19:13 +0000 | |||
175 | +++ iso-deb-size-compare 2020-11-02 20:20:51 +0000 | |||
176 | @@ -1,4 +1,4 @@ | |||
178 | 1 | #!/usr/bin/python2.7 | 1 | #!/usr/bin/python3 |
179 | 2 | # -*- coding: utf-8 -*- | 2 | # -*- coding: utf-8 -*- |
180 | 3 | 3 | ||
181 | 4 | # Copyright (C) 2010, 2012 Canonical Ltd. | 4 | # Copyright (C) 2010, 2012 Canonical Ltd. |
182 | @@ -21,8 +21,6 @@ | |||
183 | 21 | # two releases or daily builds. Note that this only really works for | 21 | # two releases or daily builds. Note that this only really works for |
184 | 22 | # alternates, since desktop CDs by and large just have one big squashfs image. | 22 | # alternates, since desktop CDs by and large just have one big squashfs image. |
185 | 23 | 23 | ||
186 | 24 | from __future__ import print_function | ||
187 | 25 | |||
188 | 26 | import subprocess | 24 | import subprocess |
189 | 27 | import sys | 25 | import sys |
190 | 28 | 26 | ||
191 | @@ -62,7 +60,7 @@ | |||
192 | 62 | 60 | ||
193 | 63 | print('== Removed packages ==') | 61 | print('== Removed packages ==') |
194 | 64 | sum = 0 | 62 | sum = 0 |
196 | 65 | for p, (v, s) in old_map.iteritems(): | 63 | for p, (v, s) in old_map.items(): |
197 | 66 | if p not in new_map: | 64 | if p not in new_map: |
198 | 67 | print('%s (%.1f MB)' % (p, s / 1000000.)) | 65 | print('%s (%.1f MB)' % (p, s / 1000000.)) |
199 | 68 | sum += s | 66 | sum += s |
200 | @@ -70,7 +68,7 @@ | |||
201 | 70 | 68 | ||
202 | 71 | sum = 0 | 69 | sum = 0 |
203 | 72 | print('\n== Added packages ==') | 70 | print('\n== Added packages ==') |
205 | 73 | for p, (v, s) in new_map.iteritems(): | 71 | for p, (v, s) in new_map.items(): |
206 | 74 | if p not in old_map: | 72 | if p not in old_map: |
207 | 75 | print('%s (%.1f MB)' % (p, s / 1000000.)) | 73 | print('%s (%.1f MB)' % (p, s / 1000000.)) |
208 | 76 | sum += s | 74 | sum += s |
209 | @@ -78,7 +76,7 @@ | |||
210 | 78 | 76 | ||
211 | 79 | print('\n== Changed packages ==') | 77 | print('\n== Changed packages ==') |
212 | 80 | sum = 0 | 78 | sum = 0 |
214 | 81 | for p, (v, s) in old_map.iteritems(): | 79 | for p, (v, s) in old_map.items(): |
215 | 82 | if p not in new_map: | 80 | if p not in new_map: |
216 | 83 | continue | 81 | continue |
217 | 84 | 82 | ||
218 | 85 | 83 | ||
219 | === modified file 'kernel-overrides' | |||
220 | --- kernel-overrides 2020-01-25 02:19:13 +0000 | |||
221 | +++ kernel-overrides 2020-11-02 20:20:51 +0000 | |||
222 | @@ -1,4 +1,4 @@ | |||
224 | 1 | #! /usr/bin/python2.7 | 1 | #! /usr/bin/python3 |
225 | 2 | 2 | ||
226 | 3 | # Copyright (C) 2009, 2010, 2011, 2012 Canonical Ltd. | 3 | # Copyright (C) 2009, 2010, 2011, 2012 Canonical Ltd. |
227 | 4 | 4 | ||
228 | @@ -16,8 +16,6 @@ | |||
229 | 16 | 16 | ||
230 | 17 | """Apply suitable overrides to new kernel binaries, matching previous ones.""" | 17 | """Apply suitable overrides to new kernel binaries, matching previous ones.""" |
231 | 18 | 18 | ||
232 | 19 | from __future__ import print_function | ||
233 | 20 | |||
234 | 21 | import atexit | 19 | import atexit |
235 | 22 | from collections import defaultdict | 20 | from collections import defaultdict |
236 | 23 | from contextlib import closing | 21 | from contextlib import closing |
237 | @@ -27,10 +25,8 @@ | |||
238 | 27 | import shutil | 25 | import shutil |
239 | 28 | import sys | 26 | import sys |
240 | 29 | import tempfile | 27 | import tempfile |
245 | 30 | try: | 28 | |
246 | 31 | from urllib.request import urlopen | 29 | from urllib.request import urlopen |
243 | 32 | except ImportError: | ||
244 | 33 | from urllib2 import urlopen | ||
247 | 34 | 30 | ||
248 | 35 | import apt_pkg | 31 | import apt_pkg |
249 | 36 | from launchpadlib.launchpad import Launchpad | 32 | from launchpadlib.launchpad import Launchpad |
250 | @@ -175,7 +171,7 @@ | |||
251 | 175 | if binary["architecture"] not in current_binaries: | 171 | if binary["architecture"] not in current_binaries: |
252 | 176 | continue | 172 | continue |
253 | 177 | current_binaries_arch = current_binaries[binary["architecture"]] | 173 | current_binaries_arch = current_binaries[binary["architecture"]] |
255 | 178 | for name, component in current_binaries_arch.items(): | 174 | for name, component in list(current_binaries_arch.items()): |
256 | 179 | if (binary["component"] != component and | 175 | if (binary["component"] != component and |
257 | 180 | equal_except_abi(name, binary["name"], newabi)): | 176 | equal_except_abi(name, binary["name"], newabi)): |
258 | 181 | print("\t%s: %s -> %s" % | 177 | print("\t%s: %s -> %s" % |
259 | 182 | 178 | ||
260 | === modified file 'kernel_series.py' | |||
261 | --- kernel_series.py 2020-01-25 02:19:13 +0000 | |||
262 | +++ kernel_series.py 2020-11-02 20:20:51 +0000 | |||
263 | @@ -1,10 +1,7 @@ | |||
265 | 1 | #!/usr/bin/env python2.7 | 1 | #!/usr/bin/python3 |
266 | 2 | # | 2 | # |
267 | 3 | 3 | ||
272 | 4 | try: | 4 | from urllib.request import urlopen |
269 | 5 | from urllib.request import urlopen | ||
270 | 6 | except ImportError: | ||
271 | 7 | from urllib2 import urlopen | ||
273 | 8 | 5 | ||
274 | 9 | import os | 6 | import os |
275 | 10 | import yaml | 7 | import yaml |
276 | @@ -50,7 +47,7 @@ | |||
277 | 50 | return not self.__eq__(other) | 47 | return not self.__eq__(other) |
278 | 51 | 48 | ||
279 | 52 | def __iter__(self): | 49 | def __iter__(self): |
281 | 53 | return iter(self._data.items()) | 50 | return iter(list(self._data.items())) |
282 | 54 | 51 | ||
283 | 55 | def __getitem__(self, which): | 52 | def __getitem__(self, which): |
284 | 56 | return self._data[which] | 53 | return self._data[which] |
285 | @@ -323,7 +320,7 @@ | |||
286 | 323 | result = [] | 320 | result = [] |
287 | 324 | packages = self._data.get('packages') | 321 | packages = self._data.get('packages') |
288 | 325 | if packages: | 322 | if packages: |
290 | 326 | for package_key, package in packages.items(): | 323 | for package_key, package in list(packages.items()): |
291 | 327 | result.append(KernelPackageEntry(self._ks, self, package_key, package)) | 324 | result.append(KernelPackageEntry(self._ks, self, package_key, package)) |
292 | 328 | return result | 325 | return result |
293 | 329 | 326 | ||
294 | @@ -339,7 +336,7 @@ | |||
295 | 339 | result = [] | 336 | result = [] |
296 | 340 | snaps = self._data.get('snaps') | 337 | snaps = self._data.get('snaps') |
297 | 341 | if snaps: | 338 | if snaps: |
299 | 342 | for snap_key, snap in snaps.items(): | 339 | for snap_key, snap in list(snaps.items()): |
300 | 343 | result.append(KernelSnapEntry(self._ks, self, snap_key, snap)) | 340 | result.append(KernelSnapEntry(self._ks, self, snap_key, snap)) |
301 | 344 | return result | 341 | return result |
302 | 345 | 342 | ||
303 | @@ -524,7 +521,7 @@ | |||
304 | 524 | result = [] | 521 | result = [] |
305 | 525 | sources = self._data.get('sources') | 522 | sources = self._data.get('sources') |
306 | 526 | if sources: | 523 | if sources: |
308 | 527 | for source_key, source in sources.items(): | 524 | for source_key, source in list(sources.items()): |
309 | 528 | result.append(KernelSourceEntry( | 525 | result.append(KernelSourceEntry( |
310 | 529 | self._ks, self, source_key, source)) | 526 | self._ks, self, source_key, source)) |
311 | 530 | return result | 527 | return result |
312 | @@ -574,7 +571,7 @@ | |||
313 | 574 | 571 | ||
314 | 575 | self._development_series = None | 572 | self._development_series = None |
315 | 576 | self._codename_to_series = {} | 573 | self._codename_to_series = {} |
317 | 577 | for series_key, series in self._data.items(): | 574 | for series_key, series in list(self._data.items()): |
318 | 578 | if not series: | 575 | if not series: |
319 | 579 | continue | 576 | continue |
320 | 580 | if series.get('development', False): | 577 | if series.get('development', False): |
321 | @@ -596,7 +593,7 @@ | |||
322 | 596 | def series(self): | 593 | def series(self): |
323 | 597 | return [KernelSeriesEntry(self, series_key, series, | 594 | return [KernelSeriesEntry(self, series_key, series, |
324 | 598 | defaults=self._defaults_series) | 595 | defaults=self._defaults_series) |
326 | 599 | for series_key, series in self._data.items()] | 596 | for series_key, series in list(self._data.items())] |
327 | 600 | 597 | ||
328 | 601 | def lookup_series(self, series=None, codename=None, development=False): | 598 | def lookup_series(self, series=None, codename=None, development=False): |
329 | 602 | if not series and not codename and not development: | 599 | if not series and not codename and not development: |
330 | 603 | 600 | ||
331 | === modified file 'list-builds-on-tracker' | |||
332 | --- list-builds-on-tracker 2020-01-25 02:19:13 +0000 | |||
333 | +++ list-builds-on-tracker 2020-11-02 20:20:51 +0000 | |||
334 | @@ -1,4 +1,4 @@ | |||
336 | 1 | #!/usr/bin/python2.7 | 1 | #!/usr/bin/python3 |
337 | 2 | # Copyright (C) 2012 Canonical Ltd. | 2 | # Copyright (C) 2012 Canonical Ltd. |
338 | 3 | 3 | ||
339 | 4 | # This program is free software: you can redistribute it and/or modify | 4 | # This program is free software: you can redistribute it and/or modify |
340 | 5 | 5 | ||
341 | === modified file 'nbs-report' | |||
342 | --- nbs-report 2020-10-23 15:03:51 +0000 | |||
343 | +++ nbs-report 2020-11-02 20:20:51 +0000 | |||
344 | @@ -1,4 +1,4 @@ | |||
346 | 1 | #!/usr/bin/python2.7 | 1 | #!/usr/bin/python3 |
347 | 2 | 2 | ||
348 | 3 | # Copyright (C) 2011, 2012 Canonical Ltd. | 3 | # Copyright (C) 2011, 2012 Canonical Ltd. |
349 | 4 | # Author: Martin Pitt <martin.pitt@ubuntu.com> | 4 | # Author: Martin Pitt <martin.pitt@ubuntu.com> |
350 | @@ -19,8 +19,6 @@ | |||
351 | 19 | # Generate a HTML report of current NBS binary packages from a checkrdepends | 19 | # Generate a HTML report of current NBS binary packages from a checkrdepends |
352 | 20 | # output directory | 20 | # output directory |
353 | 21 | 21 | ||
354 | 22 | from __future__ import print_function | ||
355 | 23 | |||
356 | 24 | from collections import defaultdict | 22 | from collections import defaultdict |
357 | 25 | import csv | 23 | import csv |
358 | 26 | from optparse import OptionParser | 24 | from optparse import OptionParser |
359 | 27 | 25 | ||
360 | === modified file 'orphaned-sources' | |||
361 | --- orphaned-sources 2020-01-25 02:19:13 +0000 | |||
362 | +++ orphaned-sources 2020-11-02 20:20:51 +0000 | |||
363 | @@ -1,6 +1,4 @@ | |||
367 | 1 | #! /usr/bin/python2.7 | 1 | #! /usr/bin/python3 |
365 | 2 | |||
366 | 3 | from __future__ import print_function | ||
368 | 4 | 2 | ||
369 | 5 | import atexit | 3 | import atexit |
370 | 6 | from contextlib import closing | 4 | from contextlib import closing |
371 | @@ -9,10 +7,8 @@ | |||
372 | 9 | import shutil | 7 | import shutil |
373 | 10 | import sys | 8 | import sys |
374 | 11 | import tempfile | 9 | import tempfile |
379 | 12 | try: | 10 | |
380 | 13 | from urllib.request import urlretrieve | 11 | from urllib.request import urlretrieve |
377 | 14 | except ImportError: | ||
378 | 15 | from urllib import urlretrieve | ||
381 | 16 | 12 | ||
382 | 17 | import apt_pkg | 13 | import apt_pkg |
383 | 18 | from launchpadlib.launchpad import Launchpad | 14 | from launchpadlib.launchpad import Launchpad |
384 | 19 | 15 | ||
385 | === modified file 'package-subscribers' | |||
386 | --- package-subscribers 2020-07-23 08:22:44 +0000 | |||
387 | +++ package-subscribers 2020-11-02 20:20:51 +0000 | |||
388 | @@ -1,6 +1,4 @@ | |||
392 | 1 | #! /usr/bin/python2.7 | 1 | #! /usr/bin/python3 |
390 | 2 | |||
391 | 3 | from __future__ import print_function | ||
393 | 4 | 2 | ||
394 | 5 | import atexit | 3 | import atexit |
395 | 6 | import bz2 | 4 | import bz2 |
396 | 7 | 5 | ||
397 | === modified file 'packageset-report' | |||
398 | --- packageset-report 2020-01-25 02:19:13 +0000 | |||
399 | +++ packageset-report 2020-11-02 20:20:51 +0000 | |||
400 | @@ -1,4 +1,4 @@ | |||
402 | 1 | #!/usr/bin/python2.7 | 1 | #!/usr/bin/python3 |
403 | 2 | # -*- coding: utf-8 -*- | 2 | # -*- coding: utf-8 -*- |
404 | 3 | 3 | ||
405 | 4 | # Copyright (C) 2013 Canonical Ltd. | 4 | # Copyright (C) 2013 Canonical Ltd. |
406 | 5 | 5 | ||
407 | === modified file 'pocket-mismatches' | |||
408 | --- pocket-mismatches 2020-01-25 02:19:13 +0000 | |||
409 | +++ pocket-mismatches 2020-11-02 20:20:51 +0000 | |||
410 | @@ -1,4 +1,4 @@ | |||
412 | 1 | #!/usr/bin/env python2.7 | 1 | #!/usr/bin/python3 |
413 | 2 | 2 | ||
414 | 3 | # Check for override mismatches between pockets | 3 | # Check for override mismatches between pockets |
415 | 4 | # Copyright (C) 2005, 2008, 2011, 2012 Canonical Ltd. | 4 | # Copyright (C) 2005, 2008, 2011, 2012 Canonical Ltd. |
416 | @@ -18,8 +18,6 @@ | |||
417 | 18 | # along with this program; if not, write to the Free Software | 18 | # along with this program; if not, write to the Free Software |
418 | 19 | # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 19 | # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
419 | 20 | 20 | ||
420 | 21 | from __future__ import print_function | ||
421 | 22 | |||
422 | 23 | import atexit | 21 | import atexit |
423 | 24 | from collections import defaultdict | 22 | from collections import defaultdict |
424 | 25 | import gzip | 23 | import gzip |
425 | 26 | 24 | ||
426 | === modified file 'point-release-snapshot' | |||
427 | --- point-release-snapshot 2020-01-25 02:19:13 +0000 | |||
428 | +++ point-release-snapshot 2020-11-02 20:20:51 +0000 | |||
429 | @@ -1,6 +1,4 @@ | |||
433 | 1 | #! /usr/bin/env python2.7 | 1 | #! /usr/bin/python3 |
431 | 2 | |||
432 | 3 | from __future__ import print_function | ||
434 | 4 | 2 | ||
435 | 5 | from optparse import OptionParser | 3 | from optparse import OptionParser |
436 | 6 | import os | 4 | import os |
437 | 7 | 5 | ||
438 | === modified file 'post-amis-to-iso-tracker' | |||
439 | --- post-amis-to-iso-tracker 2020-01-25 02:19:13 +0000 | |||
440 | +++ post-amis-to-iso-tracker 2020-11-02 20:20:51 +0000 | |||
441 | @@ -1,4 +1,4 @@ | |||
443 | 1 | #! /usr/bin/python2.7 | 1 | #! /usr/bin/python3 |
444 | 2 | 2 | ||
445 | 3 | # Copyright (C) 2010, 2011, 2012 Canonical Ltd. | 3 | # Copyright (C) 2010, 2011, 2012 Canonical Ltd. |
446 | 4 | 4 | ||
447 | @@ -14,8 +14,6 @@ | |||
448 | 14 | # You should have received a copy of the GNU General Public License | 14 | # You should have received a copy of the GNU General Public License |
449 | 15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | 15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
450 | 16 | 16 | ||
451 | 17 | from __future__ import print_function | ||
452 | 18 | |||
453 | 19 | import argparse | 17 | import argparse |
454 | 20 | import os | 18 | import os |
455 | 21 | import sys | 19 | import sys |
456 | 22 | 20 | ||
457 | === modified file 'post-image-to-iso-tracker' | |||
458 | --- post-image-to-iso-tracker 2020-01-25 02:19:13 +0000 | |||
459 | +++ post-image-to-iso-tracker 2020-11-02 20:20:51 +0000 | |||
460 | @@ -1,4 +1,4 @@ | |||
462 | 1 | #!/usr/bin/python2.7 | 1 | #!/usr/bin/python3 |
463 | 2 | 2 | ||
464 | 3 | # Copyright (C) 2011 Canonical Ltd. | 3 | # Copyright (C) 2011 Canonical Ltd. |
465 | 4 | # Author: Colin Watson <cjwatson@ubuntu.com> | 4 | # Author: Colin Watson <cjwatson@ubuntu.com> |
466 | 5 | 5 | ||
467 | === modified file 'priority-mismatches' | |||
468 | --- priority-mismatches 2020-01-25 02:19:13 +0000 | |||
469 | +++ priority-mismatches 2020-11-02 20:20:51 +0000 | |||
470 | @@ -1,4 +1,4 @@ | |||
472 | 1 | #!/usr/bin/env python2.7 | 1 | #!/usr/bin/python3 |
473 | 2 | 2 | ||
474 | 3 | # Synchronise package priorities with germinate output | 3 | # Synchronise package priorities with germinate output |
475 | 4 | # Copyright (C) 2005, 2009, 2010, 2011, 2012 Canonical Ltd. | 4 | # Copyright (C) 2005, 2009, 2010, 2011, 2012 Canonical Ltd. |
476 | @@ -25,8 +25,6 @@ | |||
477 | 25 | # i386, ia64, m68k, mips, mipsel, powerpc, s390, sparc | 25 | # i386, ia64, m68k, mips, mipsel, powerpc, s390, sparc |
478 | 26 | # <elmo> I hid it in the pool, being the cunning cabalist that I am | 26 | # <elmo> I hid it in the pool, being the cunning cabalist that I am |
479 | 27 | 27 | ||
480 | 28 | from __future__ import print_function | ||
481 | 29 | |||
482 | 30 | import atexit | 28 | import atexit |
483 | 31 | from collections import defaultdict | 29 | from collections import defaultdict |
484 | 32 | import csv | 30 | import csv |
485 | @@ -144,7 +142,7 @@ | |||
486 | 144 | important_pkgs = [ | 142 | important_pkgs = [ |
487 | 145 | pkg for pkg in important_pkgs if not re_not_base.match(pkg)] | 143 | pkg for pkg in important_pkgs if not re_not_base.match(pkg)] |
488 | 146 | if standard_seed is not None: | 144 | if standard_seed is not None: |
490 | 147 | standard_pkgs = read_germinate(suite, arch, standard_seed).keys() | 145 | standard_pkgs = list(read_germinate(suite, arch, standard_seed).keys()) |
491 | 148 | required_pkgs.sort() | 146 | required_pkgs.sort() |
492 | 149 | important_pkgs.sort() | 147 | important_pkgs.sort() |
493 | 150 | standard_pkgs.sort() | 148 | standard_pkgs.sort() |
494 | 151 | 149 | ||
495 | === modified file 'promote-to-release' | |||
496 | --- promote-to-release 2020-01-25 02:19:13 +0000 | |||
497 | +++ promote-to-release 2020-11-02 20:20:51 +0000 | |||
498 | @@ -1,4 +1,4 @@ | |||
500 | 1 | #! /usr/bin/python2.7 | 1 | #! /usr/bin/python3 |
501 | 2 | 2 | ||
502 | 3 | # Copyright (C) 2012 Canonical Ltd. | 3 | # Copyright (C) 2012 Canonical Ltd. |
503 | 4 | # Author: Colin Watson <cjwatson@ubuntu.com> | 4 | # Author: Colin Watson <cjwatson@ubuntu.com> |
504 | @@ -17,8 +17,6 @@ | |||
505 | 17 | 17 | ||
506 | 18 | """Promote packages to release pocket based on britney output.""" | 18 | """Promote packages to release pocket based on britney output.""" |
507 | 19 | 19 | ||
508 | 20 | from __future__ import print_function | ||
509 | 21 | |||
510 | 22 | from optparse import OptionParser | 20 | from optparse import OptionParser |
511 | 23 | import sys | 21 | import sys |
512 | 24 | 22 | ||
513 | 25 | 23 | ||
514 | === modified file 'publish-image-set' | |||
515 | --- publish-image-set 2020-10-21 12:47:17 +0000 | |||
516 | +++ publish-image-set 2020-11-02 20:20:51 +0000 | |||
517 | @@ -1,4 +1,4 @@ | |||
519 | 1 | #!/usr/bin/python2.7 | 1 | #!/usr/bin/python3 |
520 | 2 | # -*- coding: utf-8 -*- | 2 | # -*- coding: utf-8 -*- |
521 | 3 | 3 | ||
522 | 4 | # Copyright (C) 2010, 2011, 2012 Canonical Ltd. | 4 | # Copyright (C) 2010, 2011, 2012 Canonical Ltd. |
523 | @@ -32,8 +32,6 @@ | |||
524 | 32 | # <releaseflag>: yes/no/poolonly/named (should appear on releases.u.c.?) | 32 | # <releaseflag>: yes/no/poolonly/named (should appear on releases.u.c.?) |
525 | 33 | # <name>: name of the release (alpha-2, beta, etc.) | 33 | # <name>: name of the release (alpha-2, beta, etc.) |
526 | 34 | 34 | ||
527 | 35 | from __future__ import print_function | ||
528 | 36 | |||
529 | 37 | from collections import defaultdict | 35 | from collections import defaultdict |
530 | 38 | import optparse | 36 | import optparse |
531 | 39 | import re | 37 | import re |
532 | @@ -183,7 +181,7 @@ | |||
533 | 183 | project = 'ubuntu' | 181 | project = 'ubuntu' |
534 | 184 | if 'Preinstalled' in product: | 182 | if 'Preinstalled' in product: |
535 | 185 | type = 'preinstalled-%s' % type | 183 | type = 'preinstalled-%s' % type |
537 | 186 | if (ms.series_string == u'Focal' and | 184 | if (ms.series_string == 'Focal' and |
538 | 187 | project == 'ubuntu' and type == 'server'): | 185 | project == 'ubuntu' and type == 'server'): |
539 | 188 | project = 'ubuntu-server' | 186 | project = 'ubuntu-server' |
540 | 189 | type = 'legacy-server' | 187 | type = 'legacy-server' |
541 | @@ -306,9 +304,9 @@ | |||
542 | 306 | 304 | ||
543 | 307 | print('\n## publish images:') | 305 | print('\n## publish images:') |
544 | 308 | source_milestone = None | 306 | source_milestone = None |
548 | 309 | for project, builds in info['build_map'].items(): | 307 | for project, builds in list(info['build_map'].items()): |
549 | 310 | for type, buildstamps in builds.items(): | 308 | for type, buildstamps in list(builds.items()): |
550 | 311 | for buildstamp, arches in buildstamps.items(): | 309 | for buildstamp, arches in list(buildstamps.items()): |
551 | 312 | do_publish_release(opts, project, type, buildstamp, arches, | 310 | do_publish_release(opts, project, type, buildstamp, arches, |
552 | 313 | info['milestone_code'], info['stable']) | 311 | info['milestone_code'], info['stable']) |
553 | 314 | source_milestone = info['milestone_code'] | 312 | source_milestone = info['milestone_code'] |
554 | 315 | 313 | ||
555 | === modified file 'queuediff' | |||
556 | --- queuediff 2020-10-23 19:29:46 +0000 | |||
557 | +++ queuediff 2020-11-02 20:20:51 +0000 | |||
558 | @@ -1,4 +1,4 @@ | |||
560 | 1 | #!/usr/bin/python2.7 | 1 | #!/usr/bin/python3 |
561 | 2 | 2 | ||
562 | 3 | # Copyright (C) 2009, 2010, 2011, 2012 Canonical Ltd. | 3 | # Copyright (C) 2009, 2010, 2011, 2012 Canonical Ltd. |
563 | 4 | # Copyright (C) 2010 Scott Kitterman <scott@kitterman.com> | 4 | # Copyright (C) 2010 Scott Kitterman <scott@kitterman.com> |
564 | @@ -25,17 +25,14 @@ | |||
565 | 25 | queuediff -s hardy -b hal | view - | 25 | queuediff -s hardy -b hal | view - |
566 | 26 | ''' | 26 | ''' |
567 | 27 | 27 | ||
568 | 28 | from __future__ import print_function | ||
569 | 29 | |||
570 | 30 | import gzip | 28 | import gzip |
571 | 31 | import optparse | 29 | import optparse |
572 | 32 | import re | 30 | import re |
573 | 33 | import sys | 31 | import sys |
579 | 34 | try: | 32 | |
580 | 35 | from urllib.parse import quote | 33 | from urllib.parse import quote |
581 | 36 | from urllib.request import urlopen, urlretrieve | 34 | from urllib.request import urlopen, urlretrieve |
582 | 37 | except ImportError: | 35 | |
578 | 38 | from urllib import quote, urlopen, urlretrieve | ||
583 | 39 | import webbrowser | 36 | import webbrowser |
584 | 40 | 37 | ||
585 | 41 | from launchpadlib.launchpad import Launchpad | 38 | from launchpadlib.launchpad import Launchpad |
586 | 42 | 39 | ||
587 | === modified file 'regression-proposed-bug-search' | |||
588 | --- regression-proposed-bug-search 2020-01-25 02:19:13 +0000 | |||
589 | +++ regression-proposed-bug-search 2020-11-02 20:20:51 +0000 | |||
590 | @@ -1,4 +1,4 @@ | |||
592 | 1 | #!/usr/bin/python2.7 | 1 | #!/usr/bin/python3 |
593 | 2 | 2 | ||
594 | 3 | # Copyright (C) 2012 Canonical, Ltd. | 3 | # Copyright (C) 2012 Canonical, Ltd. |
595 | 4 | # Author: Brian Murray <brian@canonical.com> | 4 | # Author: Brian Murray <brian@canonical.com> |
596 | @@ -20,16 +20,11 @@ | |||
597 | 20 | # since the date the package was uploaded to proposed for apport and release | 20 | # since the date the package was uploaded to proposed for apport and release |
598 | 21 | # tagged bugs that contain the version of the package from -proposed | 21 | # tagged bugs that contain the version of the package from -proposed |
599 | 22 | 22 | ||
600 | 23 | from __future__ import print_function | ||
601 | 24 | |||
602 | 25 | import optparse | 23 | import optparse |
603 | 26 | 24 | ||
604 | 27 | from launchpadlib.launchpad import Launchpad | 25 | from launchpadlib.launchpad import Launchpad |
605 | 28 | 26 | ||
610 | 29 | try: | 27 | from urllib.request import urlopen |
607 | 30 | from urllib.request import urlopen | ||
608 | 31 | except ImportError: | ||
609 | 32 | from urllib import urlopen | ||
611 | 33 | 28 | ||
612 | 34 | 29 | ||
613 | 35 | def bugs_from_changes(change_url): | 30 | def bugs_from_changes(change_url): |
614 | 36 | 31 | ||
615 | === modified file 'rescore-ppa-builds' | |||
616 | --- rescore-ppa-builds 2020-01-25 02:19:13 +0000 | |||
617 | +++ rescore-ppa-builds 2020-11-02 20:20:51 +0000 | |||
618 | @@ -1,4 +1,4 @@ | |||
620 | 1 | #!/usr/bin/python2.7 | 1 | #!/usr/bin/python3 |
621 | 2 | # Rescore all builds in a PPA. | 2 | # Rescore all builds in a PPA. |
622 | 3 | # | 3 | # |
623 | 4 | # Copyright (C) 2012 Canonical Ltd. | 4 | # Copyright (C) 2012 Canonical Ltd. |
624 | @@ -16,8 +16,6 @@ | |||
625 | 16 | # You should have received a copy of the GNU General Public License | 16 | # You should have received a copy of the GNU General Public License |
626 | 17 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | 17 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
627 | 18 | 18 | ||
628 | 19 | from __future__ import print_function | ||
629 | 20 | |||
630 | 21 | from optparse import OptionParser | 19 | from optparse import OptionParser |
631 | 22 | 20 | ||
632 | 23 | from launchpadlib.launchpad import Launchpad | 21 | from launchpadlib.launchpad import Launchpad |
633 | 24 | 22 | ||
634 | === modified file 'sync-blacklist' | |||
635 | --- sync-blacklist 2020-01-25 02:19:13 +0000 | |||
636 | +++ sync-blacklist 2020-11-02 20:20:51 +0000 | |||
637 | @@ -1,4 +1,4 @@ | |||
639 | 1 | #!/usr/bin/python2.7 | 1 | #!/usr/bin/python3 |
640 | 2 | 2 | ||
641 | 3 | # Copyright (C) 2011 Iain Lane | 3 | # Copyright (C) 2011 Iain Lane |
642 | 4 | # Copyright (C) 2011 Stefano Rivera | 4 | # Copyright (C) 2011 Stefano Rivera |
643 | @@ -15,8 +15,6 @@ | |||
644 | 15 | # You should have received a copy of the GNU General Public License | 15 | # You should have received a copy of the GNU General Public License |
645 | 16 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | 16 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
646 | 17 | 17 | ||
647 | 18 | from __future__ import print_function, unicode_literals | ||
648 | 19 | |||
649 | 20 | from optparse import OptionParser | 18 | from optparse import OptionParser |
650 | 21 | 19 | ||
651 | 22 | from launchpadlib.launchpad import Launchpad | 20 | from launchpadlib.launchpad import Launchpad |
652 | 23 | 21 | ||
653 | === modified file 'utils.py' | |||
654 | --- utils.py 2020-01-25 02:19:13 +0000 | |||
655 | +++ utils.py 2020-11-02 20:20:51 +0000 | |||
656 | @@ -1,4 +1,4 @@ | |||
658 | 1 | #!/usr/bin/python2.7 | 1 | #!/usr/bin/python3 |
659 | 2 | 2 | ||
660 | 3 | # Copyright (C) 2019 Canonical Ltd. | 3 | # Copyright (C) 2019 Canonical Ltd. |
661 | 4 | # Author: Brian Murray <brian.murray@canonical.com> | 4 | # Author: Brian Murray <brian.murray@canonical.com> |