mirror of
https://github.com/PyCQA/flake8.git
synced 2026-04-14 16:34:46 +00:00
Re-order project imports based on flake8-import-order
This commit is contained in:
parent
a4e984dbd2
commit
8d36355611
7 changed files with 14 additions and 11 deletions
|
|
@ -1,10 +1,10 @@
|
||||||
"""Command-line implementation of flake8."""
|
"""Command-line implementation of flake8."""
|
||||||
import flake8
|
import flake8
|
||||||
from flake8 import defaults
|
from flake8 import defaults
|
||||||
|
from flake8 import style_guide
|
||||||
from flake8.options import aggregator
|
from flake8.options import aggregator
|
||||||
from flake8.options import manager
|
from flake8.options import manager
|
||||||
from flake8.plugins import manager as plugin_manager
|
from flake8.plugins import manager as plugin_manager
|
||||||
from flake8 import style_guide
|
|
||||||
|
|
||||||
|
|
||||||
def register_default_options(option_manager):
|
def register_default_options(option_manager):
|
||||||
|
|
|
||||||
|
|
@ -5,8 +5,8 @@ applies the user-specified command-line configuration on top of it.
|
||||||
"""
|
"""
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
from flake8.options import config
|
|
||||||
from flake8 import utils
|
from flake8 import utils
|
||||||
|
from flake8.options import config
|
||||||
|
|
||||||
LOG = logging.getLogger(__name__)
|
LOG = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2,11 +2,11 @@
|
||||||
import collections
|
import collections
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
import pkg_resources
|
|
||||||
|
|
||||||
from flake8 import exceptions
|
from flake8 import exceptions
|
||||||
from flake8.plugins import notifier
|
|
||||||
from flake8 import utils
|
from flake8 import utils
|
||||||
|
from flake8.plugins import notifier
|
||||||
|
|
||||||
|
import pkg_resources
|
||||||
|
|
||||||
LOG = logging.getLogger(__name__)
|
LOG = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
"""Plugin built-in to Flake8 to treat pyflakes as a plugin."""
|
"""Plugin built-in to Flake8 to treat pyflakes as a plugin."""
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import absolute_import
|
from __future__ import absolute_import
|
||||||
|
|
||||||
try:
|
try:
|
||||||
# The 'demandimport' breaks pyflakes and flake8.plugins.pyflakes
|
# The 'demandimport' breaks pyflakes and flake8.plugins.pyflakes
|
||||||
from mercurial import demandimport
|
from mercurial import demandimport
|
||||||
|
|
@ -10,11 +11,11 @@ else:
|
||||||
demandimport.disable()
|
demandimport.disable()
|
||||||
import os
|
import os
|
||||||
|
|
||||||
|
from flake8 import utils
|
||||||
|
|
||||||
import pyflakes
|
import pyflakes
|
||||||
import pyflakes.checker
|
import pyflakes.checker
|
||||||
|
|
||||||
from flake8 import utils
|
|
||||||
|
|
||||||
|
|
||||||
def patch_pyflakes():
|
def patch_pyflakes():
|
||||||
"""Add error codes to Pyflakes messages."""
|
"""Add error codes to Pyflakes messages."""
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,10 @@
|
||||||
"""Implementation of the StyleGuide used by Flake8."""
|
"""Implementation of the StyleGuide used by Flake8."""
|
||||||
import collections
|
import collections
|
||||||
|
import enum
|
||||||
import linecache
|
import linecache
|
||||||
import logging
|
import logging
|
||||||
import re
|
import re
|
||||||
|
|
||||||
import enum
|
|
||||||
|
|
||||||
from flake8 import utils
|
from flake8 import utils
|
||||||
|
|
||||||
__all__ = (
|
__all__ = (
|
||||||
|
|
|
||||||
6
setup.py
6
setup.py
|
|
@ -1,10 +1,12 @@
|
||||||
"""Packaging logic for Flake8."""
|
"""Packaging logic for Flake8."""
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import with_statement
|
from __future__ import with_statement
|
||||||
import setuptools
|
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
import flake8
|
import setuptools
|
||||||
|
|
||||||
|
import flake8 # noqa
|
||||||
|
|
||||||
try:
|
try:
|
||||||
# Work around a traceback with Nose on Python 2.6
|
# Work around a traceback with Nose on Python 2.6
|
||||||
|
|
|
||||||
1
tox.ini
1
tox.ini
|
|
@ -22,6 +22,7 @@ use_develop = false
|
||||||
deps =
|
deps =
|
||||||
flake8
|
flake8
|
||||||
flake8-docstrings
|
flake8-docstrings
|
||||||
|
flake8-import-order
|
||||||
commands =
|
commands =
|
||||||
flake8
|
flake8
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue