flake8
don't use mutable types for default parameter values
connection: comprehensions for performance