-
Notifications
You must be signed in to change notification settings - Fork 52
/
Copy pathsetup.cfg
57 lines (56 loc) · 2.26 KB
/
setup.cfg
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
[flake8]
max-line-length = 79
docstring-convention = numpy
max-complexity = 10
ban-relative-imports = true
banned-modules =
guardian.shortcuts.get_objects_for_group = Please use grandchallenge.core.guardian.get_objects_for_group instead
guardian.shortcuts.get_objects_for_user = Please use grandchallenge.core.guardian.get_objects_for_user instead
guardian.mixins.PermissionListMixin = Please use grandchallenge.core.guardian.PermissionListMixin instead
guardian.mixins.PermissionRequiredMixin = Please use grandchallenge.core.guardian.ObjectPermissionRequiredMixin instead
config.settings = Please use django.conf.settings
rest_framework.permissions.IsAuthenticated = Please use grandchallenge.api.permissions.IsAuthenticated instead
rest_framework.permissions.IsAuthenticatedOrReadOnly = Please use grandchallenge.api.permissions.IsAuthenticatedOrReadOnly instead
django.contrib.sitemaps.Sitemap = Please use grandchallenge.core.sitemaps.SubdomainSitemap
django.core.mail.send_mail = Please use grandchallenge.emails.emails.send_standard_email_batch
celery.shared_task = Please use acks_late_2xlarge_task or acks_late_xlarge_task instead
datetime.datetime.now = Please use django.utils.timezone.now instead
grandchallenge.components.validate_scripts = Please do not import any validation script components
select =
# B are bugbear checks (including the optionals)
B
B9
# C are complexity checks
C
# D are docstring checks
D
E
F
I
N
W
ignore =
# TODO Select B023
B023
# TODO Select B950 too (line lengths)
B950
# TODO SEP21 JM Exception chaining, unsure on the consequences
B904
# D1 are public documentation checks
D1
# D400 First line should end with a period, see D205
D400
# D401 First line should be in imperative mood, lots of false positives
D401
# D202 No blank lines allowed after function docstring, conflicts with black
D202
# D205 1 blank line required between summary line and description
D205
# W503 is not PEP8 compliant (see black formatting)
W503
# N818 Exceptions should be named Error (TODO)
N818
# See https://black.readthedocs.io/en/stable/the_black_code_style/current_style.html#flake8
E203
E501
E704