Mercurial > hg
changeset 12063:516b000fbb7e
cleanup: remove unused variables
author | Brodie Rao <brodie@bitheap.org> |
---|---|
date | Fri, 27 Aug 2010 13:32:40 -0400 |
parents | c327bfa5e831 |
children | 6449be7b8a3b |
files | hgext/convert/bzr.py hgext/convert/cvs.py hgext/inotify/client.py hgext/mq.py mercurial/commands.py mercurial/hgweb/webcommands.py mercurial/windows.py mercurial/wireproto.py |
diffstat | 8 files changed, 4 insertions(+), 9 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/convert/bzr.py Fri Aug 27 13:32:38 2010 -0400 +++ b/hgext/convert/bzr.py Fri Aug 27 13:32:40 2010 -0400 @@ -61,7 +61,7 @@ try: tree = dir.open_workingtree(recommend_upgrade=False) branch = tree.branch - except (errors.NoWorkingTree, errors.NotLocalUrl), e: + except (errors.NoWorkingTree, errors.NotLocalUrl): tree = None branch = dir.open_branch() if (tree is not None and tree.bzrdir.root_transport.base !=
--- a/hgext/convert/cvs.py Fri Aug 27 13:32:38 2010 -0400 +++ b/hgext/convert/cvs.py Fri Aug 27 13:32:40 2010 -0400 @@ -53,8 +53,6 @@ try: os.chdir(self.path) id = None - state = 0 - filerevids = {} cache = 'update' if not self.ui.configbool('convert', 'cvsps.cache', True):
--- a/hgext/inotify/client.py Fri Aug 27 13:32:38 2010 -0400 +++ b/hgext/inotify/client.py Fri Aug 27 13:32:40 2010 -0400 @@ -21,7 +21,6 @@ Raise QueryFailed if something went wrong """ def decorated_function(self, *args): - result = None try: return function(self, *args) except (OSError, socket.error), err:
--- a/hgext/mq.py Fri Aug 27 13:32:38 2010 -0400 +++ b/hgext/mq.py Fri Aug 27 13:32:40 2010 -0400 @@ -1756,7 +1756,6 @@ """print the patches already applied""" q = repo.mq - l = len(q.applied) if patch: if patch not in q.series:
--- a/mercurial/commands.py Fri Aug 27 13:32:38 2010 -0400 +++ b/mercurial/commands.py Fri Aug 27 13:32:40 2010 -0400 @@ -1360,7 +1360,7 @@ # check username ui.status(_("Checking username...\n")) try: - user = ui.username() + ui.username() except util.Abort, e: ui.write(" %s\n" % e) ui.write(_(" (specify a username in your .hgrc file)\n"))
--- a/mercurial/hgweb/webcommands.py Fri Aug 27 13:32:38 2010 -0400 +++ b/mercurial/hgweb/webcommands.py Fri Aug 27 13:32:40 2010 -0400 @@ -383,7 +383,6 @@ latestentry=lambda **x: entries(True, 1, **x)) def branches(web, req, tmpl): - b = web.repo.branchtags() tips = (web.repo[n] for t, n in web.repo.branchtags().iteritems()) heads = web.repo.heads() parity = paritygen(web.stripecount)
--- a/mercurial/windows.py Fri Aug 27 13:32:38 2010 -0400 +++ b/mercurial/windows.py Fri Aug 27 13:32:40 2010 -0400 @@ -288,7 +288,7 @@ '''atomically rename file src to dst, replacing dst if it exists''' try: os.rename(src, dst) - except OSError, err: # FIXME: check err (EEXIST ?) + except OSError: # FIXME: check err (EEXIST ?) # On windows, rename to existing file is not allowed, so we # must delete destination first. But if a file is open, unlink
--- a/mercurial/wireproto.py Fri Aug 27 13:32:38 2010 -0400 +++ b/mercurial/wireproto.py Fri Aug 27 13:32:40 2010 -0400 @@ -123,7 +123,7 @@ _('push failed:'), output) try: ret = int(ret) - except ValueError, err: + except ValueError: raise error.ResponseError( _('push failed (unexpected response):'), ret)