Status: | Merged |
---|---|
Approved by: | Jelmer Vernooij |
Approved revision: | no longer in the source branch. |
Merge reported by: | The Breezy Bot |
Merged at revision: | not available |
Proposed branch: | lp:~jelmer/brz/3.0-merge |
Merge into: | lp:brz |
Diff against target: |
289 lines (+51/-33) 13 files modified
breezy/git/.testr.conf (+1/-1) breezy/git/bzr-receive-pack (+4/-4) breezy/git/bzr-upload-pack (+4/-4) breezy/osutils.py (+1/-3) breezy/plugin.py (+6/-1) breezy/plugins/commitfromnews/__init__.py (+1/-0) breezy/plugins/darcs/__init__.py (+1/-0) breezy/plugins/email/__init__.py (+1/-0) breezy/plugins/fastimport/__init__.py (+1/-0) breezy/plugins/propose/__init__.py (+1/-0) breezy/plugins/repodebug/__init__.py (+1/-0) breezy/tests/test_plugins.py (+25/-20) doc/en/release-notes/brz-3.0.txt (+4/-0) |
To merge this branch: | bzr merge lp:~jelmer/brz/3.0-merge |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Jelmer Vernooij | Approve | ||
Review via email: mp+374062@code.launchpad.net |
Commit message
Merge lp:brz/3.0.
Description of the change
Merge lp:brz/3.0.
To post a comment you must log in.
Revision history for this message
Jelmer Vernooij (jelmer) : | # |
review:
Approve
Revision history for this message
The Breezy Bot (the-breezy-bot) wrote : | # |
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'breezy/git/.testr.conf' | |||
2 | --- breezy/git/.testr.conf 2018-03-30 14:33:57 +0000 | |||
3 | +++ breezy/git/.testr.conf 2019-10-14 00:07:21 +0000 | |||
4 | @@ -1,4 +1,4 @@ | |||
5 | 1 | [DEFAULT] | 1 | [DEFAULT] |
7 | 2 | test_command=BRZ_PLUGINS_AT=git@`pwd` BRZ_PLUGIN_PATH=-site:-user ${BRZ:-../../../brz} selftest ^breezy.plugins.git. Git --subunit2 $IDOPTION $LISTOPT | 2 | test_command=BRZ_PLUGINS_AT=git@`pwd` BRZ_PLUGIN_PATH=-site:-user ${BRZ:-../../brz} selftest ^breezy.git. Git --subunit2 $IDOPTION $LISTOPT |
8 | 3 | test_id_option=--load-list $IDFILE | 3 | test_id_option=--load-list $IDFILE |
9 | 4 | test_list_option=--list | 4 | test_list_option=--list |
10 | 5 | 5 | ||
11 | === modified file 'breezy/git/bzr-receive-pack' | |||
12 | --- breezy/git/bzr-receive-pack 2018-03-26 22:28:24 +0000 | |||
13 | +++ breezy/git/bzr-receive-pack 2019-10-14 00:07:21 +0000 | |||
14 | @@ -1,14 +1,14 @@ | |||
15 | 1 | #!/usr/bin/env python | 1 | #!/usr/bin/env python |
16 | 2 | 2 | ||
17 | 3 | import breezy | 3 | import breezy |
21 | 4 | from breezy.plugin import load_plugins | 4 | import breezy.bzr |
22 | 5 | load_plugins() | 5 | import breezy.git |
23 | 6 | from breezy.plugins.git.server import BzrBackend | 6 | from breezy.git.server import BzrBackend |
24 | 7 | from dulwich.server import ReceivePackHandler, serve_command | 7 | from dulwich.server import ReceivePackHandler, serve_command |
25 | 8 | import sys, os | 8 | import sys, os |
26 | 9 | 9 | ||
27 | 10 | if len(sys.argv) < 2: | 10 | if len(sys.argv) < 2: |
29 | 11 | print >>sys.stderr, "usage: %s <git-dir>" % os.path.basename(sys.argv[0]) | 11 | print("usage: %s <git-dir>" % os.path.basename(sys.argv[0])) |
30 | 12 | sys.exit(1) | 12 | sys.exit(1) |
31 | 13 | 13 | ||
32 | 14 | backend = BzrBackend(breezy.transport.get_transport("/")) | 14 | backend = BzrBackend(breezy.transport.get_transport("/")) |
33 | 15 | 15 | ||
34 | === modified file 'breezy/git/bzr-upload-pack' | |||
35 | --- breezy/git/bzr-upload-pack 2018-03-26 22:28:24 +0000 | |||
36 | +++ breezy/git/bzr-upload-pack 2019-10-14 00:07:21 +0000 | |||
37 | @@ -1,14 +1,14 @@ | |||
38 | 1 | #!/usr/bin/env python | 1 | #!/usr/bin/env python |
39 | 2 | 2 | ||
40 | 3 | import breezy | 3 | import breezy |
44 | 4 | from breezy.plugin import load_plugins | 4 | import breezy.bzr |
45 | 5 | load_plugins () | 5 | import breezy.git |
46 | 6 | from breezy.plugins.git.server import BzrBackend | 6 | from breezy.git.server import BzrBackend |
47 | 7 | from dulwich.server import UploadPackHandler, serve_command | 7 | from dulwich.server import UploadPackHandler, serve_command |
48 | 8 | import sys, os | 8 | import sys, os |
49 | 9 | 9 | ||
50 | 10 | if len(sys.argv) < 2: | 10 | if len(sys.argv) < 2: |
52 | 11 | print "usage: %s <git-dir>" % os.path.basename(sys.argv[0]) | 11 | print("usage: %s <git-dir>" % os.path.basename(sys.argv[0])) |
53 | 12 | sys.exit(1) | 12 | sys.exit(1) |
54 | 13 | 13 | ||
55 | 14 | backend = BzrBackend(breezy.transport.get_transport("/")) | 14 | backend = BzrBackend(breezy.transport.get_transport("/")) |
56 | 15 | 15 | ||
57 | === modified file 'breezy/osutils.py' | |||
58 | --- breezy/osutils.py 2019-10-13 17:17:48 +0000 | |||
59 | +++ breezy/osutils.py 2019-10-14 00:07:21 +0000 | |||
60 | @@ -520,9 +520,7 @@ | |||
61 | 520 | """Replacer for shutil.rmtree: could remove readonly dirs/files""" | 520 | """Replacer for shutil.rmtree: could remove readonly dirs/files""" |
62 | 521 | return shutil.rmtree(path, ignore_errors, onerror) | 521 | return shutil.rmtree(path, ignore_errors, onerror) |
63 | 522 | 522 | ||
67 | 523 | f = win32utils.get_unicode_argv # special function or None | 523 | get_unicode_argv = getattr(win32utils, 'get_unicode_argv', get_unicode_argv) |
65 | 524 | if f is not None: | ||
66 | 525 | get_unicode_argv = f | ||
68 | 526 | path_from_environ = win32utils.get_environ_unicode | 524 | path_from_environ = win32utils.get_environ_unicode |
69 | 527 | _get_home_dir = win32utils.get_home_location | 525 | _get_home_dir = win32utils.get_home_location |
70 | 528 | getuser_unicode = win32utils.get_user_name | 526 | getuser_unicode = win32utils.get_user_name |
71 | 529 | 527 | ||
72 | === modified file 'breezy/plugin.py' | |||
73 | --- breezy/plugin.py 2019-06-16 01:03:51 +0000 | |||
74 | +++ breezy/plugin.py 2019-10-14 00:07:21 +0000 | |||
75 | @@ -225,7 +225,12 @@ | |||
76 | 225 | """ | 225 | """ |
77 | 226 | path_details = [] | 226 | path_details = [] |
78 | 227 | env = osutils.path_from_environ(key) | 227 | env = osutils.path_from_environ(key) |
80 | 228 | defaults = {"user": not env, "core": True, "site": True, 'entrypoints': True} | 228 | defaults = { |
81 | 229 | "user": not env, | ||
82 | 230 | "core": True, | ||
83 | 231 | "site": True, | ||
84 | 232 | 'entrypoints': False, | ||
85 | 233 | } | ||
86 | 229 | if env: | 234 | if env: |
87 | 230 | # Add paths specified by user in order | 235 | # Add paths specified by user in order |
88 | 231 | for p in env.split(os.pathsep): | 236 | for p in env.split(os.pathsep): |
89 | 232 | 237 | ||
90 | === modified file 'breezy/plugins/commitfromnews/__init__.py' | |||
91 | --- breezy/plugins/commitfromnews/__init__.py 2018-11-11 04:08:32 +0000 | |||
92 | +++ breezy/plugins/commitfromnews/__init__.py 2019-10-14 00:07:21 +0000 | |||
93 | @@ -35,6 +35,7 @@ | |||
94 | 35 | 35 | ||
95 | 36 | from __future__ import absolute_import | 36 | from __future__ import absolute_import |
96 | 37 | 37 | ||
97 | 38 | from ... import version_info # noqa: F401 | ||
98 | 38 | from ... import hooks | 39 | from ... import hooks |
99 | 39 | from ...config import ( | 40 | from ...config import ( |
100 | 40 | option_registry, | 41 | option_registry, |
101 | 41 | 42 | ||
102 | === modified file 'breezy/plugins/darcs/__init__.py' | |||
103 | --- breezy/plugins/darcs/__init__.py 2018-11-11 04:08:32 +0000 | |||
104 | +++ breezy/plugins/darcs/__init__.py 2019-10-14 00:07:21 +0000 | |||
105 | @@ -21,6 +21,7 @@ | |||
106 | 21 | 21 | ||
107 | 22 | from __future__ import absolute_import | 22 | from __future__ import absolute_import |
108 | 23 | 23 | ||
109 | 24 | from ... import version_info # noqa: F401 | ||
110 | 24 | from breezy import ( | 25 | from breezy import ( |
111 | 25 | controldir, | 26 | controldir, |
112 | 26 | errors, | 27 | errors, |
113 | 27 | 28 | ||
114 | === modified file 'breezy/plugins/email/__init__.py' | |||
115 | --- breezy/plugins/email/__init__.py 2018-11-11 04:08:32 +0000 | |||
116 | +++ breezy/plugins/email/__init__.py 2019-10-14 00:07:21 +0000 | |||
117 | @@ -66,6 +66,7 @@ | |||
118 | 66 | 66 | ||
119 | 67 | from __future__ import absolute_import | 67 | from __future__ import absolute_import |
120 | 68 | 68 | ||
121 | 69 | from ... import version_info # noqa: F401 | ||
122 | 69 | from ...config import option_registry | 70 | from ...config import option_registry |
123 | 70 | 71 | ||
124 | 71 | 72 | ||
125 | 72 | 73 | ||
126 | === modified file 'breezy/plugins/fastimport/__init__.py' | |||
127 | --- breezy/plugins/fastimport/__init__.py 2018-11-11 04:08:32 +0000 | |||
128 | +++ breezy/plugins/fastimport/__init__.py 2019-10-14 00:07:21 +0000 | |||
129 | @@ -56,6 +56,7 @@ | |||
130 | 56 | 56 | ||
131 | 57 | from __future__ import absolute_import | 57 | from __future__ import absolute_import |
132 | 58 | 58 | ||
133 | 59 | from ... import version_info # noqa: F401 | ||
134 | 59 | from ...commands import plugin_cmds | 60 | from ...commands import plugin_cmds |
135 | 60 | 61 | ||
136 | 61 | 62 | ||
137 | 62 | 63 | ||
138 | === modified file 'breezy/plugins/propose/__init__.py' | |||
139 | --- breezy/plugins/propose/__init__.py 2019-04-27 15:40:17 +0000 | |||
140 | +++ breezy/plugins/propose/__init__.py 2019-10-14 00:07:21 +0000 | |||
141 | @@ -18,6 +18,7 @@ | |||
142 | 18 | 18 | ||
143 | 19 | from __future__ import absolute_import | 19 | from __future__ import absolute_import |
144 | 20 | 20 | ||
145 | 21 | from ... import version_info # noqa: F401 | ||
146 | 21 | from ...commands import plugin_cmds | 22 | from ...commands import plugin_cmds |
147 | 22 | 23 | ||
148 | 23 | plugin_cmds.register_lazy("cmd_propose_merge", ["propose"], __name__ + ".cmds") | 24 | plugin_cmds.register_lazy("cmd_propose_merge", ["propose"], __name__ + ".cmds") |
149 | 24 | 25 | ||
150 | === modified file 'breezy/plugins/repodebug/__init__.py' | |||
151 | --- breezy/plugins/repodebug/__init__.py 2017-09-07 08:21:29 +0000 | |||
152 | +++ breezy/plugins/repodebug/__init__.py 2019-10-14 00:07:21 +0000 | |||
153 | @@ -22,6 +22,7 @@ | |||
154 | 22 | 22 | ||
155 | 23 | from __future__ import absolute_import | 23 | from __future__ import absolute_import |
156 | 24 | 24 | ||
157 | 25 | from ... import version_info # noqa: F401 | ||
158 | 25 | from ...commands import plugin_cmds | 26 | from ...commands import plugin_cmds |
159 | 26 | 27 | ||
160 | 27 | 28 | ||
161 | 28 | 29 | ||
162 | === modified file 'breezy/tests/test_plugins.py' | |||
163 | --- breezy/tests/test_plugins.py 2019-01-25 03:30:39 +0000 | |||
164 | +++ breezy/tests/test_plugins.py 2019-10-14 00:07:21 +0000 | |||
165 | @@ -606,59 +606,62 @@ | |||
166 | 606 | self.assertEqual(expected_dirs, actual) | 606 | self.assertEqual(expected_dirs, actual) |
167 | 607 | 607 | ||
168 | 608 | def test_default(self): | 608 | def test_default(self): |
171 | 609 | self.check_path([self.user, self.core, self.entrypoints, self.site], | 609 | self.check_path([self.user, self.core, self.site], None) |
170 | 610 | None) | ||
172 | 611 | 610 | ||
173 | 612 | def test_adhoc_policy(self): | 611 | def test_adhoc_policy(self): |
175 | 613 | self.check_path([self.user, self.core, self.site, self.entrypoints], | 612 | self.check_path([self.user, self.core, self.site], |
176 | 614 | ['+user', '+core', '+site']) | 613 | ['+user', '+core', '+site']) |
177 | 615 | 614 | ||
178 | 616 | def test_fallback_policy(self): | 615 | def test_fallback_policy(self): |
180 | 617 | self.check_path([self.core, self.site, self.user, self.entrypoints], | 616 | self.check_path([self.core, self.site, self.user], |
181 | 618 | ['+core', '+site', '+user']) | 617 | ['+core', '+site', '+user']) |
182 | 619 | 618 | ||
183 | 620 | def test_override_policy(self): | 619 | def test_override_policy(self): |
185 | 621 | self.check_path([self.user, self.site, self.core, self.entrypoints], | 620 | self.check_path([self.user, self.site, self.core], |
186 | 622 | ['+user', '+site', '+core']) | 621 | ['+user', '+site', '+core']) |
187 | 623 | 622 | ||
188 | 623 | def test_enable_entrypoints(self): | ||
189 | 624 | self.check_path([self.user, self.core, self.site, self.entrypoints], | ||
190 | 625 | ['+user', '+core', '+site', '+entrypoints']) | ||
191 | 626 | |||
192 | 624 | def test_disable_user(self): | 627 | def test_disable_user(self): |
194 | 625 | self.check_path([self.core, self.entrypoints, self.site], ['-user']) | 628 | self.check_path([self.core, self.site], ['-user']) |
195 | 626 | 629 | ||
196 | 627 | def test_disable_user_twice(self): | 630 | def test_disable_user_twice(self): |
197 | 628 | # Ensures multiple removals don't left cruft | 631 | # Ensures multiple removals don't left cruft |
199 | 629 | self.check_path([self.core, self.entrypoints, self.site], ['-user', '-user']) | 632 | self.check_path([self.core, self.site], ['-user', '-user']) |
200 | 630 | 633 | ||
201 | 631 | def test_duplicates_are_removed(self): | 634 | def test_duplicates_are_removed(self): |
203 | 632 | self.check_path([self.user, self.core, self.entrypoints, self.site], | 635 | self.check_path([self.user, self.core, self.site], |
204 | 633 | ['+user', '+user']) | 636 | ['+user', '+user']) |
205 | 634 | # And only the first reference is kept (since the later references will | 637 | # And only the first reference is kept (since the later references will |
206 | 635 | # only produce '<plugin> already loaded' mutters) | 638 | # only produce '<plugin> already loaded' mutters) |
208 | 636 | self.check_path([self.user, self.core, self.site, self.entrypoints], | 639 | self.check_path([self.user, self.core, self.site], |
209 | 637 | ['+user', '+user', '+core', | 640 | ['+user', '+user', '+core', |
210 | 638 | '+user', '+site', '+site', | 641 | '+user', '+site', '+site', |
211 | 639 | '+core']) | 642 | '+core']) |
212 | 640 | 643 | ||
213 | 641 | def test_disable_overrides_enable(self): | 644 | def test_disable_overrides_enable(self): |
215 | 642 | self.check_path([self.core, self.entrypoints, self.site], ['-user', '+user']) | 645 | self.check_path([self.core, self.site], ['-user', '+user']) |
216 | 643 | 646 | ||
217 | 644 | def test_disable_core(self): | 647 | def test_disable_core(self): |
220 | 645 | self.check_path([self.entrypoints, self.site], ['-core']) | 648 | self.check_path([self.site], ['-core']) |
221 | 646 | self.check_path([self.user, self.entrypoints, self.site], ['+user', '-core']) | 649 | self.check_path([self.user, self.site], ['+user', '-core']) |
222 | 647 | 650 | ||
223 | 648 | def test_disable_site(self): | 651 | def test_disable_site(self): |
226 | 649 | self.check_path([self.core, self.entrypoints], ['-site']) | 652 | self.check_path([self.core], ['-site']) |
227 | 650 | self.check_path([self.user, self.core, self.entrypoints], ['-site', '+user']) | 653 | self.check_path([self.user, self.core], ['-site', '+user']) |
228 | 651 | 654 | ||
229 | 652 | def test_override_site(self): | 655 | def test_override_site(self): |
231 | 653 | self.check_path(['mysite', self.user, self.core, self.entrypoints], | 656 | self.check_path(['mysite', self.user, self.core], |
232 | 654 | ['mysite', '-site', '+user']) | 657 | ['mysite', '-site', '+user']) |
234 | 655 | self.check_path(['mysite', self.core, self.entrypoints], | 658 | self.check_path(['mysite', self.core], |
235 | 656 | ['mysite', '-site']) | 659 | ['mysite', '-site']) |
236 | 657 | 660 | ||
237 | 658 | def test_override_core(self): | 661 | def test_override_core(self): |
239 | 659 | self.check_path(['mycore', self.user, self.site, self.entrypoints], | 662 | self.check_path(['mycore', self.user, self.site], |
240 | 660 | ['mycore', '-core', '+user', '+site']) | 663 | ['mycore', '-core', '+user', '+site']) |
242 | 661 | self.check_path(['mycore', self.entrypoints, self.site], | 664 | self.check_path(['mycore', self.site], |
243 | 662 | ['mycore', '-core']) | 665 | ['mycore', '-core']) |
244 | 663 | 666 | ||
245 | 664 | def test_my_plugin_only(self): | 667 | def test_my_plugin_only(self): |
246 | @@ -667,11 +670,11 @@ | |||
247 | 667 | ['myplugin', '-user', '-core', '-site', '-entrypoints']) | 670 | ['myplugin', '-user', '-core', '-site', '-entrypoints']) |
248 | 668 | 671 | ||
249 | 669 | def test_my_plugin_first(self): | 672 | def test_my_plugin_first(self): |
251 | 670 | self.check_path(['myplugin', self.core, self.site, self.user, self.entrypoints], | 673 | self.check_path(['myplugin', self.core, self.site, self.user], |
252 | 671 | ['myplugin', '+core', '+site', '+user']) | 674 | ['myplugin', '+core', '+site', '+user']) |
253 | 672 | 675 | ||
254 | 673 | def test_bogus_references(self): | 676 | def test_bogus_references(self): |
256 | 674 | self.check_path(['+foo', '-bar', self.core, self.entrypoints, self.site], | 677 | self.check_path(['+foo', '-bar', self.core, self.site], |
257 | 675 | ['+foo', '-bar']) | 678 | ['+foo', '-bar']) |
258 | 676 | 679 | ||
259 | 677 | 680 | ||
260 | @@ -923,6 +926,7 @@ | |||
261 | 923 | 926 | ||
262 | 924 | def test_plugin_loaded(self): | 927 | def test_plugin_loaded(self): |
263 | 925 | self.assertPluginUnknown('plugin') | 928 | self.assertPluginUnknown('plugin') |
264 | 929 | self.overrideEnv('BRZ_PLUGIN_PATH', '+entrypoints') | ||
265 | 926 | self.setup_plugin() | 930 | self.setup_plugin() |
266 | 927 | p = self.plugins['plugin'] | 931 | p = self.plugins['plugin'] |
267 | 928 | self.assertIsInstance(p, breezy.plugin.PlugIn) | 932 | self.assertIsInstance(p, breezy.plugin.PlugIn) |
268 | @@ -930,6 +934,7 @@ | |||
269 | 930 | 934 | ||
270 | 931 | def test_plugin_loaded_disabled(self): | 935 | def test_plugin_loaded_disabled(self): |
271 | 932 | self.assertPluginUnknown('plugin') | 936 | self.assertPluginUnknown('plugin') |
272 | 937 | self.overrideEnv('BRZ_PLUGIN_PATH', '+entrypoints') | ||
273 | 933 | self.overrideEnv('BRZ_DISABLE_PLUGINS', 'plugin') | 938 | self.overrideEnv('BRZ_DISABLE_PLUGINS', 'plugin') |
274 | 934 | self.setup_plugin() | 939 | self.setup_plugin() |
275 | 935 | self.assertNotIn('plugin', self.plugins) | 940 | self.assertNotIn('plugin', self.plugins) |
276 | 936 | 941 | ||
277 | === modified file 'doc/en/release-notes/brz-3.0.txt' | |||
278 | --- doc/en/release-notes/brz-3.0.txt 2019-06-18 11:21:15 +0000 | |||
279 | +++ doc/en/release-notes/brz-3.0.txt 2019-10-14 00:07:21 +0000 | |||
280 | @@ -32,6 +32,10 @@ | |||
281 | 32 | .. Fixes for situations where brz would previously crash or give incorrect | 32 | .. Fixes for situations where brz would previously crash or give incorrect |
282 | 33 | or undesirable results. | 33 | or undesirable results. |
283 | 34 | 34 | ||
284 | 35 | * Disable loading from entrypoints by default, since it can | ||
285 | 36 | significantly slow down startup on some platforms. | ||
286 | 37 | (Jelmer Vernooij, #1832868) | ||
287 | 38 | |||
288 | 35 | Documentation | 39 | Documentation |
289 | 36 | ************* | 40 | ************* |
290 | 37 | 41 |
There was nothing to merge /ci.breezy- vcs.org/ job/brz/ job/brz- land/524/
https:/