Restating project as flask app