Closed T4bletopG4mes closed 3 months ago
Pretty sure its Cult of the Lamb causing the error
I have the same issue on Ubuntu 20.04 with the AppImage when I start it it works fine but after like 3hours it's stuck and unresponsive
And I have seen the same issue with the Cannot connect to Twitch, retrying in 2 seconds...
Spam.
Seems like it has trouble gathering channels and/or cant communicate with twitch.
I have the same issue on Ubuntu 20.04 with the AppImage
Logs And I have seen the same issue with the
Cannot connect to Twitch, retrying in 2 seconds...
Spam.
Try to delete the cookies.jar.
I have gotten this problem a lot as well.
I believe I have found the culprit being that when gathering many ACL channels, like 100+ it tends to freeze. This gets even worse when there are like 500+ ACL channels. I have, in the worse case, seen TDM taking some 30 minutes just to complete gathering ACL channels. That's 30 minutes where TDM is not mining. TDM, in my experience, has never liked when there are too many ACL channels.
Take a look at these lines: https://github.com/Windows200000/TwitchDropsMiner-updated/blob/9b8427d436d24eb640570155eabb34d3b76ce519/twitch.py#L907-L908
If we change how many ACL channels are allowed per campaign, let's say, for example, 50, TDM will no longer freeze for long periods of time when gathering channels.
Here is my fix:
from itertools import chain, islice
...
if campaign.allowed_channels:
# limit to 50 channels per campaign
acl_channels.update(islice(campaign.allowed_channels, 50))
The only problem with this is that it will only get the first 50 in the "campaign.allowed_channels", meaning that some channels with higher view count or, even worse, all 50 ACL channels are offline and, therefore, might not be added to the list.
Maybe one could integrate an inputbox in the settings menu where one can enter how many ACL channels TDM is allowed to gather. If one enters 50, it only gathers the first 50 ACL channels per campaign, and if one enters 0 or nothing, it should gather all ACL channels per campaign, but that is just an idea.
Seems to have fixed itself for me, but Im sure there are some things that need to be changed still.
I made a dirty little script that restarts TDP once per hour to keep it farming. I know its not clean but it does the trick, if somebody wants it:
Runs TDM in a xvfb (virtual framebuffer) no window visible, should work also in a docker container (not tested)
#!/bin/bash
while true
do
echo 'Starting programm.'
xvfb-run -a ./Twitch.Drops.Miner-x86_64.AppImage --log &
date
echo 'Sleeping 1 hour'
sleep 1h
echo 'Killing process now!'
kill -s 9 $(ps -ef | grep -v grep | grep Twitch | awk '{print $2}')
sleep 3
kill -s 9 $(ps -ef | grep -v grep | grep Twitch | awk '{print $2}')
sleep 3
echo 'Killing done'
done
Tracked in #172
Description
TDM becomes unresponsive due to the log error below.
To Reproduce
Just open TDM, not sure what drop causes it, see screenshot provided for my active drops.
Expected behavior
Not to do that lol.
Observed behavior
TDM becomes unresponsive.
Screenshots
Logs
!!!required_minutes for "Support a Streamer Pack" is 0 This could be due to a subscription requirement, tracked in Issue #101!!! 05:03:05: Cannot connect to Twitch, retrying in 2 seconds... 05:03:05: Cannot connect to Twitch, retrying in 2 seconds... 05:03:05: Cannot connect to Twitch, retrying in 2 seconds... 05:03:05: Cannot connect to Twitch, retrying in 2 seconds... 05:03:05: Cannot connect to Twitch, retrying in 2 seconds... 05:03:05: Cannot connect to Twitch, retrying in 2 seconds... 05:03:05: Cannot connect to Twitch, retrying in 2 seconds... 05:03:05: Cannot connect to Twitch, retrying in 2 seconds... (It keeps spamming that till I terminate it) 05:03:15: Fatal error encountered: 05:03:15: 05:03:15: Traceback (most recent call last): 05:03:15: File "channel.py", line 249, in get_stream 05:03:15: File "twitch.py", line 1543, in gql_request 05:03:15: File "contextlib.py", line 199, in aenter 05:03:15: File "twitch.py", line 1494, in request 05:03:15: exceptions.ExitRequest: Application was requested to exit 05:03:15: 05:03:15: The above exception was the direct cause of the following exception: 05:03:15: 05:03:15: Traceback (most recent call last): 05:03:15: File "main.py", line 160, in main 05:03:15: File "twitch.py", line 772, in run 05:03:15: File "twitch.py", line 915, in _run 05:03:15: File "channel.py", line 286, in update_stream 05:03:15: File "channel.py", line 253, in get_stream 05:03:15: exceptions.MinerException: Channel: blackghost_ttv 05:03:15: 05:03:15: Exiting... 05:03:15: 05:03:15: Application Terminated. 05:03:15: Close the window to exit the application.
OS
Windows 10 (64-bit)
Build
.exe
Version/Commit
v15.8.2
Additional context
No response