Fixed bug in checkpoint system in Remote module. Cleaned code using Flake8