C-extensions in bzr.dev cause "bzr gcommit" to issue exception: assert False, "How did we get here?"
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Bazaar |
Won't Fix
|
Medium
|
Unassigned | ||
Bazaar GTK+ Frontends |
Fix Released
|
High
|
John A Meinel |
Bug Description
Using latest bzr-gtk from its dev branch (revno 605) and latest bzr.dev
Bazaar (bzr) 1.9dev
from bzr checkout /home/mysql_
revision: 3769
revid: <email address hidden>
branch nick: dev
Python interpreter: /usr/bin/python 2.5
Python standard library: /usr/lib/python2.5
If I do
bzr init bzr1
cd bzr1
echo test > a
bzr add a
added a
bzr gcommit
bzr commit -m "rev1"
echo test2 > a
bzr gcommit
bzr: ERROR: exceptions.
Traceback (most recent call last):
File "/home/
return run_bzr(argv)
File "/home/
ret = run(*run_argv)
File "/home/
return self.run(
File "/home/
dlg = CommitDialog(wt)
File "/home/
self.
File "/home/
self.
File "/home/
) in iter_changes_
File "/home/
assert False, "How did we get here?"
AssertionError: How did we get here?
Hints: problem does not happen if:
- I use a fresh branch of bzr.dev where I have not typed "make"
- or I remove bzrlib/*.so generated by "make"
- so it seems to have to do with C-extensions?
I'm using Pyrex 0.9.8.5.
Related branches
Changed in bzr-gtk: | |
status: | Fix Committed → Fix Released |
Changed in bzr-gtk: | |
status: | Fix Released → Fix Committed |
Changed in bzr-gtk: | |
status: | Fix Committed → Fix Released |
summary: |
- C-extensions in bzr.dev cause "bzr gcommit" to issue exception + C-extensions in bzr.dev cause "bzr gcommit" to issue exception: assert + False, "How did we get here?" |
Can you give a bit more context?
For example, what does "bzr status" give? Does it give something different if you do or don't have the extensions compiled?
Can you add a debug statement right before the assertion? Something like:
print (file_id, paths, changed_content, versioned, parent_ids, names, kinds, executables, present_source, present_target)
Looking at the code in question, it would seem that it might be getting back an entry which the gtk/diff.py code considers unchanged.
Actually, never mind, I tracked it down.
The specific code in bzr-gtk is saying:
elif changed_content is True or executables[0] != executables[1]:
however, the pyrex iter_changes code returns "0" or "1" and not True or False. So "changed_content is True" is failing.
Instead, the gtk code should be doing:
elif changed_content or executables[0] != executables[1]: