~abentley/bzrtools/bzrtools.dev

« back to all changes in this revision

Viewing changes to fai.py

  • Committer: Robert Collins
  • Date: 2005-10-23 00:10:38 UTC
  • mto: (147.1.39) (364.1.3 bzrtools)
  • mto: This revision was merged to the branch mainline in revision 324.
  • Revision ID: robertc@robertcollins.net-20051023001038-626888fa8be1d49d
when we encounter an obviously corrupt patchlog, work around it by using the archive.

Show diffs side-by-side

added added

removed removed

Lines of Context:
36
36
    if not logs:
37
37
        return []
38
38
    for log in logs:
39
 
        indirect.extend([f for f in log.new_patches if f != log.revision])
 
39
        try:
 
40
            this_indirect = [f for f in log.new_patches if f != log.revision]
 
41
        except pybaz.errors.NamespaceError:
 
42
            print
 
43
            print "log ", log, " unusable, attempting to use archive copy."
 
44
            log = pybaz.Revision(str(log.revision)).patchlog
 
45
            this_indirect = [f for f in log.new_patches if f != log.revision]
 
46
        indirect.extend(this_indirect)
40
47
        if log.continuation_of is not None:
41
48
            # continuations list everything in new_patches
42
49
            continue