Skip to content

Commit 049d517

Browse files
committed
Cleaning for flake8-import-order
1 parent 5c8ba3f commit 049d517

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

110 files changed

+193
-174
lines changed

dev-requirements.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ flake8<3.6.0; python_version == '3.3'
55
flake8>=3.7.0,<3.8.0; python_version != '3.3'
66
flake8-coding
77
flake8-future-import<0.4.6
8+
flake8-import-order; python_version > '3.3'
9+
flake8-import-order<=1.18.1; python_version <= '3.3'
810
setuptools<40.0; python_version == '3.3'
911
sphinx
1012
sphinxcontrib-autoprogram

pytest_run.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
1212
https://sopel.chat
1313
"""
14-
from __future__ import unicode_literals, absolute_import, print_function, division
14+
from __future__ import absolute_import, division, print_function, unicode_literals
1515

1616
if __name__ == "__main__":
1717
import sys

setup.cfg

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@ pytest11 =
4040

4141
[flake8]
4242
max-line-length = 79
43+
application-import-names = sopel
44+
import-order-style = google
4345
ignore =
4446
# Line length limit. Acceptable (for now).
4547
E501,

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/usr/bin/env python
22
# coding=utf-8
3-
from __future__ import unicode_literals, absolute_import, print_function, division
3+
from __future__ import absolute_import, division, print_function, unicode_literals
44

55
import sys
66
import time

sopel.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
#!/usr/bin/env python3
22
# coding=utf-8
3-
from __future__ import unicode_literals, absolute_import, print_function, division
3+
from __future__ import absolute_import, division, print_function, unicode_literals
4+
45
import sys
6+
57
# Different from setuptools script, because we want the one in this dir.
68
from sopel.cli import run
9+
710
sys.exit(run.main())

sopel/__init__.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,15 @@
1010
#
1111
# Licensed under the Eiffel Forum License 2.
1212

13-
from __future__ import unicode_literals, absolute_import, print_function, division
13+
from __future__ import absolute_import, division, print_function, unicode_literals
1414

1515
from collections import namedtuple
1616
import locale
17-
import pkg_resources
1817
import re
1918
import sys
2019

20+
import pkg_resources
21+
2122
__all__ = [
2223
'bot',
2324
'config',

sopel/bot.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
#
77
# Licensed under the Eiffel Forum License 2.
88

9-
from __future__ import unicode_literals, absolute_import, print_function, division
9+
from __future__ import absolute_import, division, print_function, unicode_literals
1010

1111
from ast import literal_eval
1212
import collections
@@ -20,11 +20,11 @@
2020

2121
from sopel import irc, logger, plugins, tools
2222
from sopel.db import SopelDB
23-
from sopel.tools import Identifier, deprecated
23+
import sopel.loader
24+
from sopel.module import NOLIMIT
25+
from sopel.tools import deprecated, Identifier
2426
import sopel.tools.jobs
2527
from sopel.trigger import Trigger
26-
from sopel.module import NOLIMIT
27-
import sopel.loader
2828

2929

3030
__all__ = ['Sopel', 'SopelWrapper']

sopel/cli/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# coding=utf-8
2-
from __future__ import unicode_literals, absolute_import, print_function, division
2+
from __future__ import absolute_import, division, print_function, unicode_literals
33

44
# Shortcut imports
55
from .utils import ( # noqa

sopel/cli/config.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# coding=utf-8
22
"""Sopel Config Command Line Interface (CLI): ``sopel-config``"""
3-
from __future__ import unicode_literals, absolute_import, print_function, division
3+
from __future__ import absolute_import, division, print_function, unicode_literals
44

55
import argparse
66
import os

sopel/cli/plugins.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
# coding=utf-8
22
"""Sopel Plugins Command Line Interface (CLI): ``sopel-plugins``"""
3-
from __future__ import unicode_literals, absolute_import, print_function, division
3+
from __future__ import absolute_import, division, print_function, unicode_literals
44

55
import argparse
66
import inspect
77
import operator
88

99
from sopel import plugins, tools
10-
1110
from . import utils
1211

1312

0 commit comments

Comments
 (0)