Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HTTPoison.Error :nxdomain in lib/ex_twilio/api.ex:19 #88

Closed
scottswezey opened this issue Mar 1, 2018 · 3 comments · Fixed by #91
Closed

HTTPoison.Error :nxdomain in lib/ex_twilio/api.ex:19 #88

scottswezey opened this issue Mar 1, 2018 · 3 comments · Fixed by #91

Comments

@scottswezey
Copy link

After upgrading to 0.5.1, Message API calls through ExTwilio are crashing with an error:

HTTPoison.Error :nxdomain in lib/ex_twilio/api.ex:19

I've been tried specifying the API domain in my config files, or leaving it out so the defaults apply. I verified that HTTPoison can connect to the api.twilio.com domain via iex -S mix. All ex_twilio source code I reviewed appears to be correct. Name resolution is working correctly on my testing system inside and out of BEAM.

I can't think of anything else to identify if the issue is local to my system, but wanted to open an issue in case others are finding the same behavior. Feel free to close if you can't reproduce.

Thanks

@scottswezey
Copy link
Author

While far from conclusive, reverting to ex_twilio version 0.5.0 resolved the issue.

@DavidVII
Copy link

DavidVII commented Mar 14, 2018

I'm getting a similar error when calling Message.all

> ExTwilio.Message.all                                                                                                                    
** (HTTPoison.Error) :nxdomain
    (ex_twilio) lib/ex_twilio/api.ex:19: ExTwilio.Api.request!/5
    (ex_twilio) lib/ex_twilio/result_stream.ex:45: ExTwilio.ResultStream.fetch_page/3
    (elixir) lib/stream.ex:1361: Stream.do_resource/5
    (elixir) lib/enum.ex:1919: Enum.reverse/1
    (elixir) lib/enum.ex:2588: Enum.to_list/1
    (elixir) lib/enum.ex:1163: Enum.into/2

Although other requests seem to appear to be working fine. For example, I'm able to use the Messages.create/1 method just fine.

@techgaun
Copy link
Contributor

@scottswezey @DavidVII I made a PR that I believe fixes this issue. The url generation was basically creating invalid urls

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants