Skip to content

Commit

Permalink
Separate pylintrc for acme
Browse files Browse the repository at this point in the history
  • Loading branch information
kuba committed Jan 7, 2016
1 parent cc168c8 commit dba69d0
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 15 deletions.
23 changes: 13 additions & 10 deletions acme/.pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ persistent=yes

# List of plugins (as comma separated values of python modules names) to load,
# usually to register additional checkers.
load-plugins=
load-plugins=linter_plugin

# DEPRECATED
include-ids=no
Expand Down Expand Up @@ -60,7 +60,10 @@ confidence=
# --enable=similarities". If you want to run only the classes checker, but have
# no Warning level messages displayed, use"--disable=all --enable=classes
# --disable=W"
disable=E1608,W1627,E1601,E1603,E1602,E1605,E1604,E1607,E1606,W1621,W1620,W1623,W1622,W1625,W1624,W1609,W1608,W1607,W1606,W1605,W1604,W1603,W1602,W1601,W1639,W1640,I0021,W1638,I0020,W1618,W1619,W1630,W1626,W1637,W1634,W1635,W1610,W1611,W1612,W1613,W1614,W1615,W1616,W1617,W1632,W1633,W0704,W1628,W1629,W1636
disable=fixme,locally-disabled,abstract-class-not-used
# bstract-class-not-used cannot be disabled locally (at least in
# pylint 1.4.1/2)



[REPORTS]
Expand Down Expand Up @@ -133,7 +136,7 @@ notes=FIXME,XXX,TODO

# Logging modules to check that the string format arguments are in logging
# function parameter format
logging-modules=logging
logging-modules=logging,logger


[SPELLING]
Expand Down Expand Up @@ -200,7 +203,7 @@ init-import=no

# A regular expression matching the name of dummy variables (i.e. expectedly
# not used).
dummy-variables-rgx=_$|dummy
dummy-variables-rgx=_$|dummy|unused

# List of additional names supposed to be defined in builtins. Remember that
# you should avoid to define new builtins when possible.
Expand All @@ -220,7 +223,7 @@ required-attributes=
bad-functions=map,filter,input

# Good variable names which should always be accepted, separated by a comma
good-names=i,j,k,ex,Run,_
good-names=i,j,k,ex,Run,_,logger

# Bad variable names which should always be refused, separated by a comma
bad-names=foo,bar,baz,toto,tutu,tata
Expand All @@ -233,7 +236,7 @@ name-group=
include-naming-hint=no

# Regular expression matching correct function names
function-rgx=[a-z_][a-z0-9_]{2,30}$
function-rgx=[a-z_][a-z0-9_]{2,40}$

# Naming hint for function names
function-name-hint=[a-z_][a-z0-9_]{2,30}$
Expand Down Expand Up @@ -287,14 +290,14 @@ module-rgx=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
module-name-hint=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$

# Regular expression matching correct method names
method-rgx=[a-z_][a-z0-9_]{2,30}$
method-rgx=[a-z_][a-z0-9_]{2,49}$

# Naming hint for method names
method-name-hint=[a-z_][a-z0-9_]{2,30}$

# Regular expression which should only match function or class names that do
# not require a docstring.
no-docstring-rgx=__.*__
no-docstring-rgx=__.*__|test_[A-Za-z0-9_]*|_.*|.*Test

# Minimum line length for functions/classes that require docstrings, shorter
# ones are exempt.
Expand Down Expand Up @@ -324,7 +327,7 @@ exclude-protected=_asdict,_fields,_replace,_source,_make
[DESIGN]

# Maximum number of arguments for function / method
max-args=5
max-args=6

# Argument names that match this expression will be ignored. Default to name
# with leading underscore
Expand All @@ -343,7 +346,7 @@ max-branches=12
max-statements=50

# Maximum number of parents for a class (see R0901).
max-parents=7
max-parents=12

# Maximum number of attributes for a class (see R0902).
max-attributes=7
Expand Down
2 changes: 1 addition & 1 deletion acme/acme/challenges.py
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ class TLSSNI01Response(KeyAuthorizationChallengeResponse):
"""

@property
def z(self):
def z(self): # pylint: disable=invalid-name
"""``z`` value used for verification.
:rtype bytes:
Expand Down
2 changes: 1 addition & 1 deletion acme/acme/crypto_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ def _pick_certificate_cb(self, connection):
class FakeConnection(object):
"""Fake OpenSSL.SSL.Connection."""

# pylint: disable=missing-docstring
# pylint: disable=too-few-public-methods,missing-docstring

def __init__(self, connection):
self._wrapped = connection
Expand Down
4 changes: 2 additions & 2 deletions acme/acme/messages.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,13 @@ class Error(jose.JSONObjectWithFields, errors.Error):
('badCSR', 'The CSR is unacceptable (e.g., due to a short key)'),
('badNonce', 'The client sent an unacceptable anti-replay nonce'),
('connection', 'The server could not connect to the client to '
'verify the domain'),
'verify the domain'),
('dnssec', 'The server could not validate a DNSSEC signed domain'),
('malformed', 'The request message was malformed'),
('rateLimited', 'There were too many requests of a given type'),
('serverInternal', 'The server experienced an internal error'),
('tls', 'The server experienced a TLS error during domain '
'verification'),
'verification'),
('unauthorized', 'The client lacks sufficient authorization'),
('unknownHost', 'The server could not resolve a domain name'),
)
Expand Down
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ commands =
pip install -e acme -e .[dev] -e letsencrypt-apache -e letsencrypt-nginx -e letsencrypt-compatibility-test -e letshelp-letsencrypt
./pep8.travis.sh
pylint --rcfile=.pylintrc letsencrypt
pylint --rcfile=.pylintrc acme/acme
pylint --rcfile=acme/.pylintrc acme/acme
pylint --rcfile=.pylintrc letsencrypt-apache/letsencrypt_apache
pylint --rcfile=.pylintrc letsencrypt-nginx/letsencrypt_nginx
pylint --rcfile=.pylintrc letsencrypt-compatibility-test/letsencrypt_compatibility_test
Expand Down

0 comments on commit dba69d0

Please sign in to comment.