Merge lp:~jelmer/bzr-builddeb/multi-tarball-pt8 into lp:bzr-builddeb
- multi-tarball-pt8
- Merge into trunk
Proposed by
Jelmer Vernooij
Status: | Superseded |
---|---|
Proposed branch: | lp:~jelmer/bzr-builddeb/multi-tarball-pt8 |
Merge into: | lp:bzr-builddeb |
Diff against target: |
635 lines (+157/-145) 4 files modified
cmds.py (+1/-1) import_dsc.py (+86/-103) tests/test_import_dsc.py (+26/-26) upstream/pristinetar.py (+44/-15) |
To merge this branch: | bzr merge lp:~jelmer/bzr-builddeb/multi-tarball-pt8 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Bzr-builddeb-hackers | Pending | ||
Review via email: mp+68224@code.launchpad.net |
This proposal has been superseded by a proposal from 2011-07-18.
Commit message
Description of the change
To post a comment you must log in.
Unmerged revisions
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'cmds.py' | |||
2 | --- cmds.py 2011-06-28 08:41:44 +0000 | |||
3 | +++ cmds.py 2011-07-18 10:01:28 +0000 | |||
4 | @@ -964,7 +964,7 @@ | |||
5 | 964 | db.extract_upstream_tree(parents[0], tempdir) | 964 | db.extract_upstream_tree(parents[0], tempdir) |
6 | 965 | else: | 965 | else: |
7 | 966 | db._create_empty_upstream_tree(tempdir) | 966 | db._create_empty_upstream_tree(tempdir) |
9 | 967 | tree = db.get_branch_tip_revtree() | 967 | tree = db.branch.basis_tree() |
10 | 968 | tree.lock_read() | 968 | tree.lock_read() |
11 | 969 | dbs = DistributionBranchSet() | 969 | dbs = DistributionBranchSet() |
12 | 970 | dbs.add_branch(db) | 970 | dbs.add_branch(db) |
13 | 971 | 971 | ||
14 | === modified file 'import_dsc.py' | |||
15 | --- import_dsc.py 2011-06-28 08:41:44 +0000 | |||
16 | +++ import_dsc.py 2011-07-18 10:01:28 +0000 | |||
17 | @@ -277,25 +277,25 @@ | |||
18 | 277 | return str(version) | 277 | return str(version) |
19 | 278 | 278 | ||
20 | 279 | def _has_version(self, branch, tag_name, md5=None): | 279 | def _has_version(self, branch, tag_name, md5=None): |
40 | 280 | if branch.tags.has_tag(tag_name): | 280 | if not branch.tags.has_tag(tag_name): |
41 | 281 | revid = branch.tags.lookup_tag(tag_name) | 281 | return False |
42 | 282 | branch.lock_read() | 282 | revid = branch.tags.lookup_tag(tag_name) |
43 | 283 | try: | 283 | branch.lock_read() |
44 | 284 | graph = branch.repository.get_graph() | 284 | try: |
45 | 285 | if not graph.is_ancestor(revid, branch.last_revision()): | 285 | graph = branch.repository.get_graph() |
46 | 286 | return False | 286 | if not graph.is_ancestor(revid, branch.last_revision()): |
47 | 287 | finally: | 287 | return False |
48 | 288 | branch.unlock() | 288 | finally: |
49 | 289 | if md5 is None: | 289 | branch.unlock() |
50 | 290 | return True | 290 | if md5 is None: |
51 | 291 | rev = branch.repository.get_revision(revid) | 291 | return True |
52 | 292 | try: | 292 | rev = branch.repository.get_revision(revid) |
53 | 293 | return rev.properties['deb-md5'] == md5 | 293 | try: |
54 | 294 | except KeyError: | 294 | return rev.properties['deb-md5'] == md5 |
55 | 295 | warning("tag %s present in branch, but there is no " | 295 | except KeyError: |
56 | 296 | "associated 'deb-md5' property" % tag_name) | 296 | warning("tag %s present in branch, but there is no " |
57 | 297 | pass | 297 | "associated 'deb-md5' property" % tag_name) |
58 | 298 | return False | 298 | return False |
59 | 299 | 299 | ||
60 | 300 | def has_version(self, version, md5=None): | 300 | def has_version(self, version, md5=None): |
61 | 301 | """Whether this branch contains the package version specified. | 301 | """Whether this branch contains the package version specified. |
62 | @@ -409,18 +409,6 @@ | |||
63 | 409 | return self.branch.tags.lookup_tag(ubuntu_tag_name) | 409 | return self.branch.tags.lookup_tag(ubuntu_tag_name) |
64 | 410 | return self.branch.tags.lookup_tag(tag_name) | 410 | return self.branch.tags.lookup_tag(tag_name) |
65 | 411 | 411 | ||
66 | 412 | def revid_of_upstream_version(self, package, version, tarballs=None): | ||
67 | 413 | """Returns the revision id corresponding to the upstream version. | ||
68 | 414 | |||
69 | 415 | :param version: the Version object to extract the upstream version | ||
70 | 416 | from to retrieve the revid of. The upstream version must be | ||
71 | 417 | present in the upstream branch. | ||
72 | 418 | :return: the revision id corresponding to the upstream portion | ||
73 | 419 | of the version | ||
74 | 420 | """ | ||
75 | 421 | return self.pristine_upstream_source.version_as_revision(package, version, | ||
76 | 422 | tarballs) | ||
77 | 423 | |||
78 | 424 | def tag_version(self, version, revid=None): | 412 | def tag_version(self, version, revid=None): |
79 | 425 | """Tags the branch's last revision with the given version. | 413 | """Tags the branch's last revision with the given version. |
80 | 426 | 414 | ||
81 | @@ -506,6 +494,21 @@ | |||
82 | 506 | except KeyError: | 494 | except KeyError: |
83 | 507 | return False | 495 | return False |
84 | 508 | 496 | ||
85 | 497 | def can_pull_from_branch(self, branch, version, md5): | ||
86 | 498 | if not branch.has_version(version, md5=md5): | ||
87 | 499 | return False | ||
88 | 500 | |||
89 | 501 | # Check that they haven't diverged | ||
90 | 502 | branch.branch.lock_read() | ||
91 | 503 | try: | ||
92 | 504 | graph = branch.branch.repository.get_graph( | ||
93 | 505 | self.branch.repository) | ||
94 | 506 | return graph.is_ancestor(self.branch.last_revision(), | ||
95 | 507 | branch.revid_of_version(version)) | ||
96 | 508 | finally: | ||
97 | 509 | branch.branch.unlock() | ||
98 | 510 | |||
99 | 511 | |||
100 | 509 | def branch_to_pull_version_from(self, version, md5): | 512 | def branch_to_pull_version_from(self, version, md5): |
101 | 510 | """Checks whether this upload is a pull from a lesser branch. | 513 | """Checks whether this upload is a pull from a lesser branch. |
102 | 511 | 514 | ||
103 | @@ -531,29 +534,11 @@ | |||
104 | 531 | self.branch.lock_read() | 534 | self.branch.lock_read() |
105 | 532 | try: | 535 | try: |
106 | 533 | for branch in reversed(self.get_lesser_branches()): | 536 | for branch in reversed(self.get_lesser_branches()): |
118 | 534 | if branch.has_version(version, md5=md5): | 537 | if self.can_pull_from_branch(branch, version, md5): |
119 | 535 | # Check that they haven't diverged | 538 | return branch |
109 | 536 | branch.branch.lock_read() | ||
110 | 537 | try: | ||
111 | 538 | graph = branch.branch.repository.get_graph( | ||
112 | 539 | self.branch.repository) | ||
113 | 540 | if graph.is_ancestor(self.branch.last_revision(), | ||
114 | 541 | branch.revid_of_version(version)): | ||
115 | 542 | return branch | ||
116 | 543 | finally: | ||
117 | 544 | branch.branch.unlock() | ||
120 | 545 | for branch in self.get_greater_branches(): | 539 | for branch in self.get_greater_branches(): |
132 | 546 | if branch.has_version(version, md5=md5): | 540 | if self.can_pull_from_branch(branch, version, md5): |
133 | 547 | # Check that they haven't diverged | 541 | return branch |
123 | 548 | branch.branch.lock_read() | ||
124 | 549 | try: | ||
125 | 550 | graph = branch.branch.repository.get_graph( | ||
126 | 551 | self.branch.repository) | ||
127 | 552 | if graph.is_ancestor(self.branch.last_revision(), | ||
128 | 553 | branch.revid_of_version(version)): | ||
129 | 554 | return branch | ||
130 | 555 | finally: | ||
131 | 556 | branch.branch.unlock() | ||
134 | 557 | return None | 542 | return None |
135 | 558 | finally: | 543 | finally: |
136 | 559 | self.branch.unlock() | 544 | self.branch.unlock() |
137 | @@ -581,7 +566,7 @@ | |||
138 | 581 | graph = other_up_branch.repository.get_graph( | 566 | graph = other_up_branch.repository.get_graph( |
139 | 582 | up_branch.repository) | 567 | up_branch.repository) |
140 | 583 | return graph.is_ancestor(up_branch.last_revision(), | 568 | return graph.is_ancestor(up_branch.last_revision(), |
142 | 584 | branch.revid_of_upstream_version(package, version)) | 569 | branch.pristine_upstream_source.version_as_revision(package, version)) |
143 | 585 | finally: | 570 | finally: |
144 | 586 | other_up_branch.unlock() | 571 | other_up_branch.unlock() |
145 | 587 | finally: | 572 | finally: |
146 | @@ -695,7 +680,7 @@ | |||
147 | 695 | :param version: the upstream version string | 680 | :param version: the upstream version string |
148 | 696 | """ | 681 | """ |
149 | 697 | assert isinstance(version, str) | 682 | assert isinstance(version, str) |
151 | 698 | pull_revision = pull_branch.revid_of_upstream_version(package, version) | 683 | pull_revision = pull_branch.pristine_upstream_source.version_as_revision(package, version) |
152 | 699 | mutter("Pulling upstream part of %s from revision %s" % \ | 684 | mutter("Pulling upstream part of %s from revision %s" % \ |
153 | 700 | (version, pull_revision)) | 685 | (version, pull_revision)) |
154 | 701 | assert self.pristine_upstream_tree is not None, \ | 686 | assert self.pristine_upstream_tree is not None, \ |
155 | @@ -753,7 +738,7 @@ | |||
156 | 753 | "present in the upstream branch") | 738 | "present in the upstream branch") |
157 | 754 | 739 | ||
158 | 755 | def get_parents_with_upstream(self, package, version, versions, | 740 | def get_parents_with_upstream(self, package, version, versions, |
160 | 756 | force_upstream_parent=False): | 741 | tarballs, force_upstream_parent=False): |
161 | 757 | """Get the list of parents including any upstream parents. | 742 | """Get the list of parents including any upstream parents. |
162 | 758 | 743 | ||
163 | 759 | Further to get_parents this method includes any upstream parents | 744 | Further to get_parents this method includes any upstream parents |
164 | @@ -765,7 +750,7 @@ | |||
165 | 765 | If force_upstream_parent is True then the upstream parent will | 750 | If force_upstream_parent is True then the upstream parent will |
166 | 766 | be included, even if another parent is already using that | 751 | be included, even if another parent is already using that |
167 | 767 | upstream. This is for use in cases where the .orig.tar.gz | 752 | upstream. This is for use in cases where the .orig.tar.gz |
169 | 768 | is different in two ditributions. | 753 | is different in two distributions. |
170 | 769 | 754 | ||
171 | 770 | :param version: the Version that we are currently importing. | 755 | :param version: the Version that we are currently importing. |
172 | 771 | :param versions: the list of Versions that are ancestors of | 756 | :param versions: the list of Versions that are ancestors of |
173 | @@ -789,8 +774,8 @@ | |||
174 | 789 | break | 774 | break |
175 | 790 | real_parents = [p[2] for p in parents] | 775 | real_parents = [p[2] for p in parents] |
176 | 791 | if need_upstream_parent: | 776 | if need_upstream_parent: |
179 | 792 | parent_revid = self.revid_of_upstream_version(package, | 777 | parent_revid = self.pristine_upstream_source.version_as_revision(package, |
180 | 793 | version.upstream_version) | 778 | version.upstream_version, tarballs) |
181 | 794 | if len(parents) > 0: | 779 | if len(parents) > 0: |
182 | 795 | real_parents.insert(1, parent_revid) | 780 | real_parents.insert(1, parent_revid) |
183 | 796 | else: | 781 | else: |
184 | @@ -833,46 +818,48 @@ | |||
185 | 833 | % (version, upstream_part, str(upstream_parents))) | 818 | % (version, upstream_part, str(upstream_parents))) |
186 | 834 | assert self.pristine_upstream_tree is not None, \ | 819 | assert self.pristine_upstream_tree is not None, \ |
187 | 835 | "Can't import upstream with no tree" | 820 | "Can't import upstream with no tree" |
188 | 836 | if len(upstream_parents) > 0: | ||
189 | 837 | parent_revid = upstream_parents[0] | ||
190 | 838 | else: | ||
191 | 839 | parent_revid = NULL_REVISION | ||
192 | 840 | self.pristine_upstream_tree.pull(self.pristine_upstream_tree.branch, | ||
193 | 841 | overwrite=True, stop_revision=parent_revid) | ||
194 | 842 | other_branches = self.get_other_branches() | 821 | other_branches = self.get_other_branches() |
195 | 843 | upstream_trees = [o.pristine_upstream_branch.basis_tree() | ||
196 | 844 | for o in other_branches] | ||
197 | 845 | target_tree = None | ||
198 | 846 | if upstream_branch is not None: | ||
199 | 847 | if upstream_revision is None: | ||
200 | 848 | upstream_revision = upstream_branch.last_revision() | ||
201 | 849 | self.pristine_upstream_branch.fetch(upstream_branch, | ||
202 | 850 | last_revision=upstream_revision) | ||
203 | 851 | upstream_branch.tags.merge_to(self.pristine_upstream_branch.tags) | ||
204 | 852 | upstream_parents.append(upstream_revision) | ||
205 | 853 | target_tree = self.pristine_upstream_branch.repository.revision_tree( | ||
206 | 854 | upstream_revision) | ||
207 | 855 | if file_ids_from is not None: | ||
208 | 856 | upstream_trees = file_ids_from + upstream_trees | ||
209 | 857 | if self.tree: | ||
210 | 858 | self_tree = self.tree | ||
211 | 859 | self_tree.lock_write() # might also be upstream tree for dh_make | ||
212 | 860 | else: | ||
213 | 861 | self_tree = self.get_branch_tip_revtree() | ||
214 | 862 | self_tree.lock_read() | ||
215 | 863 | try: | ||
216 | 864 | import_dir(self.pristine_upstream_tree, upstream_part, | ||
217 | 865 | file_ids_from=[self_tree] + upstream_trees, | ||
218 | 866 | target_tree=target_tree) | ||
219 | 867 | finally: | ||
220 | 868 | self_tree.unlock() | ||
221 | 869 | revprops = {} | ||
222 | 870 | ret = [] | 822 | ret = [] |
223 | 871 | for (tarball, component, md5) in upstream_tarballs: | 823 | for (tarball, component, md5) in upstream_tarballs: |
224 | 824 | upstream_trees = [o.pristine_upstream_branch.basis_tree() | ||
225 | 825 | for o in other_branches] | ||
226 | 826 | target_tree = None | ||
227 | 827 | if upstream_branch is not None: | ||
228 | 828 | if upstream_revision is None: | ||
229 | 829 | upstream_revision = upstream_branch.last_revision() | ||
230 | 830 | self.pristine_upstream_branch.fetch(upstream_branch, | ||
231 | 831 | last_revision=upstream_revision) | ||
232 | 832 | upstream_branch.tags.merge_to(self.pristine_upstream_branch.tags) | ||
233 | 833 | upstream_parents.append(upstream_revision) | ||
234 | 834 | target_tree = self.pristine_upstream_branch.repository.revision_tree( | ||
235 | 835 | upstream_revision) | ||
236 | 836 | if file_ids_from is not None: | ||
237 | 837 | upstream_trees = file_ids_from + upstream_trees | ||
238 | 838 | if self.tree: | ||
239 | 839 | self_tree = self.tree | ||
240 | 840 | self_tree.lock_write() # might also be upstream tree for dh_make | ||
241 | 841 | else: | ||
242 | 842 | self_tree = self.branch.basis_tree() | ||
243 | 843 | self_tree.lock_read() | ||
244 | 844 | if len(upstream_parents) > 0: | ||
245 | 845 | parent_revid = upstream_parents[0] | ||
246 | 846 | else: | ||
247 | 847 | parent_revid = NULL_REVISION | ||
248 | 848 | self.pristine_upstream_tree.pull(self.pristine_upstream_tree.branch, | ||
249 | 849 | overwrite=True, stop_revision=parent_revid) | ||
250 | 850 | if component is None: | ||
251 | 851 | path = upstream_part | ||
252 | 852 | else: | ||
253 | 853 | path = os.path.join(upstream_part, component) | ||
254 | 854 | try: | ||
255 | 855 | import_dir(self.pristine_upstream_tree, path, | ||
256 | 856 | file_ids_from=[self_tree] + upstream_trees, | ||
257 | 857 | target_tree=target_tree) | ||
258 | 858 | finally: | ||
259 | 859 | self_tree.unlock() | ||
260 | 872 | (tag, revid) = self.pristine_upstream_source.import_component_tarball( | 860 | (tag, revid) = self.pristine_upstream_source.import_component_tarball( |
264 | 873 | package, version, self.pristine_upstream_tree, component, | 861 | package, version, self.pristine_upstream_tree, upstream_parents, component, |
265 | 874 | md5, tarball, author=author, timestamp=timestamp, | 862 | md5, tarball, author=author, timestamp=timestamp) |
263 | 875 | parent_ids=upstream_parents) | ||
266 | 876 | ret.append((component, tag, revid)) | 863 | ret.append((component, tag, revid)) |
267 | 877 | self.branch.fetch(self.pristine_upstream_branch) | 864 | self.branch.fetch(self.pristine_upstream_branch) |
268 | 878 | self.branch.tags.set_tag(tag, revid) | 865 | self.branch.tags.set_tag(tag, revid) |
269 | @@ -902,12 +889,8 @@ | |||
270 | 902 | finally: | 889 | finally: |
271 | 903 | shutil.rmtree(tarball_dir) | 890 | shutil.rmtree(tarball_dir) |
272 | 904 | 891 | ||
273 | 905 | def get_branch_tip_revtree(self): | ||
274 | 906 | return self.branch.repository.revision_tree( | ||
275 | 907 | self.branch.last_revision()) | ||
276 | 908 | |||
277 | 909 | def _mark_native_config(self, native): | 892 | def _mark_native_config(self, native): |
279 | 910 | poss_native_tree = self.get_branch_tip_revtree() | 893 | poss_native_tree = self.branch.basis_tree() |
280 | 911 | current_native = self._is_tree_native(poss_native_tree) | 894 | current_native = self._is_tree_native(poss_native_tree) |
281 | 912 | current_config = self._default_config_for_tree(poss_native_tree) | 895 | current_config = self._default_config_for_tree(poss_native_tree) |
282 | 913 | dirname = os.path.join(self.tree.basedir, '.bzr-builddeb') | 896 | dirname = os.path.join(self.tree.basedir, '.bzr-builddeb') |
283 | @@ -1069,7 +1052,7 @@ | |||
284 | 1069 | pull_branch = pull_parents[1][0] | 1052 | pull_branch = pull_parents[1][0] |
285 | 1070 | pull_version = pull_parents[1][1] | 1053 | pull_version = pull_parents[1][1] |
286 | 1071 | if not pull_branch.is_version_native(pull_version): | 1054 | if not pull_branch.is_version_native(pull_version): |
288 | 1072 | pull_revid = pull_branch.revid_of_upstream_version( | 1055 | pull_revid = pull_branch.pristine_upstream_source.version_as_revision( |
289 | 1073 | package, pull_version.upstream_version) | 1056 | package, pull_version.upstream_version) |
290 | 1074 | mutter("Initialising upstream from %s, version %s", | 1057 | mutter("Initialising upstream from %s, version %s", |
291 | 1075 | str(pull_branch), str(pull_version)) | 1058 | str(pull_branch), str(pull_version)) |
292 | @@ -1142,7 +1125,7 @@ | |||
293 | 1142 | else: | 1125 | else: |
294 | 1143 | mutter("We already have the needed upstream part") | 1126 | mutter("We already have the needed upstream part") |
295 | 1144 | parents = self.get_parents_with_upstream(package, version, versions, | 1127 | parents = self.get_parents_with_upstream(package, version, versions, |
297 | 1145 | force_upstream_parent=imported_upstream) | 1128 | upstream_tarballs, force_upstream_parent=imported_upstream) |
298 | 1146 | # Now we have the list of parents we need to import the .diff.gz | 1129 | # Now we have the list of parents we need to import the .diff.gz |
299 | 1147 | self.import_debian(debian_part, version, parents, md5, | 1130 | self.import_debian(debian_part, version, parents, md5, |
300 | 1148 | timestamp=timestamp, file_ids_from=file_ids_from) | 1131 | timestamp=timestamp, file_ids_from=file_ids_from) |
301 | @@ -1307,7 +1290,7 @@ | |||
302 | 1307 | if self.tree: | 1290 | if self.tree: |
303 | 1308 | root_id = self.tree.path2id('') | 1291 | root_id = self.tree.path2id('') |
304 | 1309 | else: | 1292 | else: |
306 | 1310 | tip = self.get_branch_tip_revtree() | 1293 | tip = self.branch.basis_tree() |
307 | 1311 | tip.lock_read() | 1294 | tip.lock_read() |
308 | 1312 | try: | 1295 | try: |
309 | 1313 | root_id = tip.path2id('') | 1296 | root_id = tip.path2id('') |
310 | 1314 | 1297 | ||
311 | === modified file 'tests/test_import_dsc.py' | |||
312 | --- tests/test_import_dsc.py 2011-06-28 08:41:44 +0000 | |||
313 | +++ tests/test_import_dsc.py 2011-07-18 10:01:28 +0000 | |||
314 | @@ -203,14 +203,14 @@ | |||
315 | 203 | db.tag_version(version) | 203 | db.tag_version(version) |
316 | 204 | self.assertEqual(db.revid_of_version(version), revid) | 204 | self.assertEqual(db.revid_of_version(version), revid) |
317 | 205 | 205 | ||
319 | 206 | def test_revid_of_upstream_version(self): | 206 | def test_upstream_version_as_revid(self): |
320 | 207 | db = self.db1 | 207 | db = self.db1 |
321 | 208 | tree = self.up_tree1 | 208 | tree = self.up_tree1 |
322 | 209 | version = "0.1" | 209 | version = "0.1" |
323 | 210 | revid = tree.commit("one") | 210 | revid = tree.commit("one") |
324 | 211 | db.tag_upstream_version(version) | 211 | db.tag_upstream_version(version) |
325 | 212 | self.assertEqual( | 212 | self.assertEqual( |
327 | 213 | db.revid_of_upstream_version("package", version), revid) | 213 | db.pristine_upstream_source.version_as_revision("package", version), revid) |
328 | 214 | 214 | ||
329 | 215 | def test_contained_versions(self): | 215 | def test_contained_versions(self): |
330 | 216 | db = self.db1 | 216 | db = self.db1 |
331 | @@ -401,13 +401,13 @@ | |||
332 | 401 | up_revid = self.up_tree1.commit("one") | 401 | up_revid = self.up_tree1.commit("one") |
333 | 402 | db.tag_upstream_version(version1.upstream_version) | 402 | db.tag_upstream_version(version1.upstream_version) |
334 | 403 | self.assertEqual( | 403 | self.assertEqual( |
336 | 404 | db.get_parents_with_upstream("package", version1, [version1]), | 404 | db.get_parents_with_upstream("package", version1, [version1], None), |
337 | 405 | [up_revid]) | 405 | [up_revid]) |
338 | 406 | db = self.db2 | 406 | db = self.db2 |
339 | 407 | self.up_tree2.pull(self.up_tree1.branch) | 407 | self.up_tree2.pull(self.up_tree1.branch) |
340 | 408 | db.tag_upstream_version(version1.upstream_version) | 408 | db.tag_upstream_version(version1.upstream_version) |
341 | 409 | self.assertEqual( | 409 | self.assertEqual( |
343 | 410 | db.get_parents_with_upstream("package", version1, [version1]), | 410 | db.get_parents_with_upstream("package", version1, [version1], None), |
344 | 411 | [up_revid]) | 411 | [up_revid]) |
345 | 412 | 412 | ||
346 | 413 | def test_get_parents_with_upstream_second_version(self): | 413 | def test_get_parents_with_upstream_second_version(self): |
347 | @@ -420,7 +420,7 @@ | |||
348 | 420 | db.tag_upstream_version(version1.upstream_version) | 420 | db.tag_upstream_version(version1.upstream_version) |
349 | 421 | # No upstream parent | 421 | # No upstream parent |
350 | 422 | self.assertEqual(db.get_parents_with_upstream( | 422 | self.assertEqual(db.get_parents_with_upstream( |
352 | 423 | "package", version2, [version2, version1]), [revid1]) | 423 | "package", version2, [version2, version1], None), [revid1]) |
353 | 424 | 424 | ||
354 | 425 | def test_get_parents_with_upstream_merge_from_lesser(self): | 425 | def test_get_parents_with_upstream_merge_from_lesser(self): |
355 | 426 | version1 = Version("0.1-1") | 426 | version1 = Version("0.1-1") |
356 | @@ -437,7 +437,7 @@ | |||
357 | 437 | versions = [version3, version1, version2] | 437 | versions = [version3, version1, version2] |
358 | 438 | # No upstream parent | 438 | # No upstream parent |
359 | 439 | self.assertEqual(self.db2.get_parents_with_upstream( | 439 | self.assertEqual(self.db2.get_parents_with_upstream( |
361 | 440 | "package", version3, versions), [revid2, revid1]) | 440 | "package", version3, versions, None), [revid2, revid1]) |
362 | 441 | 441 | ||
363 | 442 | def test_get_parents_with_upstream_merge_from_greater(self): | 442 | def test_get_parents_with_upstream_merge_from_greater(self): |
364 | 443 | version1 = Version("0.1-1") | 443 | version1 = Version("0.1-1") |
365 | @@ -454,7 +454,7 @@ | |||
366 | 454 | versions = [version3, version2, version1] | 454 | versions = [version3, version2, version1] |
367 | 455 | # No upstream parent | 455 | # No upstream parent |
368 | 456 | self.assertEqual(self.db1.get_parents_with_upstream( | 456 | self.assertEqual(self.db1.get_parents_with_upstream( |
370 | 457 | "package", version3, versions), [revid1, revid2]) | 457 | "package", version3, versions, None), [revid1, revid2]) |
371 | 458 | 458 | ||
372 | 459 | def test_get_parents_with_upstream_new_upstream_import(self): | 459 | def test_get_parents_with_upstream_new_upstream_import(self): |
373 | 460 | version1 = Version("0.1-1") | 460 | version1 = Version("0.1-1") |
374 | @@ -470,7 +470,7 @@ | |||
375 | 470 | versions = [version2, version1] | 470 | versions = [version2, version1] |
376 | 471 | # Upstream parent as it is new upstream version | 471 | # Upstream parent as it is new upstream version |
377 | 472 | self.assertEqual(self.db2.get_parents_with_upstream( | 472 | self.assertEqual(self.db2.get_parents_with_upstream( |
379 | 473 | "package", version2, versions), [revid1, up_revid2]) | 473 | "package", version2, versions, None), [revid1, up_revid2]) |
380 | 474 | 474 | ||
381 | 475 | def test_get_parents_merge_new_upstream_from_lesser(self): | 475 | def test_get_parents_merge_new_upstream_from_lesser(self): |
382 | 476 | version1 = Version("0.1-1") | 476 | version1 = Version("0.1-1") |
383 | @@ -494,7 +494,7 @@ | |||
384 | 494 | versions = [version4, version3, version2, version1] | 494 | versions = [version4, version3, version2, version1] |
385 | 495 | # no upstream parent as the lesser branch has already merged it | 495 | # no upstream parent as the lesser branch has already merged it |
386 | 496 | self.assertEqual(self.db2.get_parents_with_upstream( | 496 | self.assertEqual(self.db2.get_parents_with_upstream( |
388 | 497 | "package", version4, versions), [revid2, revid3]) | 497 | "package", version4, versions, None), [revid2, revid3]) |
389 | 498 | 498 | ||
390 | 499 | def test_get_parents_with_upstream_force_upstream(self): | 499 | def test_get_parents_with_upstream_force_upstream(self): |
391 | 500 | version1 = Version("0.1-1") | 500 | version1 = Version("0.1-1") |
392 | @@ -509,7 +509,7 @@ | |||
393 | 509 | # a previous test checked that this wouldn't give an | 509 | # a previous test checked that this wouldn't give an |
394 | 510 | # upstream parent, but we are requiring one. | 510 | # upstream parent, but we are requiring one. |
395 | 511 | self.assertEqual(self.db2.get_parents_with_upstream( | 511 | self.assertEqual(self.db2.get_parents_with_upstream( |
397 | 512 | "package", version2, versions, force_upstream_parent=True), | 512 | "package", version2, versions, None, force_upstream_parent=True), |
398 | 513 | [revid1, up_revid2]) | 513 | [revid1, up_revid2]) |
399 | 514 | 514 | ||
400 | 515 | def test_get_parents_with_upstream_sync_when_diverged(self): | 515 | def test_get_parents_with_upstream_sync_when_diverged(self): |
401 | @@ -530,7 +530,7 @@ | |||
402 | 530 | # This is a sync but we are diverged so we should get two | 530 | # This is a sync but we are diverged so we should get two |
403 | 531 | # parents | 531 | # parents |
404 | 532 | self.assertEqual(self.db2.get_parents_with_upstream( | 532 | self.assertEqual(self.db2.get_parents_with_upstream( |
406 | 533 | "package", version3, versions), [revid2, revid3]) | 533 | "package", version3, versions, None), [revid2, revid3]) |
407 | 534 | 534 | ||
408 | 535 | def test_get_parents_with_upstream_sync_new_upstream(self): | 535 | def test_get_parents_with_upstream_sync_new_upstream(self): |
409 | 536 | version1 = Version("0.1-1") | 536 | version1 = Version("0.1-1") |
410 | @@ -553,7 +553,7 @@ | |||
411 | 553 | # parents. There should be no upstream as the synced | 553 | # parents. There should be no upstream as the synced |
412 | 554 | # version will already have it. | 554 | # version will already have it. |
413 | 555 | self.assertEqual(self.db2.get_parents_with_upstream( | 555 | self.assertEqual(self.db2.get_parents_with_upstream( |
415 | 556 | "package", version3, versions), [revid2, revid3]) | 556 | "package", version3, versions, None), [revid2, revid3]) |
416 | 557 | 557 | ||
417 | 558 | def test_get_parents_with_upstream_sync_new_upstream_force(self): | 558 | def test_get_parents_with_upstream_sync_new_upstream_force(self): |
418 | 559 | version1 = Version("0.1-1") | 559 | version1 = Version("0.1-1") |
419 | @@ -580,7 +580,7 @@ | |||
420 | 580 | # when we fake-sync, but we are forcing one here. | 580 | # when we fake-sync, but we are forcing one here. |
421 | 581 | #TODO: should the upstream parent be second or third? | 581 | #TODO: should the upstream parent be second or third? |
422 | 582 | self.assertEqual(self.db2.get_parents_with_upstream( | 582 | self.assertEqual(self.db2.get_parents_with_upstream( |
424 | 583 | "package", version3, versions, force_upstream_parent=True), | 583 | "package", version3, versions, None, force_upstream_parent=True), |
425 | 584 | [revid2, up_revid3, revid3]) | 584 | [revid2, up_revid3, revid3]) |
426 | 585 | 585 | ||
427 | 586 | def test_branch_to_pull_version_from(self): | 586 | def test_branch_to_pull_version_from(self): |
428 | @@ -700,7 +700,7 @@ | |||
429 | 700 | self.assertEqual(self.tree2.branch.last_revision(), revid) | 700 | self.assertEqual(self.tree2.branch.last_revision(), revid) |
430 | 701 | self.assertEqual(self.up_tree2.branch.last_revision(), up_revid) | 701 | self.assertEqual(self.up_tree2.branch.last_revision(), up_revid) |
431 | 702 | self.assertEqual(self.db2.revid_of_version(version), revid) | 702 | self.assertEqual(self.db2.revid_of_version(version), revid) |
433 | 703 | self.assertEqual(self.db2.revid_of_upstream_version( | 703 | self.assertEqual(self.db2.pristine_upstream_source.version_as_revision( |
434 | 704 | "package", version.upstream_version), up_revid) | 704 | "package", version.upstream_version), up_revid) |
435 | 705 | 705 | ||
436 | 706 | def test_pull_from_lesser_branch_with_upstream(self): | 706 | def test_pull_from_lesser_branch_with_upstream(self): |
437 | @@ -716,7 +716,7 @@ | |||
438 | 716 | self.assertEqual(self.tree2.branch.last_revision(), revid) | 716 | self.assertEqual(self.tree2.branch.last_revision(), revid) |
439 | 717 | self.assertEqual(self.up_tree2.branch.last_revision(), up_revid) | 717 | self.assertEqual(self.up_tree2.branch.last_revision(), up_revid) |
440 | 718 | self.assertEqual(self.db2.revid_of_version(version), revid) | 718 | self.assertEqual(self.db2.revid_of_version(version), revid) |
442 | 719 | self.assertEqual(self.db2.revid_of_upstream_version( | 719 | self.assertEqual(self.db2.pristine_upstream_source.version_as_revision( |
443 | 720 | "package", version.upstream_version), up_revid) | 720 | "package", version.upstream_version), up_revid) |
444 | 721 | 721 | ||
445 | 722 | def test_pull_upstream_from_branch(self): | 722 | def test_pull_upstream_from_branch(self): |
446 | @@ -727,7 +727,7 @@ | |||
447 | 727 | self.assertNotEqual(self.up_tree2.branch.last_revision(), up_revid) | 727 | self.assertNotEqual(self.up_tree2.branch.last_revision(), up_revid) |
448 | 728 | self.db2.pull_upstream_from_branch(self.db1, "package", version) | 728 | self.db2.pull_upstream_from_branch(self.db1, "package", version) |
449 | 729 | self.assertEqual(self.up_tree2.branch.last_revision(), up_revid) | 729 | self.assertEqual(self.up_tree2.branch.last_revision(), up_revid) |
451 | 730 | self.assertEqual(self.db2.revid_of_upstream_version("package", version), | 730 | self.assertEqual(self.db2.pristine_upstream_source.version_as_revision("package", version), |
452 | 731 | up_revid) | 731 | up_revid) |
453 | 732 | 732 | ||
454 | 733 | def check_changes(self, changes, added=[], removed=[], modified=[], | 733 | def check_changes(self, changes, added=[], removed=[], modified=[], |
455 | @@ -784,7 +784,7 @@ | |||
456 | 784 | branch = tree.branch | 784 | branch = tree.branch |
457 | 785 | rh = branch.revision_history() | 785 | rh = branch.revision_history() |
458 | 786 | self.assertEqual(len(rh), 1) | 786 | self.assertEqual(len(rh), 1) |
460 | 787 | self.assertEqual(self.db1.revid_of_upstream_version( | 787 | self.assertEqual(self.db1.pristine_upstream_source.version_as_revision( |
461 | 788 | "package", version.upstream_version), rh[0]) | 788 | "package", version.upstream_version), rh[0]) |
462 | 789 | rev = branch.repository.get_revision(rh[0]) | 789 | rev = branch.repository.get_revision(rh[0]) |
463 | 790 | self.assertEqual(rev.message, | 790 | self.assertEqual(rev.message, |
464 | @@ -823,7 +823,7 @@ | |||
465 | 823 | rh = branch.revision_history() | 823 | rh = branch.revision_history() |
466 | 824 | self.assertEqual(len(rh), 2) | 824 | self.assertEqual(len(rh), 2) |
467 | 825 | self.assertEqual( | 825 | self.assertEqual( |
469 | 826 | self.db1.revid_of_upstream_version("package", version2.upstream_version), rh[1]) | 826 | self.db1.pristine_upstream_source.version_as_revision("package", version2.upstream_version), rh[1]) |
470 | 827 | rev = branch.repository.get_revision(rh[1]) | 827 | rev = branch.repository.get_revision(rh[1]) |
471 | 828 | self.assertEqual(rev.message, | 828 | self.assertEqual(rev.message, |
472 | 829 | "Import upstream version %s" % str(version2.upstream_version)) | 829 | "Import upstream version %s" % str(version2.upstream_version)) |
473 | @@ -854,7 +854,7 @@ | |||
474 | 854 | branch = tree.branch | 854 | branch = tree.branch |
475 | 855 | rh = branch.revision_history() | 855 | rh = branch.revision_history() |
476 | 856 | self.assertEqual(len(rh), 1) | 856 | self.assertEqual(len(rh), 1) |
478 | 857 | self.assertEqual(self.db1.revid_of_upstream_version( | 857 | self.assertEqual(self.db1.pristine_upstream_source.version_as_revision( |
479 | 858 | "package", version.upstream_version), rh[0]) | 858 | "package", version.upstream_version), rh[0]) |
480 | 859 | rev = branch.repository.get_revision(rh[0]) | 859 | rev = branch.repository.get_revision(rh[0]) |
481 | 860 | self.assertEqual(rev.message, | 860 | self.assertEqual(rev.message, |
482 | @@ -882,7 +882,7 @@ | |||
483 | 882 | branch = tree.branch | 882 | branch = tree.branch |
484 | 883 | rh = branch.revision_history() | 883 | rh = branch.revision_history() |
485 | 884 | self.assertEqual(len(rh), 1) | 884 | self.assertEqual(len(rh), 1) |
487 | 885 | self.assertEqual(self.db1.revid_of_upstream_version( | 885 | self.assertEqual(self.db1.pristine_upstream_source.version_as_revision( |
488 | 886 | "package", version.upstream_version), rh[0]) | 886 | "package", version.upstream_version), rh[0]) |
489 | 887 | rev = branch.repository.get_revision(rh[0]) | 887 | rev = branch.repository.get_revision(rh[0]) |
490 | 888 | self.assertEqual(rev.message, | 888 | self.assertEqual(rev.message, |
491 | @@ -916,7 +916,7 @@ | |||
492 | 916 | branch = tree.branch | 916 | branch = tree.branch |
493 | 917 | rh = branch.revision_history() | 917 | rh = branch.revision_history() |
494 | 918 | self.assertEqual(len(rh), 1) | 918 | self.assertEqual(len(rh), 1) |
496 | 919 | self.assertEqual(self.db1.revid_of_upstream_version( | 919 | self.assertEqual(self.db1.pristine_upstream_source.version_as_revision( |
497 | 920 | "package", version.upstream_version), rh[0]) | 920 | "package", version.upstream_version), rh[0]) |
498 | 921 | rev = branch.repository.get_revision(rh[0]) | 921 | rev = branch.repository.get_revision(rh[0]) |
499 | 922 | self.assertEqual(rev.message, | 922 | self.assertEqual(rev.message, |
500 | @@ -1356,7 +1356,7 @@ | |||
501 | 1356 | self.assertEqual(self.db1.revid_of_version(version2), rh1[2]) | 1356 | self.assertEqual(self.db1.revid_of_version(version2), rh1[2]) |
502 | 1357 | self.assertEqual(self.db1.revid_of_version(version3), rh1[3]) | 1357 | self.assertEqual(self.db1.revid_of_version(version3), rh1[3]) |
503 | 1358 | self.assertEqual( | 1358 | self.assertEqual( |
505 | 1359 | self.db1.revid_of_upstream_version("package", version1.upstream_version), | 1359 | self.db1.pristine_upstream_source.version_as_revision("package", version1.upstream_version), |
506 | 1360 | up_rh1[0]) | 1360 | up_rh1[0]) |
507 | 1361 | self.tree1.lock_read() | 1361 | self.tree1.lock_read() |
508 | 1362 | self.addCleanup(self.tree1.unlock) | 1362 | self.addCleanup(self.tree1.unlock) |
509 | @@ -1409,10 +1409,10 @@ | |||
510 | 1409 | self.assertEqual(self.db1.revid_of_version(version2), rh1[2]) | 1409 | self.assertEqual(self.db1.revid_of_version(version2), rh1[2]) |
511 | 1410 | self.assertEqual(self.db1.revid_of_version(version3), rh1[3]) | 1410 | self.assertEqual(self.db1.revid_of_version(version3), rh1[3]) |
512 | 1411 | self.assertEqual( | 1411 | self.assertEqual( |
514 | 1412 | self.db1.revid_of_upstream_version("package", version1.upstream_version), | 1412 | self.db1.pristine_upstream_source.version_as_revision("package", version1.upstream_version), |
515 | 1413 | up_rh1[0]) | 1413 | up_rh1[0]) |
516 | 1414 | self.assertEqual( | 1414 | self.assertEqual( |
518 | 1415 | self.db1.revid_of_upstream_version("package", version3.upstream_version), | 1415 | self.db1.pristine_upstream_source.version_as_revision("package", version3.upstream_version), |
519 | 1416 | up_rh1[1]) | 1416 | up_rh1[1]) |
520 | 1417 | self.tree1.lock_read() | 1417 | self.tree1.lock_read() |
521 | 1418 | self.addCleanup(self.tree1.unlock) | 1418 | self.addCleanup(self.tree1.unlock) |
522 | @@ -1464,10 +1464,10 @@ | |||
523 | 1464 | self.assertEqual(self.db1.revid_of_version(version2), rh1[2]) | 1464 | self.assertEqual(self.db1.revid_of_version(version2), rh1[2]) |
524 | 1465 | self.assertEqual(self.db1.revid_of_version(version3), rh1[3]) | 1465 | self.assertEqual(self.db1.revid_of_version(version3), rh1[3]) |
525 | 1466 | self.assertEqual( | 1466 | self.assertEqual( |
527 | 1467 | self.db1.revid_of_upstream_version("package", version1.upstream_version), | 1467 | self.db1.pristine_upstream_source.version_as_revision("package", version1.upstream_version), |
528 | 1468 | up_rh1[0]) | 1468 | up_rh1[0]) |
529 | 1469 | self.assertEqual( | 1469 | self.assertEqual( |
531 | 1470 | self.db1.revid_of_upstream_version("package", version3.upstream_version), | 1470 | self.db1.pristine_upstream_source.version_as_revision("package", version3.upstream_version), |
532 | 1471 | up_rh1[1]) | 1471 | up_rh1[1]) |
533 | 1472 | self.tree1.lock_read() | 1472 | self.tree1.lock_read() |
534 | 1473 | self.addCleanup(self.tree1.unlock) | 1473 | self.addCleanup(self.tree1.unlock) |
535 | 1474 | 1474 | ||
536 | === modified file 'upstream/pristinetar.py' | |||
537 | --- upstream/pristinetar.py 2011-06-28 08:41:44 +0000 | |||
538 | +++ upstream/pristinetar.py 2011-07-18 10:01:28 +0000 | |||
539 | @@ -156,9 +156,29 @@ | |||
540 | 156 | self.branch.tags.set_tag(tag_name, revid) | 156 | self.branch.tags.set_tag(tag_name, revid) |
541 | 157 | return tag_name, revid | 157 | return tag_name, revid |
542 | 158 | 158 | ||
546 | 159 | def import_component_tarball(self, package, version, tree, component=None, | 159 | def import_tarballs(self, package, version, tree, parent_ids, tarballs, |
547 | 160 | md5=None, tarball=None, author=None, timestamp=None, | 160 | timestamp=None, author=None): |
548 | 161 | parent_ids=None): | 161 | """Import the upstream tarballs. |
549 | 162 | |||
550 | 163 | :param package: Package name | ||
551 | 164 | :param version: Package version | ||
552 | 165 | :param path: Path with tree to import | ||
553 | 166 | :param parent_ids: Parent revisions | ||
554 | 167 | :param tarballs: List of (path, component, md5) | ||
555 | 168 | :param timestamp: Optional timestamp for new commits | ||
556 | 169 | :param author: Optional author for new commits | ||
557 | 170 | :return: List of tuples with (component, tag, revid) | ||
558 | 171 | """ | ||
559 | 172 | ret = [] | ||
560 | 173 | for (tarball, component, md5) in tarballs: | ||
561 | 174 | (tag, revid) = self.import_component_tarball( | ||
562 | 175 | package, version, tree, parent_ids, component, | ||
563 | 176 | md5, tarball, author=author, timestamp=timestamp) | ||
564 | 177 | ret.append((component, tag, revid)) | ||
565 | 178 | return ret | ||
566 | 179 | |||
567 | 180 | def import_component_tarball(self, package, version, tree, parent_ids, | ||
568 | 181 | component=None, md5=None, tarball=None, author=None, timestamp=None): | ||
569 | 162 | """Import a tarball. | 182 | """Import a tarball. |
570 | 163 | 183 | ||
571 | 164 | :param package: Package name | 184 | :param package: Package name |
572 | @@ -217,10 +237,7 @@ | |||
573 | 217 | def fetch_tarballs(self, package, version, target_dir): | 237 | def fetch_tarballs(self, package, version, target_dir): |
574 | 218 | return [self.fetch_component_tarball(package, version, None, target_dir)] | 238 | return [self.fetch_component_tarball(package, version, None, target_dir)] |
575 | 219 | 239 | ||
580 | 220 | def _has_version_component(self, tag_name, md5=None): | 240 | def _has_revision(self, revid, md5=None): |
577 | 221 | if not self.branch.tags.has_tag(tag_name): | ||
578 | 222 | return False | ||
579 | 223 | revid = self.branch.tags.lookup_tag(tag_name) | ||
581 | 224 | self.branch.lock_read() | 241 | self.branch.lock_read() |
582 | 225 | try: | 242 | try: |
583 | 226 | graph = self.branch.repository.get_graph() | 243 | graph = self.branch.repository.get_graph() |
584 | @@ -234,8 +251,9 @@ | |||
585 | 234 | try: | 251 | try: |
586 | 235 | return rev.properties['deb-md5'] == md5 | 252 | return rev.properties['deb-md5'] == md5 |
587 | 236 | except KeyError: | 253 | except KeyError: |
590 | 237 | warning("tag %s present in branch, but there is no " | 254 | warning("tag present in branch, but there is no " |
591 | 238 | "associated 'deb-md5' property" % tag_name) | 255 | "associated 'deb-md5' property in associated " |
592 | 256 | "revision %s", revid) | ||
593 | 239 | return True | 257 | return True |
594 | 240 | 258 | ||
595 | 241 | def version_as_revision(self, package, version, tarballs=None): | 259 | def version_as_revision(self, package, version, tarballs=None): |
596 | @@ -244,13 +262,19 @@ | |||
597 | 244 | elif len(tarballs) > 1: | 262 | elif len(tarballs) > 1: |
598 | 245 | raise MultipleUpstreamTarballsNotSupported() | 263 | raise MultipleUpstreamTarballsNotSupported() |
599 | 246 | else: | 264 | else: |
601 | 247 | return self.version_component_as_revision(package, version, tarballs[0][1]) | 265 | return self.version_component_as_revision(package, version, tarballs[0][1], |
602 | 266 | tarballs[0][2]) | ||
603 | 248 | 267 | ||
605 | 249 | def version_component_as_revision(self, package, version, component, tarballs=None): | 268 | def version_component_as_revision(self, package, version, component, md5=None): |
606 | 250 | assert isinstance(version, str) | 269 | assert isinstance(version, str) |
607 | 251 | for tag_name in self.possible_tag_names(version, component=component): | 270 | for tag_name in self.possible_tag_names(version, component=component): |
610 | 252 | if self._has_version_component(tag_name, tarballs): | 271 | try: |
611 | 253 | return self.branch.tags.lookup_tag(tag_name) | 272 | revid = self.branch.tags.lookup_tag(tag_name) |
612 | 273 | except NoSuchTag: | ||
613 | 274 | continue | ||
614 | 275 | else: | ||
615 | 276 | if self._has_revision(revid, md5=md5): | ||
616 | 277 | return revid | ||
617 | 254 | tag_name = self.tag_name(version, component=component) | 278 | tag_name = self.tag_name(version, component=component) |
618 | 255 | try: | 279 | try: |
619 | 256 | return self.branch.tags.lookup_tag(tag_name) | 280 | return self.branch.tags.lookup_tag(tag_name) |
620 | @@ -269,8 +293,13 @@ | |||
621 | 269 | def has_version_component(self, package, version, component, md5=None): | 293 | def has_version_component(self, package, version, component, md5=None): |
622 | 270 | assert isinstance(version, str), str(type(version)) | 294 | assert isinstance(version, str), str(type(version)) |
623 | 271 | for tag_name in self.possible_tag_names(version, component=component): | 295 | for tag_name in self.possible_tag_names(version, component=component): |
626 | 272 | if self._has_version_component(tag_name, md5=md5): | 296 | try: |
627 | 273 | return True | 297 | revid = self.branch.tags.lookup_tag(tag_name) |
628 | 298 | except NoSuchTag: | ||
629 | 299 | continue | ||
630 | 300 | else: | ||
631 | 301 | if self._has_revision(revid, md5=md5): | ||
632 | 302 | return True | ||
633 | 274 | return False | 303 | return False |
634 | 275 | 304 | ||
635 | 276 | def possible_tag_names(self, version, component): | 305 | def possible_tag_names(self, version, component): |