Optmizing request to avoid dict creation at method invocation. Upgrading flake8 and coverage