Skip to content

Commit abd0ade

Browse files
committed
Create .flake8
1 parent a65a86e commit abd0ade

File tree

1 file changed

+59
-0
lines changed

1 file changed

+59
-0
lines changed

.flake8

+59
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
# -*- coding: utf-8 -*-
2+
3+
# =============================================================================
4+
# Flake8 Configuration
5+
# =============================================================================
6+
7+
[flake8]
8+
# Ignore the following rules:
9+
# - E203: Whitespace before ':' (often conflicts with Black)
10+
# - E266: Too many leading '#' for block comments
11+
# - E501: Line too long (handled by Black)
12+
# - W503: Line break occurred before a binary operator (handled by Black)
13+
# - F401: Ignore unused imports in `__init__.py` files (often used for API exposure)
14+
ignore =
15+
E203,
16+
E266,
17+
E501,
18+
W503,
19+
F401
20+
21+
# Enable the following rules:
22+
# - E731: Do not assign a lambda expression, use a def
23+
# - F405: May be undefined, or defined from star imports
24+
enable-extensions =
25+
E731,
26+
F405
27+
28+
# Maximum allowed McCabe complexity (useful to identify overly complex code)
29+
max-complexity = 10
30+
31+
# Maximum line length allowed (often set to match Black's default)
32+
max-line-length = 79
33+
34+
# Show the source code for each error
35+
show-source = True
36+
37+
# Count the number of issues instead of printing them all
38+
statistics = True
39+
40+
# Exclude these directories and files from being checked
41+
exclude =
42+
.git,
43+
__pycache__,
44+
build,
45+
dist,
46+
.venv,
47+
.eggs,
48+
*.egg,
49+
*.egg-info,
50+
.tox,
51+
.mypy_cache,
52+
docs/conf.py
53+
54+
# Specify the files to include (you can be specific or generic)
55+
# For example: include all Python files
56+
include = *.py
57+
58+
# Set this to True if you want to allow `# noqa` comments to silence flake8 warnings
59+
enable-noqa = True

0 commit comments

Comments
 (0)