diff --git a/solarconditions.py b/solarconditions.py index a521f30..800b5a6 100644 --- a/solarconditions.py +++ b/solarconditions.py @@ -57,21 +57,6 @@ def drap_xray_conditions(): xray_flux += "error fetching" return xray_flux -# def get_sunrise_sunset(lat=0, lon=0): -# from suntime import Sun, SunTimeException # pip install suntime -# if lat != 0 and lon != 0: -# sun = Sun(lat, lon) -# else: -# sun = Sun(LATITUDE, LONGITUDE) - -# to_zone = tz.tzlocal() -# today_sr = sun.get_sunrise_time(datetime.now()) -# today_ss = sun.get_sunset_time(datetime.now()) -# if today_ss < today_sr: # if sunset is before sunrise, then it's tomorrow -# today_ss = today_ss + timedelta(1) -# todaysun = [today_sr.astimezone(to_zone).strftime('%a %d %I:%M'), today_ss.astimezone(to_zone).strftime('%a %d %I:%M')] -# return todaysun - def get_sun(lat=0, lon=0): obs = ephem.Observer() obs.date = datetime.now()