1. Bill_Barry
  2. hgattic

Commits

bbarry  committed 4982e91

bug: parent[0] may not exist under certain circumstances

  • Participants
  • Parent commits 64f7e42
  • Branches default

Comments (0)

Files changed (1)

File attic.py

View file
  • Ignore whitespace
         if date:
             fp.write('# Date %d %d\n' % date)
         parents = [p.node() for p in ctx.parents() if p]
-        fp.write('# Parent  %s\n' % hex(parents[0]))
+        if parents:
+            fp.write('# Parent  %s\n' % hex(parents[0]))
         if msg:
             if not isinstance(msg, str):
                 msg = '\n'.join(msg)