mvabdi / vsco-scraper

Easily allows for scraping a VSCO
MIT License
133 stars 26 forks source link

('Connection aborted.', RemoteDisconnected('Remote end closed connection without response')) #50

Closed billyklubb closed 1 month ago

billyklubb commented 1 month ago

Hello all, has anyone experienced the below errors? These errors are produced instantly, it is like no connection attempt is even tried. Worked perfectly fine one day, and not the next. Any ideas what this is? I have tried to make sense of the errors, but no dice... appreciate any guidance!!

===================

[user@host test_vsco]$ vsco-scraper -i any-user Traceback (most recent call last): File "/usr/lib/python3.9/site-packages/urllib3/connectionpool.py", line 700, in urlopen httplib_response = self._make_request( File "/usr/lib/python3.9/site-packages/urllib3/connectionpool.py", line 446, in _make_request six.raise_from(e, None) File "", line 3, in raise_from File "/usr/lib/python3.9/site-packages/urllib3/connectionpool.py", line 441, in _make_request httplib_response = conn.getresponse() File "/usr/lib64/python3.9/http/client.py", line 1377, in getresponse response.begin() File "/usr/lib64/python3.9/http/client.py", line 320, in begin version, status, reason = self._read_status() File "/usr/lib64/python3.9/http/client.py", line 289, in _read_status raise RemoteDisconnected("Remote end closed connection without" http.client.RemoteDisconnected: Remote end closed connection without response

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/usr/lib/python3.9/site-packages/requests/adapters.py", line 439, in send resp = conn.urlopen( File "/usr/lib/python3.9/site-packages/urllib3/connectionpool.py", line 756, in urlopen retries = retries.increment( File "/usr/lib/python3.9/site-packages/urllib3/util/retry.py", line 534, in increment raise six.reraise(type(error), error, _stacktrace) File "/usr/lib/python3.9/site-packages/urllib3/packages/six.py", line 708, in reraise raise value.with_traceback(tb) File "/usr/lib/python3.9/site-packages/urllib3/connectionpool.py", line 700, in urlopen httplib_response = self._make_request( File "/usr/lib/python3.9/site-packages/urllib3/connectionpool.py", line 446, in _make_request six.raise_from(e, None) File "", line 3, in raise_from File "/usr/lib/python3.9/site-packages/urllib3/connectionpool.py", line 441, in _make_request httplib_response = conn.getresponse() File "/usr/lib64/python3.9/http/client.py", line 1377, in getresponse response.begin() File "/usr/lib64/python3.9/http/client.py", line 320, in begin version, status, reason = self._read_status() File "/usr/lib64/python3.9/http/client.py", line 289, in _read_status raise RemoteDisconnected("Remote end closed connection without" urllib3.exceptions.ProtocolError: ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/home/user/.local/bin/vsco-scraper", line 33, in sys.exit(load_entry_point('vsco-scraper==0.70', 'console_scripts', 'vsco-scraper')()) File "/home/user/.local/lib/python3.9/site-packages/vscoscrape/vscoscrape.py", line 748, in main scraper = Scraper(args.username) File "/home/user/.local/lib/python3.9/site-packages/vscoscrape/vscoscrape.py", line 20, in init self.session.get( File "/usr/lib/python3.9/site-packages/requests/sessions.py", line 557, in get return self.request('GET', url, kwargs) File "/usr/lib/python3.9/site-packages/requests/sessions.py", line 544, in request resp = self.send(prep, send_kwargs) File "/usr/lib/python3.9/site-packages/requests/sessions.py", line 657, in send r = adapter.send(request, **kwargs) File "/usr/lib/python3.9/site-packages/requests/adapters.py", line 498, in send raise ConnectionError(err, request=request) requests.exceptions.ConnectionError: ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response')) [user@host test_vsco]$

jgpotter075 commented 1 month ago

Getting the same. Or all just say Crashed. I only added the previous fix two weeks ago.

AL3433 commented 1 month ago

Same here, I just tried to run my usual command to scrape and all of them said: "[profile name] crashed"

timbo0o1 commented 1 month ago

They switched from http to https. open vscoscraper.py. search for http:// replace all of them with https://

then it should be working again

billyklubb commented 1 month ago

Hey timbo0o1, thank you! This worked perfectly! I appreciate your help... =)

for those that are on linux and want a faster way to make this change without errors, here is the sed command, though I suggest you create a backup of the vscoscrape.py file first!

backup file: cp -p vscoscrape.py vscoscrape.py.2024-10-15

then...

write the substitution to vscoscrape.py using sed: sed -i 's/http/https/g' vscoscrape.py

billyklubb commented 1 month ago

This issue has been resolved.