qdiff: refresh crashes after a commit

Bug #515651 reported by Samuel Bronson
96
This bug affects 13 people
Affects Status Importance Assigned to Milestone
QBzr
Confirmed
High
Unassigned

Bug Description

I had opened a diff from either bzr explorer's main toolbar or the commit dialog box.
Then, after committing and pushing, I hit refresh and got this:

bzr: ERROR: exceptions.AssertionError: parent <email address hidden> has disappeared from ['<email address hidden>']

Traceback (most recent call last):
  File "C:/Program Files/Bazaar/plugins\qbzr\lib\diffwindow.py", line 404, in click_refresh
  File "C:/Program Files/Bazaar/plugins\qbzr\lib\util.py", line 1002, in run_in_loading_queue
  File "C:/Program Files/Bazaar/plugins\qbzr\lib\diffwindow.py", line 266, in load_diff
  File "bzrlib\tree.pyo", line 1045, in iter_changes
  File "bzrlib\decorators.pyo", line 138, in read_locked
  File "bzrlib\tree.pyo", line 201, in iter_entries_by_dir
  File "bzrlib\workingtree_4.pyo", line 1825, in _get_inventory
  File "bzrlib\workingtree_4.pyo", line 1695, in _generate_inventory
AssertionError: parent <email address hidden> has disappeared from ['<email address hidden>']

bzr 2.0.4 on python 2.5.4 (win32)
arguments: ['C:\\Program Files\\Bazaar\\bzr.exe', 'qdiff']
encoding: 'cp1252', fsenc: 'mbcs', lang: None
plugins:
  bzrtools C:\Program Files\Bazaar\plugins\bzrtools [2.0.1]
  explorer C:\Program Files\Bazaar\plugins\explorer [0.8.3]
  launchpad C:\Program Files\Bazaar\plugins\launchpad [2.0.4]
  netrc_credential_store C:\Program Files\Bazaar\plugins\netrc_credential_store [2.0.4]
  qbzr C:\Program Files\Bazaar\plugins\qbzr [0.14.6]
  rebase C:\Program Files\Bazaar\plugins\rebase [0.5.4]
  svn C:\Program Files\Bazaar\plugins\svn [1.0.0]
  upload C:\Program Files\Bazaar\plugins\upload [1.0.0dev]
  xmloutput C:\Program Files\Bazaar\plugins\xmloutput [0.8.5]

Tags: qdiff
Revision history for this message
Gary van der Merwe (garyvdm) wrote :

We need to reload the parent tree on refresh if the new tree is the working tree, and there was no -r arg.

tags: added: qdiff
Changed in qbzr:
importance: Undecided → Medium
status: New → Confirmed
summary: - qdiff refresh crashes when clicked after a commit???
+ qdiff: refresh crashes after a commit.
Revision history for this message
Josh Brown (joshbrown) wrote : Re: qdiff: refresh crashes after a commit.

I've just received a similar error when I opened a diff, made a commit, then refreshed the diff.

bzr: ERROR: exceptions.ValueError: list.index(x): x not in list

Traceback (most recent call last):
  File "/usr/lib/python2.6/dist-packages/bzrlib/plugins/qbzr/lib/diffwindow.py", line 438, in click_refresh
    run_in_loading_queue(self.load_diff)
  File "/usr/lib/python2.6/dist-packages/bzrlib/plugins/qbzr/lib/util.py", line 891, in run_in_loading_queue
    f(*args, **kargs)
  File "/usr/lib/python2.6/dist-packages/bzrlib/plugins/qbzr/lib/diffwindow.py", line 294, in load_diff
    executable) in sorted(changes, key=changes_key):
  File "/usr/lib/python2.6/dist-packages/bzrlib/tree.py", line 1046, in iter_changes
    lookup_trees, require_versioned=require_versioned)
  File "/usr/lib/python2.6/dist-packages/bzrlib/workingtree_4.py", line 877, in paths2ids
    trees, require_versioned)
  File "/usr/lib/python2.6/dist-packages/bzrlib/tree.py", line 577, in paths2ids
    return find_ids_across_trees(paths, [self] + list(trees), require_versioned)
  File "/usr/lib/python2.6/dist-packages/bzrlib/tree.py", line 804, in find_ids_across_trees
    require_versioned)
  File "/usr/lib/python2.6/dist-packages/bzrlib/tree.py", line 824, in _find_ids_across_trees
    file_id = tree.path2id(tree_path)
  File "/usr/lib/python2.6/dist-packages/bzrlib/decorators.py", line 140, in read_locked
    result = unbound(self, *args, **kwargs)
  File "/usr/lib/python2.6/dist-packages/bzrlib/workingtree_4.py", line 1895, in path2id
    entry = self._get_entry(path=path)
  File "/usr/lib/python2.6/dist-packages/bzrlib/workingtree_4.py", line 1664, in _get_entry
    parent_index = self._get_parent_index()
  File "/usr/lib/python2.6/dist-packages/bzrlib/workingtree_4.py", line 1647, in _get_parent_index
    return self._dirstate.get_parent_ids().index(self._revision_id) + 1
