I am trying to access an external api from aws glue script.
import requests
r = requests.get("https://api.github.com/users/hadley/orgs")
I'm getting a connection error stating,
ConnectionError: HTTPSConnectionPool(host='api.github.com/users/hadley/orgs', port=443): Max retries exceeded with url: / (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x7fb8ff471400>: Failed to establish a new connection: [Errno 101] Network is unreachable',))
Can anyone help? Thanks in advance!
Not sure if this has been answered yet but go to "Edit job" and remove your required connection if you have one. When you have a required connection it keeps you within your VPC not allowing for external connections.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With