소스 검색

Remove unused imports

Jonas Borgström 11 년 전
부모
커밋
a579b7917b
3개의 변경된 파일2개의 추가작업 그리고 6개의 파일을 삭제
  1. 1 1
      attic/archiver.py
  2. 0 3
      attic/lrucache.py
  3. 1 2
      attic/testsuite/archiver.py

+ 1 - 1
attic/archiver.py

@@ -12,7 +12,7 @@ from attic.repository import Repository
 from attic.cache import Cache
 from attic.key import key_creator
 from attic.helpers import location_validator, format_time, \
-    format_file_mode, IncludePattern, ExcludePattern, exclude_path, adjust_patterns, to_localtime, \
+    format_file_mode, ExcludePattern, exclude_path, adjust_patterns, to_localtime, \
     get_cache_dir, get_keys_dir, format_timedelta, prune_split, Manifest, Location, remove_surrogates
 from attic.remote import RepositoryServer, RemoteRepository, ConnectionClosed
 

+ 0 - 3
attic/lrucache.py

@@ -1,6 +1,3 @@
-from heapq import heappush, heapify, heapreplace, heappop
-
-
 class LRUCache(dict):
 
     def __init__(self, capacity):

+ 1 - 2
attic/testsuite/archiver.py

@@ -77,8 +77,8 @@ class ArchiverTestCase(AtticTestCase):
             self.assert_equal(exit_code, ret)
             return output
         args = list(args)
+        stdout, stderr = sys.stdout, sys.stderr
         try:
-            stdout, stderr = sys.stdout, sys.stderr
             output = StringIO()
             sys.stdout = sys.stderr = output
             ret = self.archiver.run(args)
@@ -100,7 +100,6 @@ class ArchiverTestCase(AtticTestCase):
         with open(filename, 'wb') as fd:
             fd.write(b'X' * size)
 
-
     def create_test_files(self):
         """Create a minimal test case including all supported file types
         """