AmEv7Fam/familysearch-python-sdk-opensource

urllib.error.URLError: <urlopen error [Errno 11004] getaddrinfo failed>

Opened this issue · 0 comments

Hi !
I use python 3.6.4 on Windows
I tried :
fs = FamilySearch('ClientApp/1.0', app_key)
I got this error:

Traceback (most recent call last):
  File "C:\Program Files (x86)\Python36-32\lib\urllib\request.py", line 1318, in do_open
    encode_chunked=req.has_header('Transfer-encoding'))
  File "C:\Program Files (x86)\Python36-32\lib\http\client.py", line 1239, in request
    self._send_request(method, url, body, headers, encode_chunked)
  File "C:\Program Files (x86)\Python36-32\lib\http\client.py", line 1285, in _send_request
    self.endheaders(body, encode_chunked=encode_chunked)
  File "C:\Program Files (x86)\Python36-32\lib\http\client.py", line 1234, in endheaders
    self._send_output(message_body, encode_chunked=encode_chunked)
  File "C:\Program Files (x86)\Python36-32\lib\http\client.py", line 1026, in _send_output
    self.send(msg)
  File "C:\Program Files (x86)\Python36-32\lib\http\client.py", line 964, in send
    self.connect()
  File "C:\Program Files (x86)\Python36-32\lib\http\client.py", line 1392, in connect
    super().connect()
  File "C:\Program Files (x86)\Python36-32\lib\http\client.py", line 936, in connect
    (self.host,self.port), self.timeout, self.source_address)
  File "C:\Program Files (x86)\Python36-32\lib\socket.py", line 704, in create_connection
    for res in getaddrinfo(host, port, 0, SOCK_STREAM):
  File "C:\Program Files (x86)\Python36-32\lib\socket.py", line 745, in getaddrinfo
    for res in _socket.getaddrinfo(host, port, family, type, proto, flags):
socket.gaierror: [Errno 11004] getaddrinfo failed

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "Z:\getmyancestors\test.py", line 7, in <module>
    fs = FamilySearch('ClientApp/1.0', app_key)
  File "Z:\getmyancestors\familysearch\__init__.py", line 122, in __init__
    Discovery.__init__(self)
  File "Z:\getmyancestors\familysearch\discovery.py", line 12, in __init__
    self.root_collection = self.get(self.base + '/.well-known/collection')
  File "Z:\getmyancestors\familysearch\__init__.py", line 217, in get
    url, data, headers, "GET", nojson), nojson)
  File "Z:\getmyancestors\familysearch\__init__.py", line 164, in _request
    return self.opener.open(request)
  File "C:\Program Files (x86)\Python36-32\lib\urllib\request.py", line 526, in open
    response = self._open(req, data)
  File "C:\Program Files (x86)\Python36-32\lib\urllib\request.py", line 544, in _open
    '_open', req)
  File "C:\Program Files (x86)\Python36-32\lib\urllib\request.py", line 504, in _call_chain
    result = func(*args)
  File "C:\Program Files (x86)\Python36-32\lib\urllib\request.py", line 1361, in https_open
    context=self._context, check_hostname=self._check_hostname)
  File "C:\Program Files (x86)\Python36-32\lib\urllib\request.py", line 1320, in do_open
    raise URLError(err)
urllib.error.URLError: <urlopen error [Errno 11004] getaddrinfo failed>