nylas/nylas-python

SSLError: hostname 'api.nylas.com' doesn't match 'api.cac1.prod.nylas.com'

Closed this issue · 1 comments

OS: NAME=Ubuntu 14.04.6
Python Version: 2.7.6
Nylas Version: 4.12.0

I'm working on a legacy project and I'm unable to upgrade Python or Ubuntu. When I try and create a calendar I get the following error:

  File "/root/.virtualenvs/parakeet-api/local/lib/python2.7/site-packages/nylas/client/restful_models.py", line 116, in save
    new_obj = self.api._create_resource(self.cls, self.as_json(), **kwargs)
  File "/root/.virtualenvs/parakeet-api/local/lib/python2.7/site-packages/nylas/client/client.py", line 413, in _create_resource
    response = session.post(url, json=converted_data, headers=headers)
  File "/root/.virtualenvs/parakeet-api/local/lib/python2.7/site-packages/requests/sessions.py", line 504, in post
    return self.request('POST', url, data=data, json=json, **kwargs)
  File "/root/.virtualenvs/parakeet-api/local/lib/python2.7/site-packages/requests/sessions.py", line 461, in request
    resp = self.send(prep, **send_kwargs)
  File "/root/.virtualenvs/parakeet-api/local/lib/python2.7/site-packages/requests/sessions.py", line 573, in send
    r = adapter.send(request, **kwargs)
  File "/root/.virtualenvs/parakeet-api/local/lib/python2.7/site-packages/requests/adapters.py", line 431, in send
    raise SSLError(e, request=request)
SSLError: hostname 'api.nylas.com' doesn't match 'api.cac1.prod.nylas.com'

How do I workaround this error?

@chrislondon The Python SDK does not yet support calendar creation, and this appears to be a problem with the Calendar API rather than the Python SDK. Please reach out to support@nylas.com to discuss it; they are better equipped to help you and they might need you to share configuration details to resolve this problem.