This module seems to be the web interface for your pedometer service. However it has some file handling logic that should probably be in another module. This allows you to separate responsibilities. And if in the future you decided to change how data is stored (maybe from file objects to a small database) refactoring your code will be a lot easier.