[elbe-devel] [PATCH 3/7] pep8: fix E265 block comment should start with '# '

Manuel Traut manut at linutronix.de
Wed Dec 20 22:11:43 CET 2017


The '#' was used to comment out sourcecode.
Unused sourcecode should not be in elbe.
So the lines are just removed.

The new pycodestyle statistics are:

3       E266 too many leading '#' for block comment
2       E402 module level import not at top of file
98      E501 line too long (82 > 79 characters)
7       E741 ambiguous variable name 'l'

Signed-off-by: Manuel Traut <manut at linutronix.de>
---
 elbepack/commands/parselicence.py | 4 ----
 elbepack/dump.py                  | 1 -
 elbepack/licencexml.py            | 1 -
 3 files changed, 6 deletions(-)

diff --git a/elbepack/commands/parselicence.py b/elbepack/commands/parselicence.py
index 044a8b33..cda4667d 100644
--- a/elbepack/commands/parselicence.py
+++ b/elbepack/commands/parselicence.py
@@ -243,9 +243,6 @@ def run_command(argv):
         with io.open(opt.tagvalue, "wt", encoding='utf-8') as fp:
             fp.write(u'SPDXVersion: SPDX-1.2\n')
             fp.write(u'DataLicense: CC0-1.0\n')
-            #fp.write (u'SPDXID: SPDXRef-DOCUMENT\n')
-            #fp.write (u'DocumentName: %s\n' % opt.tagvalue)
-            #fp.write (u'DocumentNamespace: %s\n' % some_uri_with_uuid )
             fp.write(u'\n')
             fp.write(u'## Creation Information\n')
             fp.write(u'Creator: Tool: elbe-%s\n' % elbe_version)
@@ -259,7 +256,6 @@ def run_command(argv):
                 fp.write(u'## Package %s\n' % pkg.et.attrib['name'])
                 fp.write(u'PackageName: %s\n' % pkg.et.attrib['name'])
                 fp.write(u'PackageDownloadLocation: NOASSERTION\n')
-                #fp.write (u'PackageVerificationCode: %s\n')
                 if pkg.has('have_override'):
                     fp.write(
                         u'PackageLicenseConcluded: %s\n' %
diff --git a/elbepack/dump.py b/elbepack/dump.py
index 8525a62e..1961c433 100644
--- a/elbepack/dump.py
+++ b/elbepack/dump.py
@@ -213,7 +213,6 @@ def elbe_report(xml, buildenv, cache, reportname, targetfs):
     mt_index = targetfs.mtime_snap()
     if xml.has("target/finetuning"):
         do_finetuning(xml, outf, buildenv, targetfs)
-        #outf.print_raw( do_command( opt.finetuning ) )
         mt_index_post_fine = targetfs.mtime_snap()
     else:
         mt_index_post_fine = mt_index
diff --git a/elbepack/licencexml.py b/elbepack/licencexml.py
index 21990e9e..f5db9cc8 100644
--- a/elbepack/licencexml.py
+++ b/elbepack/licencexml.py
@@ -93,7 +93,6 @@ class copyright_xml (object):
             pass
 
         bytesio.seek(0)
-        #textio = io.TextIOWrapper (bytesio, encoding='iso-8859-1')
 
         c = do_heuristics(bytesio)
 
-- 
2.15.1




More information about the elbe-devel mailing list