ValueError: list.index(x): x not in list

bzr 2.1.1 on python 2.6.5 (linux2)
arguments: ['/usr/bin/bzr', 'qdiff', 'snakes']
encoding: 'UTF-8', fsenc: 'UTF-8', lang: 'en_GB.utf8'
plugins:
  bzrtools /usr/lib/python2.6/dist-packages/bzrlib/plugins/bzrtools [2.1.0]
  explorer /usr/lib/python2.6/dist-packages/bzrlib/plugins/explorer [1.0.1]
  launchpad /usr/lib/python2.6/dist-packages/bzrlib/plugins/launchpad [2.1.1]
  netrc_credential_store /usr/lib/python2.6/dist-packages/bzrlib/plugins/netrc_credential_store [2.1.1]
  news_merge /usr/lib/python2.6/dist-packages/bzrlib/plugins/news_merge [2.1.1]
  qbzr /usr/lib/python2.6/dist-packages/bzrlib/plugins/qbzr [0.18.6]

The commit I made can be found on Launchpad: lp:~snakes-game/snakes-game/trunk 2.5.1.1 [http://bazaar.launchpad.net/~snakes-game/snakes-game/trunk/revision/25.1.1]

Running:
  qbzr 0.18.6-0ubuntu1
  bzr 2.1.1-1

Josh Brown (joshbrown)
summary: - qdiff: refresh crashes after a commit.
+ qdiff: refresh crashes after a commit
Revision history for this message
yesgrey (yesgrey) wrote :

I've just received a similar error when I opened a diff, made a commit, then refreshed the diff.

bzr: ERROR: exceptions.AssertionError: parent <email address hidden> has disappeared from ['<email address hidden>']

Traceback (most recent call last):
  File "C:/Program Files (x86)/Bazaar/plugins\qbzr\lib\diffwindow.py", line 441, in click_refresh
  File "C:/Program Files (x86)/Bazaar/plugins\qbzr\lib\util.py", line 868, in run_in_loading_queue
  File "C:/Program Files (x86)/Bazaar/plugins\qbzr\lib\diffwindow.py", line 297, in load_diff
  File "bzrlib\tree.pyo", line 1070, in iter_changes
  File "bzrlib\decorators.pyo", line 140, in read_locked
  File "bzrlib\tree.pyo", line 201, in iter_entries_by_dir
  File "bzrlib\workingtree_4.pyo", line 1831, in _get_inventory
  File "bzrlib\workingtree_4.pyo", line 1697, in _generate_inventory
AssertionError: parent <email address hidden> has disappeared from ['<email address hidden>']

bzr 2.2.3 on python 2.6.4 (win32)
arguments: ['C:\\Program Files (x86)\\Bazaar\\bzrw.exe', 'qdiff']
encoding: 'cp1252', fsenc: 'mbcs', lang: None
plugins:
  bzrtools C:\Program Files (x86)\Bazaar\plugins\bzrtools [2.2.0]
  explorer C:\Program Files (x86)\Bazaar\plugins\explorer [1.1.2]
  launchpad C:\Program Files (x86)\Bazaar\plugins\launchpad [2.2.3]
  news_merge C:\Program Files (x86)\Bazaar\plugins\news_merge [2.2.3]
  qbzr C:\Program Files (x86)\Bazaar\plugins\qbzr [0.19.2]
  upload C:\Program Files (x86)\Bazaar\plugins\upload [1.0.0]
  xmloutput C:\Program Files (x86)\Bazaar\plugins\xmloutput [0.8.6]

Revision history for this message
Martin Pool (mbp) wrote :

I'm going to bump this up based on the number of dupes.

Changed in qbzr:
importance: Medium → High
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.