[Reproducible-commits] [misc] 02/07: clean-notes: `lambda x: fn(x)` <==> `fn`. Well, unless you're being pedantic re. scoping

Chris Lamb lamby at moszumanska.debian.org
Mon Feb 9 18:01:30 UTC 2015


This is an automated email from the git hooks/post-receive script.

lamby pushed a commit to branch master
in repository misc.

commit 815f35d1b3373379d1b69569190caa198b61c820
Author: Chris Lamb <lamby at debian.org>
Date:   Mon Feb 9 17:51:56 2015 +0000

    clean-notes: `lambda x: fn(x)` <==> `fn`. Well, unless you're being pedantic re. scoping
---
 clean-notes | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/clean-notes b/clean-notes
index 87c780f..efe7e70 100755
--- a/clean-notes
+++ b/clean-notes
@@ -119,7 +119,7 @@ def check_bugs(notes):
     This function check whether all the bugs listed in notes.git are usertagged
     """
     bugs = []
-    for pkg in sorted(notes, key=lambda x: str(x)):
+    for pkg in sorted(notes, key=str):
         if 'bugs' in notes[pkg]:
             for bug in notes[pkg]['bugs']:
                 bugs.append((str(pkg), int(bug)))
@@ -144,7 +144,7 @@ def find_old_notes(testedpkgs, notes):
     if args.verbose:
         print("parsing the reproducible.json and the notes to find weirdness")
     toremove = []
-    for pkg in sorted(notes, key=lambda x: str(x)):
+    for pkg in sorted(notes, key=str):
         if 'version' not in notes[pkg] and \
            'missing-version' not in args.disable:
             print("There is no version set for the package " + pkg)
@@ -259,7 +259,7 @@ def cleanup_notes(notes, toremove):
 
 def write_out(notes):
     out = ''
-    for pkg, values in sorted(notes.items(), key=lambda x: str(x)):
+    for pkg, values in sorted(notes.items(), key=str):
         if not any((values.get(key, None) for key in ['comments', 'issues', 'bugs'])):
             continue
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/misc.git



More information about the Reproducible-commits mailing list