You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi @Pierrrrrrre ,
very nice script thanks! It is very useful for reports! Unfortunately freegeoip is down now so the script does not work anymore. For this I have just hacked the script to include:
diff --git a/pygeoipmap.py b/pygeoipmap.py
index 2fddb0f..0b1816a 100644
--- a/pygeoipmap.py
+++ b/pygeoipmap.py
@@ -31,9 +31,10 @@ def get_lat_lon(ip_list=[], lats=[], lons=[]):
"""
print("Processing {} IPs...".format(len(ip_list)))
for ip in ip_list:
- r = requests.get("https://freegeoip.net/json/" + ip)
+ #r = requests.get("https://freegeoip.net/json/" + ip)
+ r = requests.get("https://www.telize.com/geoip/" + ip)
json_response = r.json()
- print("{ip}, {region_name}, {country_name}, {latitude}, {longitude}".format(**json_response))
+ print("{ip}, {continent_code}, {country}, {latitude}, {longitude}".format(**json_response))
if json_response['latitude'] and json_response['longitude']:
lats.append(json_response['latitude'])
lons.append(json_response['longitude'])
and use telize.com. I did not do a merge request because telize will shut down soon too .
Thanks again,
Denis
The text was updated successfully, but these errors were encountered:
Hi @Pierrrrrrre ,
very nice script thanks! It is very useful for reports! Unfortunately freegeoip is down now so the script does not work anymore. For this I have just hacked the script to include:
and use telize.com. I did not do a merge request because telize will shut down soon too .
Thanks again,
Denis
The text was updated successfully, but these errors were encountered: