I am getting IndexError for following code
import ipinfo
access_token = '************'
handler = ipinfo.getHandler(access_token)
ip_country = lambda x:handler.getDetails(x).country
df1['country'] = df1["IP_address"].apply(ip_country)
There are few IP address for which it gives IndexError. For Example : 192.168.73.231, 10.62.100.139
If we try handler.getDetails('10.62.100.139').country, it will retrun IndexError:tuple index out of range.
Can you edit ipinfo package that it return NAN in such cases?
I am getting IndexError for following code
There are few IP address for which it gives
IndexError. For Example : 192.168.73.231, 10.62.100.139If we try
handler.getDetails('10.62.100.139').country, it will retrunIndexError:tuple index out of range.Can you edit ipinfo package that it return
NANin such cases?