From 8a517e38e07ff837a4c3abe8b7ad28cd9ae6954f Mon Sep 17 00:00:00 2001 From: Alex Meyer Date: Thu, 23 Jan 2020 20:38:12 -0800 Subject: [PATCH] Removed snow report --- snow_notify.py | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/snow_notify.py b/snow_notify.py index 4c9a800..3a89778 100644 --- a/snow_notify.py +++ b/snow_notify.py @@ -19,18 +19,15 @@ -snow_request = requests.get(config.snow_url) -snow_report = snow_request.json() -print(snow_report) -print("Lower snow report:",snow_report['lowersnow_in'],"inches.") -if snow_report['newsnow_in'] >= 3: +forecast_request = requests.get(config.forecast_url) +forecast_report = forecast_request.json() +print(forecast_report) +print("Lower snow report:",forecast_report['lowersnow_in'],"inches.") +if forecast_report['newsnow_in'] >= 3: print('You got Snow!') - print('The last snowfall size was',snow_report['lastsnow_in'],'inches.') - print('The snow type is',snow_report['conditions'],'.') + print('The last snowfall size was',forecast_report['lastsnow_in'],'inches.') + print('The snow type is',forecast_report['conditions'],'.') else: print('Hopefully soon!') - print('The last snowfall size was',snow_report['lastsnow_in'],'inches on',snow_report['lastsnow']) + print('The last snowfall size was',forecast_report['lastsnow_in'],'inches on',forecast_report['lastsnow']) -forecast_request = requests.get(config.forecast_url) -forecast_report = forecast_request.json() -print(forecast_report)