i use raspbary py zero 2 w with phat, and then run the program.
python3 /home/akio/Pimoroni/inky/examples/phat/
But print time out error.How I can change? Please teach me.

Status code Unknown from ERROR - HTTPSConnectionPool(host=‘’, port=443): Read timed out. (read timeout=5.0)
Traceback (most recent call last):
File “/home/akio/Pimoroni/inky/examples/phat/”, line 112, in
weather = get_weather(location_string)
File “/home/akio/Pimoroni/inky/examples/phat/”, line 73, in get_weather
res = requests.get(“” + str(coords[0]) + “&longitude=” + str(coords[1]) + “&current_weather=true”)
TypeError: ‘NoneType’ object is not subscriptable

That error looks like the example is struggling to connect to the weather API, does this happen every time?

Is your Pi connected to the internet?

That error is the example is having trouble connecting to the weather API. I can connect once in 5 times.

The Pi is connected to the internet via Wi-Fi.

From the trace, it seems that has a problem. Not open-meteo.

You could add your latitude and longitude manually to this line (and comment out the coords = line) if you’re having trouble with the geocoder library/arcgis:

Thank you very much. I appreciate it.

1 Like