Hello,
I am trying to download some images from (my local) wbsite and storing them on my Presto. But I encounter always the same error. The URL is accessible.
This is my code
import requests
image_file = 'image_1.png'
image_url = 'http://brimages.mydomain.local/image_1.png'
image.data = requests.get(image_url).content
with open(image_file, ‘wb’) as handler:
handler.write(br_image)
It gets stuck at the requests and returns error (after about 10 seconds):
Traceback (most recent call last):
File “requests/init.py”, line 205, in get
File “requests/init.py”, line 96, in request
OSError: [Errno 103] ECONNABORTED
It’s a local site, so “global” DNS resolving does not work.
Is there a possibility to have a kind of '“hosts” file in the Presto?