From 16885508da872be425c1c2d8f95559cc5a411acd Mon Sep 17 00:00:00 2001 From: "Martin A. Brown" Date: Mon, 29 Feb 2016 20:33:14 -0800 Subject: [PATCH] pep8/pyflakes --- tldp/inventory.py | 11 +++++------ tldp/sources.py | 3 ++- tldp/typeguesser.py | 3 ++- tldp/utils.py | 1 - 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/tldp/inventory.py b/tldp/inventory.py index df128c4..e3be9f1 100644 --- a/tldp/inventory.py +++ b/tldp/inventory.py @@ -5,14 +5,13 @@ from __future__ import absolute_import, division, print_function import copy import logging -logger = logging.getLogger(__name__) from tldp.utils import max_mtime, mtime_gt from tldp.sources import SourceCollection from tldp.outputs import OutputCollection -from argparse import Namespace +logger = logging.getLogger(__name__) # -- any individual document (source or output) will have a status # from the following list of status_types @@ -99,7 +98,7 @@ class Inventory(object): del o[doc] self.orphan[doc].status = 'orphan' logger.debug("Identified %d orphan documents: %r.", len(self.orphan), - self.orphan.keys()) + self.orphan.keys()) # -- unpublished ('new') identification # @@ -109,7 +108,7 @@ class Inventory(object): del s[doc] self.new[doc].status = 'new' logger.debug("Identified %d new documents: %r.", len(self.new), - self.new.keys()) + self.new.keys()) # -- published identification; source and output should be same size assert len(s) == len(o) @@ -135,7 +134,7 @@ class Inventory(object): odoc.status = sdoc.status = 'stale' self.stale[stem] = sdoc logger.debug("Identified %d stale documents: %r.", len(self.stale), - self.stale.keys()) + self.stale.keys()) # -- stale identification # @@ -145,7 +144,7 @@ class Inventory(object): self.broken[stem] = sdoc sdoc.status = sdoc.output.status = 'broken' logger.debug("Identified %d broken documents: %r.", len(self.broken), - self.broken.keys()) + self.broken.keys()) def getByStatusClass(self, status_class): desired = status_classes.get(status_class, None) diff --git a/tldp/sources.py b/tldp/sources.py index cfca999..11050d2 100644 --- a/tldp/sources.py +++ b/tldp/sources.py @@ -7,13 +7,14 @@ import os import sys import errno import logging -logger = logging.getLogger(__name__) from tldp.ldpcollection import LDPDocumentCollection from tldp.utils import statfiles, stem_and_ext from tldp.typeguesser import guess, knownextensions +logger = logging.getLogger(__name__) + def scansourcedirs(dirnames): '''return a dict() of all SourceDocuments discovered in dirnames diff --git a/tldp/typeguesser.py b/tldp/typeguesser.py index 607e330..fdb7836 100644 --- a/tldp/typeguesser.py +++ b/tldp/typeguesser.py @@ -6,12 +6,13 @@ from __future__ import absolute_import, division, print_function import os import inspect import logging -logger = logging.getLogger(__name__) from tldp.utils import makefh import tldp.doctypes +logger = logging.getLogger(__name__) + def getDoctypeMembers(membertype): '''returns a list of tldp.doctypes; convenience function''' diff --git a/tldp/utils.py b/tldp/utils.py index 3106740..6d2c379 100644 --- a/tldp/utils.py +++ b/tldp/utils.py @@ -5,7 +5,6 @@ from __future__ import absolute_import, division, print_function import os import io -import sys import time import errno import operator