Move tasks to tasks.py