def get_data_Weather():
while True:
print("Input the data for the Wunderground weather API.\n")
API_KEY = input("API Key:\n")
COUNTRY = input("Country:\n")
CITY = input("City:\n")
CITY_code = check_weather(API_KEY,COUNTRY, CITY)
if CITY_code == False:
if y_n("Retry?") == False:
raise Exception("User abort on Weather Data select.")
else:
break
while True:
print("Input the data for the DWD FTP Server.\n")
dwdname = input("Username:\n")
dwdpass = input("Password:\n")
if not check_dwdftp(dwdname, dwdpass):
if y_n("Retry?") == False:
raise Exception("User abort on DWD FTP Server data input.")
else:
break
return InputWeather(API_KEY, CITY_code,dwdname,dwdpass)
create_account.py 文件源码
python
阅读 26
收藏 0
点赞 0
评论 0
评论列表
文章目录