mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2024-12-23 07:33:27 -06:00
bf3083c376
https://pylint.pycqa.org/en/latest/user_guide/messages/convention/unnecessary-lambda-assignment.html: > Used when a lambda expression is assigned to variable rather than defining a standard function with the "def" keyword. https://peps.python.org/pep-0008/#programming-recommendations: > Always use a def statement instead of an assignment statement that binds a lambda expression directly to an identifier: def f(x): return 2*x f = lambda x: 2*x The first form means that the name of the resulting function object is specifically ‘f’ instead of the generic ‘<lambda>’. This is more useful for tracebacks and string representations in general. The use of the assignment statement eliminates the sole benefit a lambda expression can offer over an explicit def statement (i.e. that it can be embedded inside a larger expression) Fixes: https://pagure.io/freeipa/issue/9278 Signed-off-by: Stanislav Levin <slev@altlinux.org> Reviewed-By: Stanislav Levin <slev@altlinux.org> |
||
---|---|---|
.. | ||
data | ||
__init__.py | ||
test_aci.py | ||
test_backend.py | ||
test_base.py | ||
test_capabilities.py | ||
test_cli.py | ||
test_config.py | ||
test_crud.py | ||
test_errors.py | ||
test_frontend.py | ||
test_messages.py | ||
test_output.py | ||
test_parameters.py | ||
test_plugable.py | ||
test_rpc.py | ||
test_text.py | ||
test_util.py | ||
test_x509.py |