python ping option with mail function