GramAddict / bot

Completely free and open-source human-like Instagram bot. Powered by UIAutomator2 and compatible with basically any Android device 5.0+ that can run Instagram - real or emulated.
https://docs.gramaddict.org
MIT License
1.14k stars 180 forks source link

RecursionError: maximum recursion depth exceeded while calling a Python object #301

Open vasavinyoeri opened 1 year ago

vasavinyoeri commented 1 year ago

Bot crashes

Environment:

Relevant Logs:

[04/08 00:46:48] ERROR | Traceback (most recent call last): File "/home/pi/.local/lib/python3.7/site-packages/GramAddict/core/decorators.py", line 31, in wrapper func(*args, *kwargs) File "/home/pi/.local/lib/python3.7/site-packages/GramAddict/plugins/interact_feed.py", line 90, in job interact_percentage, File "/home/pi/.local/lib/python3.7/site-packages/GramAddict/plugins/interact_feed.py", line 147, in handle_feed self.args.scrape_to_file, File "/home/pi/.local/lib/python3.7/site-packages/GramAddict/core/handle_sources.py", line 598, in handle_posts liked = post_view_list._check_if_liked() File "/home/pi/.local/lib/python3.7/site-packages/GramAddict/core/views.py", line 984, in _check_if_liked return PostsViewList(self.device)._check_if_liked() File "/home/pi/.local/lib/python3.7/site-packages/GramAddict/core/views.py", line 984, in _check_if_liked return PostsViewList(self.device)._check_if_liked() File "/home/pi/.local/lib/python3.7/site-packages/GramAddict/core/views.py", line 984, in _check_if_liked return PostsViewList(self.device)._check_if_liked() [Previous line repeated 948 more times] File "/home/pi/.local/lib/python3.7/site-packages/GramAddict/core/views.py", line 972, in _check_if_liked if bnt_like_obj.exists(): File "/home/pi/.local/lib/python3.7/site-packages/GramAddict/core/device_facade.py", line 569, in exists exists: bool = self.viewV2.exists(self.get_ui_timeout(ui_timeout)) File "/home/pi/.local/lib/python3.7/site-packages/uiautomator2/utils.py", line 115, in call return bool(self) File "/home/pi/.local/lib/python3.7/site-packages/uiautomator2/utils.py", line 105, in bool return self.nonzero() File "/home/pi/.local/lib/python3.7/site-packages/uiautomator2/utils.py", line 101, in nonzero return self.uiobject.jsonrpc.exist(self.uiobject.selector) File "/home/pi/.local/lib/python3.7/site-packages/uiautomator2/init.py", line 481, in call http_timeout) File "/home/pi/.local/lib/python3.7/site-packages/uiautomator2/init.py", line 487, in _jsonrpc_retry_call return self._jsonrpc_call(args, kwargs) File "/home/pi/.local/lib/python3.7/site-packages/uiautomator2/init.py", line 516, in _jsonrpc_call timeout=http_timeout) File "/usr/lib/python3/dist-packages/requests/sessions.py", line 581, in post return self.request('POST', url, data=data, json=json, kwargs) File "/home/pi/.local/lib/python3.7/site-packages/uiautomator2/init.py", line 203, in request return super().request(method, url, kwargs) File "/home/pi/.local/lib/python3.7/site-packages/uiautomator2/init.py", line 120, in request self).request(method, url, kwargs) File "/usr/lib/python3/dist-packages/requests/sessions.py", line 533, in request resp = self.send(prep, send_kwargs) File "/usr/lib/python3/dist-packages/requests/sessions.py", line 646, in send r = adapter.send(request, kwargs) File "/usr/lib/python3/dist-packages/requests/adapters.py", line 449, in send timeout=timeout File "/home/pi/.local/lib/python3.7/site-packages/urllib3/connectionpool.py", line 706, in urlopen chunked=chunked, File "/home/pi/.local/lib/python3.7/site-packages/urllib3/connectionpool.py", line 445, in _make_request six.raise_from(e, None) File "", line 3, in raise_from File "/home/pi/.local/lib/python3.7/site-packages/urllib3/connectionpool.py", line 440, in _make_request httplib_response = conn.getresponse() File "/usr/lib/python3.7/http/client.py", line 1352, in getresponse response.begin() File "/usr/lib/python3.7/http/client.py", line 334, in begin self.headers = self.msg = parse_headers(self.fp) File "/usr/lib/python3.7/http/client.py", line 228, in parse_headers return email.parser.Parser(_class=_class).parsestr(hstring) File "/usr/lib/python3.7/email/parser.py", line 68, in parsestr return self.parse(StringIO(text), headersonly=headersonly) File "/usr/lib/python3.7/email/parser.py", line 57, in parse feedparser.feed(data) File "/usr/lib/python3.7/email/feedparser.py", line 176, in feed self._call_parse() File "/usr/lib/python3.7/email/feedparser.py", line 180, in _call_parse self._parse() File "/usr/lib/python3.7/email/feedparser.py", line 295, in _parsegen if self._cur.get_content_maintype() == 'message': File "/usr/lib/python3.7/email/message.py", line 594, in get_content_maintype ctype = self.get_content_type() File "/usr/lib/python3.7/email/message.py", line 578, in get_content_type value = self.get('content-type', missing) File "/usr/lib/python3.7/email/message.py", line 471, in get return self.policy.header_fetch_parse(k, v) File "/usr/lib/python3.7/email/_policybase.py", line 316, in header_fetch_parse return self._sanitize_header(name, value) File "/usr/lib/python3.7/email/_policybase.py", line 287, in _sanitize_header if _has_surrogates(value): File "/usr/lib/python3.7/email/utils.py", line 57, in _has_surrogates s.encode() RecursionError: maximum recursion depth exceeded while calling a Python object (decorators.py:88) [04/08 00:46:48] CRITICAL | 'RecursionError: maximum recursion depth exceeded while calling a Python object ' -> This kind of exception will stop the bot (no restart). (decorators.py:91) [04/08 00:46:50] INFO | List of running apps: com.sec.spp.push, com.samsung.android.sm.provider, com.sec.android.app.launcher, com.anydesk.anydeskandroid, com.instagram.android, com.samsung.android.sm, com.android.contacts, com.github.uiautomator, com.samsung.android.providers.context, com.android.bluetooth, com.android.systemui, com.sec.android.provider.badge, com.samsung.ucs.agent.boot, com.samsung.android.beaconmanager, com.samsung.klmsagent, com.google.android.tts, com.android.managedprovisioning, com.sec.android.service.health, com.samsung.android.MtpApplication, com.samsung.android.app.assistantmenu, com.sec.android.app.shealth, com.sec.android.daemonapp, com.android.phone, com.google.android.gms, com.samsung.ucs.ucspinpad, com.sec.android.inputmethod, com.sec.smartcard.manager, com.sec.phone, com.android.nfc (decorators.py:94)

davidjaksa commented 1 year ago

I have the same problem

locolive commented 1 year ago

Same error here, Windows 11

kenpyfin commented 1 year ago

Same error

sagirab commented 8 months ago

I still get this issue. Any solution ?