File tree Expand file tree Collapse file tree 2 files changed +3
-12
lines changed Expand file tree Collapse file tree 2 files changed +3
-12
lines changed Original file line number Diff line number Diff line change 11from __future__ import absolute_import
22
33import abc
4- import six
54import zipp
65
7- try :
8- import pathlib
9- except ImportError :
10- import pathlib2 as pathlib
6+ from ._compat import ABC , Path
117
128
13- __metaclass__ = type
14-
15-
16- @six .add_metaclass (abc .ABCMeta )
17- class Traversable :
9+ class Traversable (ABC ):
1810 @abc .abstractmethod
1911 def iterdir (self ):
2012 """
@@ -48,7 +40,7 @@ def is_file(self):
4840
4941def from_package (package ):
5042 """Return a Traversable object for the given package"""
51- package_directory = pathlib . Path (package .__spec__ .origin ).parent
43+ package_directory = Path (package .__spec__ .origin ).parent
5244 try :
5345 archive_path = package .__spec__ .loader .archive
5446 rel_path = package_directory .relative_to (archive_path )
Original file line number Diff line number Diff line change @@ -24,7 +24,6 @@ install_requires =
2424 pathlib2; python_version < '3'
2525 typing; python_version < '3.5'
2626 zipp >= 0.4
27- six
2827packages = find:
2928
3029[options.package_data]
You can’t perform that action at this time.
0 commit comments