diff -r 33988aaa1652 -r 01d98d68d697 mercurial/commands.py --- a/mercurial/commands.py Sun Dec 17 22:16:57 2006 -0600 +++ b/mercurial/commands.py Mon Dec 18 12:22:43 2006 -0800 @@ -2450,9 +2450,10 @@ hexfunc = ui.debugflag and hex or short for t, n in l: try: + hn = hexfunc(n) r = "%5d:%s" % (repo.changelog.rev(n), hexfunc(n)) - except KeyError: - r = " ?:?" + except revlog.LookupError: + r = " ?:%s" % hn if ui.quiet: ui.write("%s\n" % t) else: