Flask and tornado working together