Pylint 1.8.3 fixes

Teach pylint more about the internals of API to fix various issues with
pylint 1.8.3.

Signed-off-by: Christian Heimes <cheimes@redhat.com>
Reviewed-By: Stanislav Laznicka <slaznick@redhat.com>
This commit is contained in:
Christian Heimes 2018-03-19 09:01:05 +01:00
parent 3bb3e7555d
commit ce8ec5028a

View File

@ -62,13 +62,22 @@ fake_backend = {'Backend': [
{'wsgi_dispatch': ['mount']},
]}
NAMESPACE_ATTRS = ['Command', 'Object', 'Method', fake_backend, 'Updater',
NAMESPACE_ATTRS = ['Object', 'Method', fake_backend, 'Updater',
'Advice']
fake_api_env = {'env': [
'host',
'realm',
'kinit_lifetime',
]}
fake_api_env = {
'env': [
'host',
'realm',
'kinit_lifetime',
],
'Command': [
'get_plugin',
'config_show',
'host_show',
'service_show',
'user_show',
],
}
# this is due ipaserver.rpcserver.KerberosSession where api is undefined
fake_api = {'api': [fake_api_env] + NAMESPACE_ATTRS}
@ -90,13 +99,17 @@ ipa_class_members = {
'ipalib.config.Env': [
{'__d': ['get']},
{'__done': ['add']},
'xmlrpc_uri',
'validate_api',
'startup_traceback',
'verbose',
'ca_host',
'ca_install_port',
'debug',
'server',
{'domain': dir(str)},
'http_timeout',
'rpc_protocol',
'startup_traceback',
'server',
'validate_api',
'verbose',
'xmlrpc_uri',
],
'ipalib.errors.ACIError': [
'info',