Imports cleanup
authorThierry Florac <tflorac@ulthar.net>
Wed, 24 Oct 2018 09:24:14 +0200
changeset 145 b3e0a7593d19
parent 144 c69cef8ed484
child 146 4b44f2acda26
Imports cleanup
src/pyams_file/file.py
--- a/src/pyams_file/file.py	Tue Oct 23 12:09:30 2018 +0200
+++ b/src/pyams_file/file.py	Wed Oct 24 09:24:14 2018 +0200
@@ -12,36 +12,31 @@
 
 __docformat__ = 'restructuredtext'
 
-
-# import standard library
-import os
-import shutil
 try:
     import magic
 except ImportError:
     magic = None
 
+import os
+import shutil
 from io import BytesIO
-from PIL import Image
-
-# import interfaces
-from pyams_file.interfaces import IFile, IImage, ISVGImage, IVideo, IAudio, IFileInfo, FileModifiedEvent
-from zope.copy.interfaces import ICopyHook, ResumeCopy
-from zope.location.interfaces import IContained
 
-# import packages
+from PIL import Image
+from ZODB.blob import Blob
 from persistent import Persistent
-from pyams_utils.adapter import adapter_config, ContextAdapter
+from zope.container.contained import Contained
+from zope.copy.interfaces import ICopyHook, ResumeCopy
+from zope.interface import implementer
+from zope.location.interfaces import IContained
+from zope.schema.fieldproperty import FieldProperty
+
+from pyams_file.interfaces import FileModifiedEvent, IAudio, IFile, IFileInfo, IImage, ISVGImage, IVideo
+from pyams_utils.adapter import ContextAdapter, adapter_config
 from pyams_utils.request import check_request
-from ZODB.blob import Blob
-from zope.container.contained import Contained
-from zope.interface import implementer
-from zope.schema.fieldproperty import FieldProperty
 
 
 BLOCK_SIZE = 1 << 16
 
-
 EXTENSIONS_THUMBNAILS = {
     '.7z': 'application-x-7z-compressed.png',
     '.ac3': 'audio-ac3.png',