Get requests.exceptions.ConnectionError While Trying to Trigger APIs on Dash UI

Hello, I ran my dashboard in EC2 and tried to trigger API calculations in an external website. However, I got the following ConnectionError which I have never seen when my project ran locally using PyCharm IDE (I’ve hided the host url below for safety concern):

requests.exceptions.ConnectionError: HTTPConnectionPool(host=‘xxx.com’, port=80): Max retries exceeded with url: /poly/com.polypaths.ent.gui.pprequest.polyAPI?importBO%20in_file%20filter.xml (Caused by NewConnectionError(‘<urllib3.connection.HTTPConnection object at 0x7f0cc38be460>: Failed to establish a new connection: [Errno 110] Connection timed out’))

In the Debug mode it appears to be “Callback error updating …”
Any ideas on how to resolve this issue? Thanks!

Hi,

Does the EC2 instance has access to the external website? For instance, can you reach it using curl or requests outside the Dash app?

This does not seem to be related to Dash tbh…