I can reproduce this bug with a recent bzr (which generate only 114 conflicts instead of 143 thanks
to some other bug fixes :-/), traceback:
BZR_PDB=1 bzr remerge --lca
Warning: criss-cross merge encountered. See bzr help criss-cross.
bzr: ERROR: The file id "sp1f-genericmsvc.h-20080110122110-bnn2j7c6jhbiw4scjarkxgxk2w5xoh22" is not present in the tree <Inventory object at e21abd0, contents="{'sp1f-have_log_bin.require-20070514123848-glb7sh4lf7vnfqt4l77gwhguyc2k2cw4': InventoryFile('sp1f-have_log_bin.require-20070514123848-glb7sh4lf7vnfqt4l77gwhguyc2k2cw4', u'have_log_bin.require', parent_id='sp1d-mysqltest_r-x5knzvhqj2dl73uerge4e24flx5aupsc', sha1='566d3ad4d03fb568d20dd5fde481e10e0fb38018', len=31, <email address hidden>), 'sp1f-clientcert.der-20060503111055-belh4pjgfofrfv4ss6krjapskeho2uk6': InventoryFile('sp1f-clientcert.der-20060503111055-belh4pjgfofrfv4ss6krjapskeho2uk6', u'client-cert.der', parent_id='sp1d-extra_yassl_certs-qlzltwwnxf7xxgjup7s37vagnqovtril', sha1='04927567dc3010224979a839c16261dbbc40347e', len=699, revision=sp1r-msvensson@shellback.(none)-20060503112051-37118), 'sp1f-be_default.h-20071106183210-mnvzyvwpym77uxcwsvgfb3y5bnvorew2': InventoryFile('sp1f-be_default.h-20071106183210-mnvzyvwpym77uxcwsvgfb3y5bnvorew2', u'be_default.h', parent_id='sp1d-sql_backup-kssn2h2a5l2cqskksbk7dvts6pbym5j6', sha1='cda092bd4d88c2b8d5bb5b0aa06db849b022790a', len=8950, revision=sp1r-cbell/Chuck@mysql_cab_desk.-20071203202832-61394), 'sp1f-rpl_ndb_innodb_trans-20060905145203-mopikf2kqymact2krb45jf2j3ss7kegk': InventoryFile('sp1f-rpl_ndb_innodb_trans-20060905145203-mopikf2kqymact2krb45jf2j3ss7kegk', u'rpl_ndb_innodb_trans.test', parent_id='sp1d-mysqltest_suite_rpl_ndb_t-5daypjzb3gdodf7j5dgrrwfq2wbjs3jh', sha1='e5a6462ce1f5e59b55e0673c30fab9c1a5bdd97b', len=1521, <email address hidden>), 'sp1f-myisam_tb3.inc-20070206175435-46ozmsyoeusi6vqkhzhowmiyzh7iqxd5': InventoryFile('sp1f-myisam_tb3.inc-20070206175435-46ozmsyoeusi6vqkhzhowmiyzh7iqxd5', u'myisam_tb3.inc', parent_id='sp1d-mysqltest_suite_funcs_1_include-lku56dwgrx62ghafw3tek3oa5qnapu7d', sha1='cbba7f7455f9bdd558902bcca3dc962ea471976f', len=2267, revision=sp1r-joerg@debian.(none)-20070727113232-19339), 'sp1f-falcon_bug_22179.tes-20070920154325-xkh5yfl7opoxsxhc7euxjeqli2gh6yn5': InventoryFile('sp1f-falcon_bug_22179.tes-20070920154325-xkh5yfl7opoxsxhc7euxjeqli2gh6yn5', u'fa...}">.
**** entering debugger
/home/vila/src/bzr/trunk/bzrlib/inventory.py(1264)__getitem__()
-> raise errors.NoSuchId(self, file_id)
(Pdb) bt
/home/vila/src/bzr/trunk/bzrlib/commands.py(835)exception_to_return_code()
-> return the_callable(*args, **kwargs)
/home/vila/src/bzr/trunk/bzrlib/commands.py(1039)run_bzr()
-> ret = run(*run_argv)
/home/vila/src/bzr/trunk/bzrlib/commands.py(643)run_argv_aliases()
-> return self.run_direct(**all_cmd_args)
/home/vila/src/bzr/trunk/bzrlib/commands.py(647)run_direct()
-> return self._operation.run_simple(*args, **kwargs)
/home/vila/src/bzr/trunk/bzrlib/cleanup.py(122)run_simple()
-> self.cleanups, self.func, *args, **kwargs)
/home/vila/src/bzr/trunk/bzrlib/cleanup.py(156)_do_with_cleanups()
-> result = func(*args, **kwargs)
/home/vila/src/bzr/trunk/bzrlib/builtins.py(4104)run()
-> conflicts = merger.do_merge()
/home/vila/src/bzr/trunk/bzrlib/merge.py(657)do_merge()
-> merge = operation.run_simple()
/home/vila/src/bzr/trunk/bzrlib/cleanup.py(122)run_simple()
-> self.cleanups, self.func, *args, **kwargs)
/home/vila/src/bzr/trunk/bzrlib/cleanup.py(156)_do_with_cleanups()
-> result = func(*args, **kwargs)
/home/vila/src/bzr/trunk/bzrlib/merge.py(628)_do_merge_to()
-> merge.do_merge()
/home/vila/src/bzr/trunk/bzrlib/merge.py(764)do_merge()
-> operation.run()
/home/vila/src/bzr/trunk/bzrlib/cleanup.py(118)run()
-> self.cleanups, self.func, self, *args, **kwargs)
/home/vila/src/bzr/trunk/bzrlib/cleanup.py(156)_do_with_cleanups()
-> result = func(*args, **kwargs)
/home/vila/src/bzr/trunk/bzrlib/merge.py(769)_do_merge()
-> self._compute_transform()
/home/vila/src/bzr/trunk/bzrlib/merge.py(807)_compute_transform()
-> file_status = self._do_merge_contents(file_id)
/home/vila/src/bzr/trunk/bzrlib/merge.py(1294)_do_merge_contents()
-> hook_status, lines = hook.merge_contents(params)
/home/vila/src/bzr/trunk/bzrlib/merge.py(1385)merge_contents()
-> merge_hook_params.trans_id)
/home/vila/src/bzr/trunk/bzrlib/merge.py(1638)text_merge()
-> lines, base_lines = self._merged_lines(file_id)
/home/vila/src/bzr/trunk/bzrlib/merge.py(1617)_merged_lines()
-> plan = self._generate_merge_plan(file_id, base)
/home/vila/src/bzr/trunk/bzrlib/merge.py(1659)_generate_merge_plan()
-> base=base)
/home/vila/src/bzr/trunk/bzrlib/tree.py(494)plan_file_lca_merge()
-> data = self._get_plan_merge_data(file_id, other, base)
/home/vila/src/bzr/trunk/bzrlib/tree.py(465)_get_plan_merge_data()
-> last_revision_a = self._get_file_revision(file_id, vf, 'this:')
/home/vila/src/bzr/trunk/bzrlib/tree.py(522)_get_file_revision()
-> self._iter_parent_trees()]
/home/vila/src/bzr/trunk/bzrlib/tree.py(512)_file_revision()
-> return revision_tree.inventory[file_id].revision
> /home/vila/src/bzr/trunk/bzrlib/inventory.py(1264)__getitem__()
-> raise errors.NoSuchId(self, file_id)
(Pdb)
There are several problems here:
1) We don't revert the tree properly,
2) We fail to retrieve the file revision because it's involved in an unresolved conflict
This can't be addressed simply (we first need to either revert properly or at least stop
with a warning before trying to remerge).
The workaround is to do:
bzr revert [--no-backup]
bzr clean-tree --detritus (checking that no precious unversioned files will be deleted)
bzr merge --lca
I'll tags this bug and will come back to it later.
I can reproduce this bug with a recent bzr (which generate only 114 conflicts instead of 143 thanks vc.h-2008011012 2110-bnn2j7c6jh biw4scjarkxgxk2 w5xoh22" is not present in the tree <Inventory object at e21abd0, contents= "{'sp1f- have_log_ bin.require- 20070514123848- glb7sh4lf7vnfqt 4l77gwhguyc2k2c w4': InventoryFile( 'sp1f-have_ log_bin. require- 20070514123848- glb7sh4lf7vnfqt 4l77gwhguyc2k2c w4', u'have_ log_bin. require' , parent_ id='sp1d- mysqltest_ r-x5knzvhqj2dl7 3uerge4e24flx5a upsc', sha1='566d3ad4d 03fb568d20dd5fd e481e10e0fb3801 8', len=31, <email address hidden>), 'sp1f-clientcer t.der-200605031 11055-belh4pjgf ofrfv4ss6krjaps keho2uk6' : InventoryFile( 'sp1f-clientcer t.der-200605031 11055-belh4pjgf ofrfv4ss6krjaps keho2uk6' , u'client-cert.der', parent_ id='sp1d- extra_yassl_ certs-qlzltwwnx f7xxgjup7s37vag nqovtril' , sha1='04927567d c3010224979a839 c16261dbbc40347 e', len=699, revision= sp1r-msvensson@ shellback. (none)- 20060503112051- 37118), 'sp1f-be_ default. h-2007110618321 0-mnvzyvwpym77u xcwsvgfb3y5bnvo rew2': InventoryFile( 'sp1f-be_ default. h-2007110618321 0-mnvzyvwpym77u xcwsvgfb3y5bnvo rew2', u'be_default.h', parent_ id='sp1d- sql_backup- kssn2h2a5l2cqsk ksbk7dvts6pbym5 j6', sha1='cda092bd4 d88c2b8d5bb5b0a a06db849b022790 a', len=8950, revision= sp1r-cbell/ Chuck@mysql_ cab_desk. -20071203202832 -61394) , 'sp1f-rpl_ ndb_innodb_ trans-200609051 45203-mopikf2kq ymact2krb45jf2j 3ss7kegk' : InventoryFile( 'sp1f-rpl_ ndb_innodb_ trans-200609051 45203-mopikf2kq ymact2krb45jf2j 3ss7kegk' , u'rpl_ndb_ innodb_ trans.test' , parent_ id='sp1d- mysqltest_ suite_rpl_ ndb_t-5daypjzb3 gdodf7j5dgrrwfq 2wbjs3jh' , sha1='e5a6462ce 1f5e59b55e0673c 30fab9c1a5bdd97 b', len=1521, <email address hidden>), 'sp1f-myisam_ tb3.inc- 20070206175435- 46ozmsyoeusi6vq khzhowmiyzh7iqx d5': InventoryFile( 'sp1f-myisam_ tb3.inc- 20070206175435- 46ozmsyoeusi6vq khzhowmiyzh7iqx d5', u'myisam_tb3.inc', parent_ id='sp1d- mysqltest_ suite_funcs_ 1_include- lku56dwgrx62gha fw3tek3oa5qnapu 7d', sha1='cbba7f745 5f9bdd558902bcc a3dc962ea471976 f', len=2267, revision= sp1r-joerg@ debian. (none)- 20070727113232- 19339), 'sp1f-falcon_ bug_22179. tes-20070920154 325-xkh5yfl7opo xsxhc7euxjeqli2 gh6yn5' : InventoryFile( 'sp1f-falcon_ bug_22179. tes-20070920154 325-xkh5yfl7opo xsxhc7euxjeqli2 gh6yn5' , u'fa...}">. vila/src/ bzr/trunk/ bzrlib/ inventory. py(1264) __getitem_ _() NoSuchId( self, file_id) vila/src/ bzr/trunk/ bzrlib/ commands. py(835) exception_ to_return_ code() vila/src/ bzr/trunk/ bzrlib/ commands. py(1039) run_bzr( ) vila/src/ bzr/trunk/ bzrlib/ commands. py(643) run_argv_ aliases( ) direct( **all_cmd_ args) vila/src/ bzr/trunk/ bzrlib/ commands. py(647) run_direct( ) .run_simple( *args, **kwargs) vila/src/ bzr/trunk/ bzrlib/ cleanup. py(122) run_simple( ) vila/src/ bzr/trunk/ bzrlib/ cleanup. py(156) _do_with_ cleanups( ) vila/src/ bzr/trunk/ bzrlib/ builtins. py(4104) run() vila/src/ bzr/trunk/ bzrlib/ merge.py( 657)do_ merge() run_simple( ) vila/src/ bzr/trunk/ bzrlib/ cleanup. py(122) run_simple( ) vila/src/ bzr/trunk/ bzrlib/ cleanup. py(156) _do_with_ cleanups( ) vila/src/ bzr/trunk/ bzrlib/ merge.py( 628)_do_ merge_to( ) vila/src/ bzr/trunk/ bzrlib/ merge.py( 764)do_ merge() vila/src/ bzr/trunk/ bzrlib/ cleanup. py(118) run() vila/src/ bzr/trunk/ bzrlib/ cleanup. py(156) _do_with_ cleanups( ) vila/src/ bzr/trunk/ bzrlib/ merge.py( 769)_do_ merge() transform( ) vila/src/ bzr/trunk/ bzrlib/ merge.py( 807)_compute_ transform( ) merge_contents( file_id) vila/src/ bzr/trunk/ bzrlib/ merge.py( 1294)_do_ merge_contents( ) contents( params) vila/src/ bzr/trunk/ bzrlib/ merge.py( 1385)merge_ contents( ) params. trans_id) vila/src/ bzr/trunk/ bzrlib/ merge.py( 1638)text_ merge() lines(file_ id) vila/src/ bzr/trunk/ bzrlib/ merge.py( 1617)_merged_ lines() merge_plan( file_id, base) vila/src/ bzr/trunk/ bzrlib/ merge.py( 1659)_generate_ merge_plan( ) vila/src/ bzr/trunk/ bzrlib/ tree.py( 494)plan_ file_lca_ merge() plan_merge_ data(file_ id, other, base) vila/src/ bzr/trunk/ bzrlib/ tree.py( 465)_get_ plan_merge_ data() file_revision( file_id, vf, 'this:') vila/src/ bzr/trunk/ bzrlib/ tree.py( 522)_get_ file_revision( ) parent_ trees() ] vila/src/ bzr/trunk/ bzrlib/ tree.py( 512)_file_ revision( ) tree.inventory[ file_id] .revision src/bzr/ trunk/bzrlib/ inventory. py(1264) __getitem_ _() NoSuchId( self, file_id)
to some other bug fixes :-/), traceback:
BZR_PDB=1 bzr remerge --lca
Warning: criss-cross merge encountered. See bzr help criss-cross.
bzr: ERROR: The file id "sp1f-genericms
**** entering debugger
/home/
-> raise errors.
(Pdb) bt
/home/
-> return the_callable(*args, **kwargs)
/home/
-> ret = run(*run_argv)
/home/
-> return self.run_
/home/
-> return self._operation
/home/
-> self.cleanups, self.func, *args, **kwargs)
/home/
-> result = func(*args, **kwargs)
/home/
-> conflicts = merger.do_merge()
/home/
-> merge = operation.
/home/
-> self.cleanups, self.func, *args, **kwargs)
/home/
-> result = func(*args, **kwargs)
/home/
-> merge.do_merge()
/home/
-> operation.run()
/home/
-> self.cleanups, self.func, self, *args, **kwargs)
/home/
-> result = func(*args, **kwargs)
/home/
-> self._compute_
/home/
-> file_status = self._do_
/home/
-> hook_status, lines = hook.merge_
/home/
-> merge_hook_
/home/
-> lines, base_lines = self._merged_
/home/
-> plan = self._generate_
/home/
-> base=base)
/home/
-> data = self._get_
/home/
-> last_revision_a = self._get_
/home/
-> self._iter_
/home/
-> return revision_
> /home/vila/
-> raise errors.
(Pdb)
There are several problems here:
1) We don't revert the tree properly,
2) We fail to retrieve the file revision because it's involved in an unresolved conflict
This can't be addressed simply (we first need to either revert properly or at least stop
with a warning before trying to remerge).
The workaround is to do:
bzr revert [--no-backup]
bzr clean-tree --detritus (checking that no precious unversioned files will be deleted)
bzr merge --lca
I'll tags this bug and will come back to it later.