move import os just below the func def