Voldrix / onlyfans-dl-2

OnlyFans content downloader v2
GNU General Public License v3.0
169 stars 24 forks source link

Today an issue - Failed to establish a new connection: [Errno 11001] getaddrinfo failed')) #10

Closed CarlosJoseChaconChavarria closed 3 years ago

CarlosJoseChaconChavarria commented 3 years ago

hi I've been downloading for days straight but few minutes go I got this and the issue repeating and it won't let me continue not sure if it is specific file but now I can download any more files from that profile

**Secretgirl1/photos/2019-08-07_6026040/2019-08-07_49726797.jpeg Traceback (most recent call last): File "C:\Python39\lib\site-packages\urllib3\connection.py", line 169, in _new_conn conn = connection.create_connection( File "C:\Python39\lib\site-packages\urllib3\util\connection.py", line 73, in create_connection for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM): File "C:\Python39\lib\socket.py", line 953, in getaddrinfo for res in _socket.getaddrinfo(host, port, family, type, proto, flags): socket.gaierror: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 699, in urlopen httplib_response = self._make_request( File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 382, in _make_request self._validate_conn(conn) File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 1010, in _validate_conn conn.connect() File "C:\Python39\lib\site-packages\urllib3\connection.py", line 353, in connect conn = self._new_conn() File "C:\Python39\lib\site-packages\urllib3\connection.py", line 181, in _new_conn raise NewConnectionError( urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x0000013259554C40>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Python39\lib\site-packages\requests\adapters.py", line 439, in send resp = conn.urlopen( File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 755, in urlopen retries = retries.increment( File "C:\Python39\lib\site-packages\urllib3\util\retry.py", line 574, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='ca.convert.onlyfans.com', port=443): Max retries exceeded with url: /upload/9977bde30bd1886f13389e59ec2bcb06402235.jpeg (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x0000013259554C40>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "D:\oo\onlyfans-dl-3.py", line 223, in get_content("posts", "/users/" + PROFILE_ID + "/posts") File "D:\oo\onlyfans-dl-3.py", line 191, in get_content download_media(media, MEDIATYPE, album) File "D:\oo\onlyfans-dl-3.py", line 160, in download_media r = requests.get(source, stream=True) File "C:\Python39\lib\site-packages\requests\api.py", line 76, in get return request('get', url, params=params, kwargs) File "C:\Python39\lib\site-packages\requests\api.py", line 61, in request return session.request(method=method, url=url, kwargs) File "C:\Python39\lib\site-packages\requests\sessions.py", line 542, in request resp = self.send(prep, send_kwargs) File "C:\Python39\lib\site-packages\requests\sessions.py", line 655, in send r = adapter.send(request, kwargs) File "C:\Python39\lib\site-packages\requests\adapters.py", line 516, in send raise ConnectionError(e, request=request) requests.exceptions.ConnectionError: HTTPSConnectionPool(host='ca.convert.onlyfans.com', port=443): Max retries exceeded with url: /upload/9977bde30bd1886f13389e59ec2bcb06402235.jpeg (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x0000013259554C40>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')) PS D:\oo>_**

after trying again

**_Secretgirl1 exists. Downloading new media, skipping pre-existing. Found 535 posts Secretgirl1/photos/2019-08-07_6026040/2019-08-07_49726797.jpeg Traceback (most recent call last): File "C:\Python39\lib\site-packages\urllib3\connection.py", line 169, in _new_conn conn = connection.create_connection( File "C:\Python39\lib\site-packages\urllib3\util\connection.py", line 73, in create_connection for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM): File "C:\Python39\lib\socket.py", line 953, in getaddrinfo for res in _socket.getaddrinfo(host, port, family, type, proto, flags): socket.gaierror: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 699, in urlopen httplib_response = self._make_request( File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 382, in _make_request self._validate_conn(conn) File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 1010, in _validate_conn conn.connect() File "C:\Python39\lib\site-packages\urllib3\connection.py", line 353, in connect conn = self._new_conn() File "C:\Python39\lib\site-packages\urllib3\connection.py", line 181, in _new_conn raise NewConnectionError( urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x000002811C0E4AF0>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Python39\lib\site-packages\requests\adapters.py", line 439, in send resp = conn.urlopen( File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 755, in urlopen retries = retries.increment( File "C:\Python39\lib\site-packages\urllib3\util\retry.py", line 574, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='ca.convert.onlyfans.com', port=443): Max retries exceeded with url: /upload/9977bde30bd1886f13389e59ec2bcb06402235.jpeg (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x000002811C0E4AF0>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "D:\oo\onlyfans-dl-3.py", line 223, in get_content("posts", "/users/" + PROFILE_ID + "/posts") File "D:\oo\onlyfans-dl-3.py", line 191, in get_content download_media(media, MEDIATYPE, album) File "D:\oo\onlyfans-dl-3.py", line 160, in download_media r = requests.get(source, stream=True) File "C:\Python39\lib\site-packages\requests\api.py", line 76, in get return request('get', url, params=params, kwargs) File "C:\Python39\lib\site-packages\requests\api.py", line 61, in request return session.request(method=method, url=url, kwargs) File "C:\Python39\lib\site-packages\requests\sessions.py", line 542, in request resp = self.send(prep, send_kwargs) File "C:\Python39\lib\site-packages\requests\sessions.py", line 655, in send r = adapter.send(request, kwargs) File "C:\Python39\lib\site-packages\requests\adapters.py", line 516, in send raise ConnectionError(e, request=request) requests.exceptions.ConnectionError: HTTPSConnectionPool(host='ca.convert.onlyfans.com', port=443): Max retries exceeded with url: /upload/9977bde30bd1886f13389e59ec2bcb06402235.jpeg (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x000002811C0E4AF0>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))_**

any idea?

Thanks

CarlosJoseChaconChavarria commented 3 years ago

BTW I tried again I renamed the original profile folder and I see the new folder has the same amount of files so I am wondering if there is something related with this OF profile

I am starting to download a new profile and see

Voldrix commented 3 years ago

That error seems to be related to an open connection limit in the requests library. I guess I assumed they closed when the function ended. I've added an explicit close for each connection, pull the latest commit and try again.

CarlosJoseChaconChavarria commented 3 years ago

That error seems to be related to an open connection limit in the requests library. I guess I assumed they closed when the function ended. I've added an explicit close for each connection, pull the latest commit and try again.

well looks like something with that file specifically, it always stop there

/2019-08-07_49726797.jpeg

Secretgirl1/videos/2019-08-06_49497260.mp4 Secretgirl1/photos/2019-08-07_6026040/2019-08-07_49726797.jpeg Traceback (most recent call last): File "C:\Python39\lib\site-packages\urllib3\connection.py", line 169, in _new_conn conn = connection.create_connection( File "C:\Python39\lib\site-packages\urllib3\util\connection.py", line 73, in create_connection for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM): File "C:\Python39\lib\socket.py", line 953, in getaddrinfo for res in _socket.getaddrinfo(host, port, family, type, proto, flags): socket.gaierror: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 699, in urlopen httplib_response = self._make_request( File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 382, in _make_request self._validate_conn(conn) File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 1010, in _validate_conn conn.connect() File "C:\Python39\lib\site-packages\urllib3\connection.py", line 353, in connect conn = self._new_conn() File "C:\Python39\lib\site-packages\urllib3\connection.py", line 181, in _new_conn raise NewConnectionError( urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x000001FBE0D24C40>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Python39\lib\site-packages\requests\adapters.py", line 439, in send resp = conn.urlopen( File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 755, in urlopen retries = retries.increment( File "C:\Python39\lib\site-packages\urllib3\util\retry.py", line 574, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='ca.convert.onlyfans.com', port=443): Max retries exceeded with url: /upload/9977bde30bd1886f13389e59ec2bcb06402235.jpeg (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x000001FBE0D24C40>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "D:\OO\onlyfans-dl-4.py", line 223, in get_content("posts", "/users/" + PROFILE_ID + "/posts") File "D:\OO\onlyfans-dl-4.py", line 191, in get_content download_media(media, MEDIATYPE, album) File "D:\OO\onlyfans-dl-4.py", line 160, in download_media r = requests.get(source, stream=True) File "C:\Python39\lib\site-packages\requests\api.py", line 76, in get return request('get', url, params=params, kwargs) File "C:\Python39\lib\site-packages\requests\api.py", line 61, in request return session.request(method=method, url=url, kwargs) File "C:\Python39\lib\site-packages\requests\sessions.py", line 542, in request resp = self.send(prep, send_kwargs) File "C:\Python39\lib\site-packages\requests\sessions.py", line 655, in send r = adapter.send(request, kwargs) File "C:\Python39\lib\site-packages\requests\adapters.py", line 516, in send raise ConnectionError(e, request=request) requests.exceptions.ConnectionError: HTTPSConnectionPool(host='ca.convert.onlyfans.com', port=443): Max retries exceeded with url: /upload/9977bde30bd1886f13389e59ec2bcb06402235.jpeg (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x000001FBE0D24C40>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')) PS D:\OO>

Voldrix commented 3 years ago

The domain you are trying to connect to doesn't exist. Must be bad data on OF side. The requests library doesn't have a graceful way of dealing with nonexistent domains, so I've had to resort to a try catch block to detect that error. So now when you run it, you should get an error message that spits out the bad URL, but then just continues on. Also since printing every file downloaded can be kind of spamy, I set it to only do that if the max age parameters set. Just so you don't think it's stuck.

CarlosJoseChaconChavarria commented 3 years ago

The domain you are trying to connect to doesn't exist. Must be bad data on OF side. The requests library doesn't have a graceful way of dealing with nonexistent domains, so I've had to resort to a try catch block to detect that error. So now when you run it, you should get an error message that spits out the bad URL, but then just continues on. Also since printing every file downloaded can be kind of spamy, I set it to only do that if the max age parameters set. Just so you don't think it's stuck.

yes might be that profile and those URLs from that specific profile since I've downloaed 2 more profiles without any issues yesterday I was creating the files as dummies in the folder for this OF profile and the script was failing in with another picture then but I got tired of simulating dummy files lol

it works fine is just that profile, let me know I can share the creds so you can try

thanks great script

CarlosJoseChaconChavarria commented 3 years ago

BTW

Secretgirl1/photos/2019-08-07_6026040/2019-08-07_49726797.jpeg Traceback (most recent call last): File "C:\Python39\lib\site-packages\urllib3\connection.py", line 169, in _new_conn conn = connection.create_connection( File "C:\Python39\lib\site-packages\urllib3\util\connection.py", line 73, in create_connection for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM): File "C:\Python39\lib\socket.py", line 953, in getaddrinfo for res in _socket.getaddrinfo(host, port, family, type, proto, flags): socket.gaierror: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 699, in urlopen httplib_response = self._make_request( File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 382, in _make_request self._validate_conn(conn) File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 1010, in _validate_conn conn.connect() File "C:\Python39\lib\site-packages\urllib3\connection.py", line 353, in connect conn = self._new_conn() File "C:\Python39\lib\site-packages\urllib3\connection.py", line 181, in _new_conn raise NewConnectionError( urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x000001B3101B4400>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Python39\lib\site-packages\requests\adapters.py", line 439, in send resp = conn.urlopen( File "C:\Python39\lib\site-packages\urllib3\connectionpool.py", line 755, in urlopen retries = retries.increment( File "C:\Python39\lib\site-packages\urllib3\util\retry.py", line 574, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='ca.convert.onlyfans.com', port=443): Max retries exceeded with url: /upload/9977bde30bd1886f13389e59ec2bcb06402235.jpeg (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x000001B3101B4400>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "D:\oo\onlyfans-dl-3.py", line 223, in get_content("posts", "/users/" + PROFILE_ID + "/posts") File "D:\oo\onlyfans-dl-3.py", line 191, in get_content download_media(media, MEDIATYPE, album) File "D:\oo\onlyfans-dl-3.py", line 160, in download_media r = requests.get(source, stream=True) File "C:\Python39\lib\site-packages\requests\api.py", line 76, in get return request('get', url, params=params, kwargs) File "C:\Python39\lib\site-packages\requests\api.py", line 61, in request return session.request(method=method, url=url, kwargs) File "C:\Python39\lib\site-packages\requests\sessions.py", line 542, in request resp = self.send(prep, send_kwargs) File "C:\Python39\lib\site-packages\requests\sessions.py", line 655, in send r = adapter.send(request, kwargs) File "C:\Python39\lib\site-packages\requests\adapters.py", line 516, in send raise ConnectionError(e, request=request) requests.exceptions.ConnectionError: HTTPSConnectionPool(host='ca.convert.onlyfans.com', port=443): Max retries exceeded with url: /upload/9977bde30bd1886f13389e59ec2bcb06402235.jpeg (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x000001B3101B4400>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')) PS D:\oo>