diff --git a/lib/location.py b/lib/location.py index 2afb377..572b36d 100644 --- a/lib/location.py +++ b/lib/location.py @@ -196,7 +196,6 @@ def location_processing(location, ip_addr): override_location_name = location[1:].replace('+', ' ') location = "%s,%s" % (geolocation['latitude'], geolocation['longitude']) full_address = geolocation['address'] - print full_address else: location = NOT_FOUND_LOCATION #location[1:] try: diff --git a/lib/wttr.py b/lib/wttr.py index 6e357e7..f8bbcfb 100644 --- a/lib/wttr.py +++ b/lib/wttr.py @@ -92,7 +92,6 @@ def get_wetter(location, ip, html=False, lang=None, query=None, location_name=No stdout = open(test_file, 'r').read() stderr = "" break - print "LOCATION = ", location if location == NOT_FOUND_LOCATION: location_not_found = True location = DEFAULT_LOCATION @@ -194,7 +193,6 @@ def get_wetter(location, ip, html=False, lang=None, query=None, location_name=No stdout = re.sub("", "" + title + opengraph, stdout) open(filename+'.html', 'w').write(stdout) - print "LOCATION >>> ", location filename = get_filename(location, lang=lang, query=query, location_name=location_name) if not os.path.exists(filename): save_weather_data(location, filename, lang=lang, query=query, location_name=location_name, full_address=full_address) @@ -221,7 +219,6 @@ def get_moon(location, html=False, lang=None): env = os.environ.copy() if lang: env['LANG'] = lang - print cmd p = Popen(cmd, stdout=PIPE, stderr=PIPE, env=env) stdout = p.communicate()[0] diff --git a/lib/wttr_srv.py b/lib/wttr_srv.py index addf63c..ea9984b 100644 --- a/lib/wttr_srv.py +++ b/lib/wttr_srv.py @@ -171,7 +171,7 @@ def wttr(location, request): query = parse_query.metric_or_imperial(query, lang, us_ip=us_ip) log(" ".join(map(str, [ - ip_addr, user_agent, orig_location.encode('utf-8'), location, + ip_addr, user_agent, (orig_location or "").encode('utf-8'), location, query.get('use_imperial', False), lang ])))