This repository has been archived by the owner on Dec 4, 2024. It is now read-only.
forked from stripe/stripe-python
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.flake8
43 lines (40 loc) · 1.67 KB
/
.flake8
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
[flake8]
# E501 is the "Line too long" error. We disable it because we use Black for
# code formatting. Black makes a best effort to keep lines under the max
# length, but can go over in some cases.
# W503 goes against PEP8 rules. It's disabled by default, but must be disabled
# explicitly when using `ignore`.
# E704 is disabled in the default configuration, but by specifying `ignore`, we wipe that out.
# ruff formatting creates code that violates it, so we have to disable it manually
ignore = E501, W503, E704
per-file-ignores =
*/__init__.py: IMP100, E402, F401
# we test various import patterns
tests/test_exports.py: IMP100, IMP101, IMP102
tests/*: IMP101, IMP102, BAN100, ASY100
# backcompat with outdated import patterns
stripe/api_resources/*: IMP100, E402, F401
# IMP101: Do not import stripe
# breaking circular dependencies in overrides
stripe/_file.py: IMP101
stripe/_account.py: IMP101
stripe/_person.py: IMP101
stripe/_quote.py: IMP101
# IMP102: Do not create public modules
# contains a single deprecated class
stripe/api_resources/recipient_transfer.py: IMP102
# type names conflict with existing error names in stripe
stripe/oauth_error.py: IMP102
# setup.py is required for tooling
setup.py: IMP102
# should not raise a deprecation warning since it needs
# to be imported early in `stripe/__init__.py` to avoid
# a name conflict
stripe/app_info.py: IMP102
[flake8:local-plugins]
extension =
SPY = flake8_stripe:TypingImportsChecker
IMP = flake8_stripe:StripeImportsChecker
BAN = flake8_stripe:BanPublicMethodsChecker
ASY = flake8_stripe:AsyncNamingConventions
paths=./flake8_stripe