Patchwork D11683: fix: appease pyflakes and make unused variables more obvious

login
register
mail settings
Submitter phabricator
Date Oct. 18, 2021, 9:35 a.m.
Message ID <differential-rev-PHID-DREV-waehhuryb6enxr3yjt7r-req@mercurial-scm.org>
Download mbox | patch
Permalink /patch/50007/
State Superseded
Headers show

Comments

phabricator - Oct. 18, 2021, 9:35 a.m.
Alphare created this revision.
Herald added a reviewer: hg-reviewers.
Herald added a subscriber: mercurial-patches.

REVISION SUMMARY
  pyflakes is complaining that `baserevs` is redefined by the list comprehension,
  and while this lint can be valuable, it's not actually a problem here.

REPOSITORY
  rHG Mercurial

BRANCH
  default

REVISION DETAIL
  https://phab.mercurial-scm.org/D11683

AFFECTED FILES
  hgext/fix.py

CHANGE DETAILS




To: Alphare, #hg-reviewers
Cc: mercurial-patches, mercurial-devel

Patch

diff --git a/hgext/fix.py b/hgext/fix.py
--- a/hgext/fix.py
+++ b/hgext/fix.py
@@ -434,7 +434,7 @@ 
             numitems[rev] += 1
     workqueue = [
         (min(dstrevs), path, dstrevs)
-        for (filerev, baserevs, path), dstrevs in dstrevmap.items()
+        for (_filerev, _baserevs, path), dstrevs in dstrevmap.items()
     ]
     # Move work items for earlier changesets to the front of the queue, so we
     # might be able to replace those changesets (in topological order) while