could use os.pardir instead of ".."