[GH-ISSUE #38] socket.timeout: timed out #32

Closed
opened 2026-03-02 23:37:29 +03:00 by kerem · 11 comments
Owner

Originally created by @jonap339 on GitHub (Jun 28, 2020).
Original GitHub issue: https://github.com/alexal1/Insomniac/issues/38

Dear, good afternoon.! My samsung s6 device after an internet outage started to throw the following error after entering the first follower to look at their photos. This is recurring, that is, it reaches the first follower and throws that message. Any ideas?

python insomniac.py --interact comerennuevacordoba --likes-count 3 --total-likes-limit 200

`C:\Users\usuario\Desktop\samsung\Insomniac>python insomniac.py --interact comerennuevacordoba --likes-count 3 --total-likes-limit 200
Insomniac v1.5.1

Action: interact with @comerennuevacordoba

-------- START: 2020-06-28 16:26:17.618545 --------
Open Instagram app
Sleep for 2 seconds
Press profile
Hello, @bokurajeanscba

Handle @comerennuevacordoba
Press search
Open user @comerennuevacordoba
Open @comerennuevacordoba followers
Iterate over visible followers
@eltallerdeltequenio: interact
Sleep for 4 seconds
Scroll down to see more photos.
Screenshot taken and saved as Crash-2020-06-28-16-31-26.png

TOTAL
Completed sessions: 0
Total duration: 0:05:12.256446
Total interactions: 0
Successful interactions: 0
Total likes: 0
Total followed: 0
Total unfollowed: 0
Traceback (most recent call last):
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 426, in _make_request
six.raise_from(e, None)
File "", line 3, in raise_from
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 421, in _make_request
httplib_response = conn.getresponse()
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\http\client.py", line 1332, in getresponse
response.begin()
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\http\client.py", line 303, in begin
version, status, reason = self._read_status()
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\http\client.py", line 264, in _read_status
line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1")
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\socket.py", line 669, in readinto
return self._sock.recv_into(b)
socket.timeout: timed out

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "insomniac.py", line 342, in
main()
File "insomniac.py", line 77, in main
_job_handle_bloggers(device,
File "insomniac.py", line 152, in _job_handle_bloggers
raise e
File "insomniac.py", line 133, in _job_handle_bloggers
handle_blogger(device, username, likes_count, follow_percentage, storage, _on_like, on_interaction)
File "C:\Users\usuario\Desktop\samsung\Insomniac\action_handle_blogger.py", line 26, in handle_blogger
_iterate_over_followers(device, interaction, storage, on_interaction, is_myself)
File "C:\Users\usuario\Desktop\samsung\Insomniac\action_handle_blogger.py", line 120, in _iterate_over_followers
interaction_succeed, followed = interaction(device, username=username, can_follow=can_follow)
File "C:\Users\usuario\Desktop\samsung\Insomniac\action_handle_blogger.py", line 164, in interact_with_user
if not scroll_profile(device):
File "C:\Users\usuario\Desktop\samsung\Insomniac\action_handle_blogger.py", line 256, in scroll_profile
profile_tabs_container_top = profile_tabs_container.bounds['top']
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\uiautomator_init
.py", line 934, in getattr
info = self.info
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\uiautomator_init
.py", line 945, in info
return self.jsonrpc.objInfo(self.selector)
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\uiautomator_init
.py", line 443, in wrapper
return JsonRPCMethod(url, method, timeout, False)(*args, **kwargs)
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\uiautomator_init
.py", line 438, in wrapper
return method_obj(*args, **kwargs)
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\uiautomator_init
.py", line 115, in call
res = self.pool.urlopen("POST",
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\poolmanager.py", line 336, in urlopen
response = conn.urlopen(method, u.request_uri, **kw)
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 724, in urlopen
retries = retries.increment(
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\util\retry.py", line 403, in increment
raise six.reraise(type(error), error, _stacktrace)
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\packages\six.py", line 735, in reraise
raise value
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 670, in urlopen
httplib_response = self._make_request(
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 428, in _make_request
self._raise_timeout(err=e, url=url, timeout_value=read_timeout)
File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 335, in _raise_timeout
raise ReadTimeoutError(
urllib3.exceptions.ReadTimeoutError: HTTPConnectionPool(host='localhost', port=9009): Read timed out. (read timeout=90)

C:\Users\usuario\Desktop\samsung\Insomniac>`

I already tried everything, I even did a full reset and everything remains the same, it goes into the first follower and dies there. The strange thing is that the rest of my devices work perfectly.

Suggestions?

Originally created by @jonap339 on GitHub (Jun 28, 2020). Original GitHub issue: https://github.com/alexal1/Insomniac/issues/38 Dear, good afternoon.! My samsung s6 device after an internet outage started to throw the following error after entering the first follower to look at their photos. This is recurring, that is, it reaches the first follower and throws that message. Any ideas? `python insomniac.py --interact comerennuevacordoba --likes-count 3 --total-likes-limit 200 ` `C:\Users\usuario\Desktop\samsung\Insomniac>python insomniac.py --interact comerennuevacordoba --likes-count 3 --total-likes-limit 200 Insomniac v1.5.1 Action: interact with @comerennuevacordoba -------- START: 2020-06-28 16:26:17.618545 -------- Open Instagram app Sleep for 2 seconds Press profile Hello, @bokurajeanscba Handle @comerennuevacordoba Press search Open user @comerennuevacordoba Open @comerennuevacordoba followers Iterate over visible followers @eltallerdeltequenio: interact Sleep for 4 seconds Scroll down to see more photos. Screenshot taken and saved as Crash-2020-06-28-16-31-26.png TOTAL Completed sessions: 0 Total duration: 0:05:12.256446 Total interactions: 0 Successful interactions: 0 Total likes: 0 Total followed: 0 Total unfollowed: 0 Traceback (most recent call last): File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 426, in _make_request six.raise_from(e, None) File "<string>", line 3, in raise_from File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 421, in _make_request httplib_response = conn.getresponse() File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\http\client.py", line 1332, in getresponse response.begin() File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\http\client.py", line 303, in begin version, status, reason = self._read_status() File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\http\client.py", line 264, in _read_status line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1") File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\socket.py", line 669, in readinto return self._sock.recv_into(b) socket.timeout: timed out During handling of the above exception, another exception occurred: Traceback (most recent call last): File "insomniac.py", line 342, in <module> main() File "insomniac.py", line 77, in main _job_handle_bloggers(device, File "insomniac.py", line 152, in _job_handle_bloggers raise e File "insomniac.py", line 133, in _job_handle_bloggers handle_blogger(device, username, likes_count, follow_percentage, storage, _on_like, on_interaction) File "C:\Users\usuario\Desktop\samsung\Insomniac\action_handle_blogger.py", line 26, in handle_blogger _iterate_over_followers(device, interaction, storage, on_interaction, is_myself) File "C:\Users\usuario\Desktop\samsung\Insomniac\action_handle_blogger.py", line 120, in _iterate_over_followers interaction_succeed, followed = interaction(device, username=username, can_follow=can_follow) File "C:\Users\usuario\Desktop\samsung\Insomniac\action_handle_blogger.py", line 164, in _interact_with_user if not _scroll_profile(device): File "C:\Users\usuario\Desktop\samsung\Insomniac\action_handle_blogger.py", line 256, in _scroll_profile profile_tabs_container_top = profile_tabs_container.bounds['top'] File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\uiautomator\__init__.py", line 934, in __getattr__ info = self.info File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\uiautomator\__init__.py", line 945, in info return self.jsonrpc.objInfo(self.selector) File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\uiautomator\__init__.py", line 443, in wrapper return _JsonRPCMethod(url, method, timeout, False)(*args, **kwargs) File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\uiautomator\__init__.py", line 438, in wrapper return _method_obj(*args, **kwargs) File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\uiautomator\__init__.py", line 115, in __call__ res = self.pool.urlopen("POST", File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\poolmanager.py", line 336, in urlopen response = conn.urlopen(method, u.request_uri, **kw) File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 724, in urlopen retries = retries.increment( File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\util\retry.py", line 403, in increment raise six.reraise(type(error), error, _stacktrace) File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\packages\six.py", line 735, in reraise raise value File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 670, in urlopen httplib_response = self._make_request( File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 428, in _make_request self._raise_timeout(err=e, url=url, timeout_value=read_timeout) File "C:\Users\usuario\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 335, in _raise_timeout raise ReadTimeoutError( urllib3.exceptions.ReadTimeoutError: HTTPConnectionPool(host='localhost', port=9009): Read timed out. (read timeout=90) C:\Users\usuario\Desktop\samsung\Insomniac>` I already tried everything, I even did a full reset and everything remains the same, it goes into the first follower and dies there. The strange thing is that the rest of my devices work perfectly. Suggestions?
kerem 2026-03-02 23:37:29 +03:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@alexal1 commented on GitHub (Jun 29, 2020):

The strange thing is that the rest of my devices work perfectly.

  1. Didn't this device fall asleep?
  2. Probably slightly different UI on this model/Android version. I'll need a uiautomatorviewer screenshot on the place where it crashed to find out the problem.
<!-- gh-comment-id:651042240 --> @alexal1 commented on GitHub (Jun 29, 2020): > The strange thing is that the rest of my devices work perfectly. 1. Didn't this device fall asleep? 2. Probably slightly different UI on this model/Android version. I'll need a `uiautomatorviewer` screenshot on the place where it crashed to find out the problem.
Author
Owner

@jonap339 commented on GitHub (Jun 29, 2020):

Alex, I think it's the account. Try the same account on another device and the same thing happens on that other device. I do not understand why this can happen, it will not be a form of instagram blocking? It happens with the account, not with the device.

<!-- gh-comment-id:651054656 --> @jonap339 commented on GitHub (Jun 29, 2020): Alex, I think it's the account. Try the same account on another device and the same thing happens on that other device. I do not understand why this can happen, it will not be a form of instagram blocking? It happens with the account, not with the device.
Author
Owner

@jonap339 commented on GitHub (Jun 29, 2020):

Today I tried again. It did less than 10 likes and then stopped working again. Attached screenshot with UiAutomatorviewer. I think if this is an instagram lock we are in trouble. Let's follow this case, as it can be a big problem! Regards!
ERR.zip

<!-- gh-comment-id:651095505 --> @jonap339 commented on GitHub (Jun 29, 2020): Today I tried again. It did less than 10 likes and then stopped working again. Attached screenshot with UiAutomatorviewer. I think if this is an instagram lock we are in trouble. Let's follow this case, as it can be a big problem! Regards! [ERR.zip](https://github.com/alexal1/Insomniac/files/4845547/ERR.zip)
Author
Owner

@alexal1 commented on GitHub (Jun 29, 2020):

git pull to get the latest version, please: hard to debug when there's an old code. And send full log again then.

I think if this is an instagram lock we are in trouble

That would be strange to block only specific action, leave others to work and not showing "Account blocked" window. But that account-connection is strange of course. Maybe that happens on this particular user "eltallerdeltequenio"? What about other profiles?

<!-- gh-comment-id:651119990 --> @alexal1 commented on GitHub (Jun 29, 2020): `git pull` to get the latest version, please: hard to debug when there's an old code. And send full log again then. > I think if this is an instagram lock we are in trouble That would be strange to block only specific action, leave others to work and not showing "Account blocked" window. But that account-connection is strange of course. Maybe that happens on this particular user "eltallerdeltequenio"? What about other profiles?
Author
Owner

@alexal1 commented on GitHub (Jun 29, 2020):

Can it be because of multiple devices connected at once? Theoretically adb works through single port and can be overloaded

<!-- gh-comment-id:651128753 --> @alexal1 commented on GitHub (Jun 29, 2020): Can it be because of multiple devices connected at once? Theoretically adb works through single port and can be overloaded
Author
Owner

@jonap339 commented on GitHub (Jun 29, 2020):

Alex, I'm already running the latest insomniac update. As you will see in the registry, enter the first follower, and die there. The problem persists. I attach the error and the screenshot with UiAutomatorViewer.
Answering your questions:
1- No, the mobile did not fall asleep since I have it next to it.
2- Attached the screenshot for you to check where it was blocked.
3- The problem is the account, enter the first follower, whatever it is, and it is blocked.
4- I tried to run only that device and it hangs the same. I don't think it's an overload problem.

Crash.zip

<!-- gh-comment-id:651398346 --> @jonap339 commented on GitHub (Jun 29, 2020): Alex, I'm already running the latest insomniac update. As you will see in the registry, enter the first follower, and die there. The problem persists. I attach the error and the screenshot with UiAutomatorViewer. Answering your questions: 1- No, the mobile did not fall asleep since I have it next to it. 2- Attached the screenshot for you to check where it was blocked. 3- The problem is the account, enter the first follower, whatever it is, and it is blocked. 4- I tried to run only that device and it hangs the same. I don't think it's an overload problem. [Crash.zip](https://github.com/alexal1/Insomniac/files/4848317/Crash.zip)
Author
Owner

@alexal1 commented on GitHub (Jul 1, 2020):

@jonap339 check please

<!-- gh-comment-id:652337279 --> @alexal1 commented on GitHub (Jul 1, 2020): @jonap339 check please
Author
Owner

@jonap339 commented on GitHub (Jul 1, 2020):

@alexal1 as we could verify, still does not move :( Please let me know what you need.! :(

<!-- gh-comment-id:652633753 --> @jonap339 commented on GitHub (Jul 1, 2020): @alexal1 as we could verify, still does not move :( Please let me know what you need.! :(
Author
Owner

@alexal1 commented on GitHub (Jul 3, 2020):

@jonap339 committed to the same branch, waiting for your response.

<!-- gh-comment-id:653610519 --> @alexal1 commented on GitHub (Jul 3, 2020): @jonap339 committed to the same branch, waiting for your response.
Author
Owner

@alexal1 commented on GitHub (Jul 5, 2020):

Finally merged PR #43

<!-- gh-comment-id:653909036 --> @alexal1 commented on GitHub (Jul 5, 2020): Finally merged PR #43
Author
Owner

@jusedit commented on GitHub (Aug 21, 2020):

Disabling follower based filter made this bug disappear.
I think the _get_followers_and_followings() function is failing.

<!-- gh-comment-id:678485147 --> @jusedit commented on GitHub (Aug 21, 2020): Disabling follower based filter made this bug disappear. I think the _get_followers_and_followings() function is failing.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Insomniac#32
No description provided.