Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit0f4abc0

Browse files
authored
Merge pull requestalexmojaki#26 from tony/lint-sort-packages
poetry: Add flake8, isort
2 parents2a4f3a4 +4bb006e commit0f4abc0

File tree

7 files changed

+83
-35
lines changed

7 files changed

+83
-35
lines changed

‎backend/main/chapters/c05_if_statements.py‎

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,7 @@
44
fromabcimportABC
55
fromtextwrapimportdedent
66

7-
frommain.textimport (
8-
ExerciseStep,
9-
MessageStep,
10-
Page,
11-
Step,
12-
VerbatimStep,
13-
search_ast,
14-
)
7+
frommain.textimportExerciseStep,MessageStep,Page,Step,VerbatimStep,search_ast
158
frommain.utilsimportreturns_stdout
169

1710

‎backend/main/chapters/c06_lists.py‎

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,7 @@
55
fromtypingimportList
66

77
frommain.exercisesimportgenerate_list,generate_string
8-
frommain.textimport (
9-
ExerciseStep,
10-
MessageStep,
11-
Page,
12-
Step,
13-
VerbatimStep,
14-
search_ast,
15-
)
8+
frommain.textimportExerciseStep,MessageStep,Page,Step,VerbatimStep,search_ast
169
frommain.utilsimportreturns_stdout
1710

1811

‎backend/main/workers/limits.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ def set_limits():
3636
exceptValueError:
3737
pass
3838

39-
frommain.workersimportsnoop,birdseye
39+
frommain.workersimportbirdseye,snoop
4040
str([snoop,birdseye])
4141

4242
patch_cwd()
@@ -46,8 +46,8 @@ def set_limits():
4646

4747
@lru_cache
4848
defdestroy_dangerous_functions():
49-
importsignal
5049
importgc
50+
importsignal
5151

5252
delsignal.sigwait.__doc__
5353

‎backend/main/workers/worker.py‎

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,7 @@
1010
frommain.textimportpages
1111
frommain.utilsimportprint_exception
1212
frommain.workers.limitsimportset_limits
13-
frommain.workers.utilsimport (
14-
internal_error_result,
15-
make_result,
16-
output_buffer,
17-
)
13+
frommain.workers.utilsimportinternal_error_result,make_result,output_buffer
1814

1915
log=logging.getLogger(__name__)
2016

‎poetry.lock‎

Lines changed: 76 additions & 10 deletions
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.

‎pyproject.toml‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ stack_data = "^0.0.7"
3434
production = ["gevent","gunicorn","psycopg2"]
3535

3636
[tool.poetry.dev-dependencies]
37+
flake8 = {version ="^3.8.3",optional =true}
38+
isort ="^5.1.4"
3739

3840
[build-system]
3941
requires = ["poetry>=0.12"]

‎setup.cfg‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,5 @@ include_trailing_comma = true
1212
multi_line_output = 3
1313
known_django = django
1414
known_first_party = main
15-
split_before_closing_bracket = true
1615
sections = FUTURE,STDLIB,DJANGO,THIRDPARTY,FIRSTPARTY,LOCALFOLDER
1716
line_length = 88
18-
not_skip = __init__.py

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp