comparison tests/test-check-code-hg.t @ 16689:f366d4c2ff34

cleanup: replace naked excepts with except Exception: ...
author Brodie Rao <brodie@sf.io>
date Sat, 12 May 2012 16:02:46 +0200
parents cfb6682961b8
children c2d9ef43ff6c
comparison
equal deleted inserted replaced
16688:cfb6682961b8 16689:f366d4c2ff34
6 > exit 80 6 > exit 80
7 > fi 7 > fi
8 $ hg manifest | xargs "$check_code" || echo 'FAILURE IS NOT AN OPTION!!!' 8 $ hg manifest | xargs "$check_code" || echo 'FAILURE IS NOT AN OPTION!!!'
9 9
10 $ hg manifest | xargs "$check_code" --warnings --nolineno --per-file=0 || true 10 $ hg manifest | xargs "$check_code" --warnings --nolineno --per-file=0 || true
11 contrib/perf.py:0:
12 > except:
13 warning: naked except clause
14 contrib/perf.py:0:
15 > except:
16 warning: naked except clause
17 contrib/setup3k.py:0:
18 > except:
19 warning: naked except clause
20 contrib/shrink-revlog.py:0: 11 contrib/shrink-revlog.py:0:
21 > except: 12 > except:
22 warning: naked except clause 13 warning: naked except clause
23 hgext/convert/bzr.py:0:
24 > except:
25 warning: naked except clause
26 hgext/convert/convcmd.py:0:
27 > except:
28 warning: naked except clause
29 hgext/convert/cvsps.py:0: 14 hgext/convert/cvsps.py:0:
30 > ui.write('Ancestors: %s\n' % (','.join(r))) 15 > ui.write('Ancestors: %s\n' % (','.join(r)))
31 warning: unwrapped ui message 16 warning: unwrapped ui message
32 hgext/convert/cvsps.py:0: 17 hgext/convert/cvsps.py:0:
33 > ui.write('Parent: %d\n' % cs.parents[0].id) 18 > ui.write('Parent: %d\n' % cs.parents[0].id)
57 > ui.write('PatchSet %d \n' % cs.id) 42 > ui.write('PatchSet %d \n' % cs.id)
58 warning: unwrapped ui message 43 warning: unwrapped ui message
59 hgext/convert/cvsps.py:0: 44 hgext/convert/cvsps.py:0:
60 > ui.write('Tag%s: %s \n' % (['', 's'][len(cs.tags) > 1], 45 > ui.write('Tag%s: %s \n' % (['', 's'][len(cs.tags) > 1],
61 warning: unwrapped ui message 46 warning: unwrapped ui message
62 hgext/convert/git.py:0:
63 > except:
64 warning: naked except clause
65 hgext/convert/hg.py:0:
66 > except:
67 warning: naked except clause
68 warning: naked except clause
69 hgext/convert/hg.py:0:
70 > except:
71 warning: naked except clause
72 hgext/convert/monotone.py:0:
73 > except:
74 warning: naked except clause
75 hgext/convert/subversion.py:0:
76 > except:
77 warning: naked except clause
78 hgext/hgk.py:0: 47 hgext/hgk.py:0:
79 > ui.write("parent %s\n" % p) 48 > ui.write("parent %s\n" % p)
80 warning: unwrapped ui message 49 warning: unwrapped ui message
81 hgext/hgk.py:0: 50 hgext/hgk.py:0:
82 > ui.write('k=%s\nv=%s\n' % (name, value)) 51 > ui.write('k=%s\nv=%s\n' % (name, value))
107 warning: naked except clause 76 warning: naked except clause
108 warning: naked except clause 77 warning: naked except clause
109 warning: naked except clause 78 warning: naked except clause
110 warning: naked except clause 79 warning: naked except clause
111 hgext/mq.py:0: 80 hgext/mq.py:0:
112 > except:
113 warning: naked except clause
114 hgext/mq.py:0:
115 > ui.write("mq: %s\n" % ', '.join(m)) 81 > ui.write("mq: %s\n" % ', '.join(m))
116 warning: unwrapped ui message 82 warning: unwrapped ui message
117 hgext/patchbomb.py:0: 83 hgext/patchbomb.py:0:
118 > ui.write('Subject: %s\n' % subj) 84 > ui.write('Subject: %s\n' % subj)
119 warning: unwrapped ui message 85 warning: unwrapped ui message
131 warning: unwrapped ui message 97 warning: unwrapped ui message
132 mercurial/commands.py:0: 98 mercurial/commands.py:0:
133 > ui.write("unpruned common: %s\n" % " ".join([short(n) 99 > ui.write("unpruned common: %s\n" % " ".join([short(n)
134 warning: unwrapped ui message 100 warning: unwrapped ui message
135 mercurial/commands.py:0: 101 mercurial/commands.py:0:
136 > except:
137 warning: naked except clause
138 mercurial/commands.py:0:
139 > ui.write("format: id, p1, p2, cset, delta base, len(delta)\n") 102 > ui.write("format: id, p1, p2, cset, delta base, len(delta)\n")
140 warning: unwrapped ui message 103 warning: unwrapped ui message
141 mercurial/commands.py:0: 104 mercurial/commands.py:0:
142 > ui.write("local is subset\n") 105 > ui.write("local is subset\n")
143 warning: unwrapped ui message 106 warning: unwrapped ui message
236 > except: 199 > except:
237 warning: naked except clause 200 warning: naked except clause
238 mercurial/repair.py:0: 201 mercurial/repair.py:0:
239 > except: 202 > except:
240 warning: naked except clause 203 warning: naked except clause
241 mercurial/transaction.py:0:
242 > except:
243 warning: naked except clause
244 mercurial/util.py:0: 204 mercurial/util.py:0:
245 > except: 205 > except:
246 warning: naked except clause
247 mercurial/verify.py:0:
248 > except:
249 warning: naked except clause
250 mercurial/verify.py:0:
251 > except:
252 warning: naked except clause
253 setup.py:0:
254 > except:
255 warning: naked except clause 206 warning: naked except clause
256 tests/autodiff.py:0: 207 tests/autodiff.py:0:
257 > ui.write('data lost for: %s\n' % fn) 208 > ui.write('data lost for: %s\n' % fn)
258 warning: unwrapped ui message 209 warning: unwrapped ui message
259 tests/test-convert-mtn.t:0: 210 tests/test-convert-mtn.t:0: