Skip to content

Commit

Permalink
Sort imports
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Sep 13, 2024
1 parent a575660 commit eefac29
Show file tree
Hide file tree
Showing 10 changed files with 12 additions and 18 deletions.
2 changes: 1 addition & 1 deletion tests/_test_params.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import types
import functools
import types

from more_itertools import always_iterable

Expand Down
1 change: 0 additions & 1 deletion tests/compat/py310.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import sys


if sys.version_info >= (3, 11):
from importlib.resources.abc import Traversable
else: # pragma: no cover
Expand Down
1 change: 0 additions & 1 deletion tests/compat/py38.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import sys


if (3, 9) <= sys.version_info < (3, 11): # pragma: no cover
from importlib.abc import Traversable # type: ignore[attr-defined, unused-ignore]
elif sys.version_info < (3, 9): # pragma: no cover
Expand Down
1 change: 0 additions & 1 deletion tests/compat/py39.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

from jaraco.test.cpython import from_test_support, try_import


os_helper = try_import('os_helper') or from_test_support(
'FakePath',
'temp_dir',
Expand Down
4 changes: 2 additions & 2 deletions tests/test_complexity.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
import re
import string
import unittest
from zipp.compat.overlay import zipfile

from jaraco.functools import compose
from more_itertools import consume

from ._support import import_or_skip
from zipp.compat.overlay import zipfile

from ._support import import_or_skip

big_o = import_or_skip('big_o')
pytest = import_or_skip('pytest')
Expand Down
10 changes: 5 additions & 5 deletions tests/test_path.py
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
import contextlib
import io
import itertools
import contextlib
import pathlib
import pickle
import stat
import sys
import time
import unittest
from zipp.compat.overlay import zipfile

from .compat.py39.os_helper import temp_dir, FakePath # type: ignore[import-not-found]

import jaraco.itertools
from jaraco.functools import compose

from ._test_params import parameterize, Invoked
from zipp.compat.overlay import zipfile

from ._test_params import Invoked, parameterize
from .compat.py39.os_helper import FakePath, temp_dir # type: ignore[import-not-found]


def _make_link(info: zipfile.ZipInfo): # type: ignore[name-defined]
Expand Down
1 change: 0 additions & 1 deletion tests/write-alpharep.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
from . import test_path


__name__ == '__main__' and test_path.build_alpharep_fixture().extractall('alpharep')
7 changes: 3 additions & 4 deletions zipp/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,20 +7,19 @@
for more detail.
"""

import contextlib
import io
import posixpath
import zipfile
import itertools
import contextlib
import pathlib
import posixpath
import re
import stat
import sys
import zipfile

from .compat.py310 import text_encoding
from .glob import Translator


__all__ = ['Path']


Expand Down
2 changes: 1 addition & 1 deletion zipp/compat/py310.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import sys
import io
import sys


def _text_encoding(encoding, stacklevel=2, /): # pragma: no cover
Expand Down
1 change: 0 additions & 1 deletion zipp/glob.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import os
import re


_default_seps = os.sep + str(os.altsep) * bool(os.altsep)


Expand Down

0 comments on commit eefac29

Please sign in to comment.