Closed m7zr closed 2 years ago
@Jorgen1040 can you help me please ?
I'm sorry, i don't know the code that well so i can't help you with this
@m7zr can you check if your game account (steam, epic, etc) is linked to Twitch and show your config.json
contents?
I made a test with Don't starve together
(a game I never played), to test the software I had to:
488634
to my config.json file.After 30 minutes I got a drop that I'll probably never get as I've never played this game, so everything is working correctly..
Could you give more details of the problem you are having?
My config.json
now looks like:
{
"browser": "/usr/bin/chromium-browser",
"games": ["30921", "488634"],
"headless": false,
"headless_login": false,
"interval": 10,
"load_timeout_secs": 180,
"hide_video": true,
"browser_args": ["--load-extension=/home/pi/.config/chromium/Default/Extensions/aleakchihdccplidncghkekgioiakgal/1.1.0_0/"]
}
I ran software and got this:
[2021-12-29 22:38:56] [info] Restoring cookies from last session.
[2021-12-29 22:38:56] [info] Logged in as ********
[2021-12-29 22:38:56] [info] Updating drop campaigns...
[2021-12-29 22:38:57] [info] Found 86 campaigns.
[2021-12-29 22:38:57] [info] Found 1 pending campaigns.
[2021-12-29 22:38:57] [info] Processing campaign: Don't Starve Together Don't Starve Together - Topsy-Turvy Treehouse
[2021-12-29 22:39:00] [info] Found 17 active streams
[2021-12-29 22:39:00] [info] Found 17 potential streams
[2021-12-29 22:39:00] [info] Watching stream: https://www.twitch.tv/magnumofspades
[2021-12-29 22:39:00] [info] Updating drop progress...
[2021-12-29 22:39:27] [info] Waiting for page to load...
[2021-12-29 22:39:46] [info] Set stream to lowest quality
[2021-12-29 22:39:46] [info] Set stream visibility to hidden
Watching https://www.twitch.tv/magnumofspades | Viewers: 425 | Uptime: 5:07:31
Topsy-Turvy... - Icon █░░░░░░░░░░░░░░░░░░░ 2 / 30 minutes
30 minutes later... :sunglasses:
[2021-12-29 23:04:00] [info] Found 1 pending campaigns.
Watching https://www.twitch.tv/magnumofspades | Viewers: 433 | Uptime: 5:35:24
Topsy-Turvy... - Icon ████████████████████ 30 / 30 minutes
[2021-12-29 23:08:17] [info] Claiming drop!
[2021-12-29 23:08:20] [info] Found 17 active streams
[2021-12-29 23:08:20] [info] Found 17 potential streams
[2021-12-29 23:08:20] [info] Watching stream: https://www.twitch.tv/magnumofspades
[2021-12-29 23:08:20] [info] Updating drop progress...
[2021-12-29 23:08:46] [info] Waiting for page to load...
[2021-12-29 23:08:52] [info] Set stream to lowest quality
[2021-12-29 23:08:52] [info] Set stream visibility to hidden
Watching https://www.twitch.tv/magnumofspades | Viewers: 444 | Uptime: 5:36:00
Topsy-Turvy Portrait ░░░░░░░░░░░░░░░░░░░░ 0 / 90 minutes
so if i want to start the bot every time with out login with user/pass what should i use command in config ? username:------- password:------- ? @FelipeCalliari
like i want to use my defalt chrome
and btw everything is linked like now i want "new world" drops and i have linked acc and still
so if i want to start the bot every time with out login with user/pass what should i use command in config ? username:------- password:------- ? @FelipeCalliari
Yes, you can put it into your config.json
if you don't have 2FA.
config.json
{ "browser": "C:\Program Files (x86)\Google\Chrome\Application\chrome.exe", // <--- check this "games": ["493597"], // <--- New World "username": "my_username", // <--- this only works "password": "my_password", // <--- if you don't have 2FA .... }
OR
If you have 2FA, I recommend creating a cookie. Go to Twitch-Drops-Bot
folder and run: npm run start
. After you login Twitch a file cookie-username.json
will be created inside Twitch-Drops-Bot
's folder. Then you can use your config.json
and this cookie
by running:
node /home/pi/Twitch-Drops-Bot/dist/index.js --config /home/pi/Twitch-Drops-Bot/config.json --cookies-path /home/pi/Twitch-Drops-Bot/cookies-username.json
Advantage: you could possibly use more than one account
like i want to use my defalt chrome
Ok, just check browser
on config.json
. The executable path may be different.
On Windows, it may be C:\\Program Files\\Google\\Chrome\\Application\\chrome.exe"
(without the (x86))
On Linux, run: which chromium-browser
and it will return the path for Chromium (for example: /usr/bin/chromium-browser
).
and btw everything is linked like now i want "new world" drops and i have linked acc and still
You must add 493597
to games
on config.json
. As shown above.
[2021-12-30 22:12:07] [error] Navigation timeout of 30000 ms exceeded TimeoutError: Navigation timeout of 30000 ms exceeded at D:\bots\Twitch-Drops-Bot-master\node_modules\puppeteer-core\lib\cjs\puppeteer\common\LifecycleWatcher.js:107:111 at async FrameManager.waitForFrameNavigation (D:\bots\Twitch-Drops-Bot-master\node_modules\puppeteer-core\lib\cjs\puppeteer\common\FrameManager.js:167:23) at async Frame.waitForNavigation (D:\bots\Twitch-Drops-Bot-master\node_modules\puppeteer-core\lib\cjs\puppeteer\common\FrameManager.js:524:16) at async Page.waitForNavigation (D:\bots\Twitch-Drops-Bot-master\node_modules\puppeteer-core\lib\cjs\puppeteer\common\Page.js:1229:16)
The timeout can be changed on config.json
, just add this line..
"load_timeout_secs": 180,
i have already ,and this my config
{ "browser": "C:\Program Files\Google\Chrome\Application\chrome.exe", "games": ["493597"], "username": "sssssssssssssssssss", "password": "sssssssssssssssssss", "headless": true, "headless_login": true, "interval": 10, "load_timeout_secs": 180, "hide_video": true, "browser_args": [] }
still the same issue @FelipeCalliari
Strange, is your Twitch-Drops-Bot
updated?
The message bellow does not make sense if you have "load_timeout_secs": 180,
..
[2021-12-30 22:12:07] [error] Navigation timeout of 30000 ms exceeded TimeoutError: Navigation timeout of 30000 ms exceeded
Advice: you could try set "headless": false,
to see if the webpage is loading..
still same issue :(
[2021-12-30 22:53:20] [info] Loading config file: config.json [2021-12-30 22:53:21] [info] Logging in... [2021-12-30 22:54:42] [info] Logged in as ------ [2021-12-30 22:54:42] [info] Saved cookies to ./cookies------- [2021-12-30 22:54:42] [info] Updating drop campaigns... [2021-12-30 22:54:43] [info] Found 87 campaigns. [2021-12-30 22:54:43] [info] Found 1 pending campaigns. [2021-12-30 22:54:43] [info] Processing campaign: New World The Wheel of Time Drops [2021-12-30 22:54:47] [info] Found 0 active streams [2021-12-30 22:54:47] [info] Found 0 potential streams [2021-12-30 22:54:47] [info] No streams! [2021-12-30 22:54:47] [info] No campaigns active/streams online. Checking again in 4.9 min.
[2021-12-31 00:14:55] [info] Found 0 active streams [2021-12-31 00:14:55] [info] Found 0 potential streams [2021-12-31 00:14:55] [info] No streams! [2021-12-31 00:14:55] [info] No campaigns active/streams online. Checking again in 4.9 min.
@FelipeCalliari
any help guys ? @FelipeCalliari @TychoTheTaco @Kyraminol @sibalzer @agret
there's a lot of streame's online and with twitch drops in new world but the bot says ther's no channel is online any fix ?
Had the same problem. For me it worked that I opened the Twitch-Drops-Bot-master Folder -> right click in open space -> open in windows terminal -> and starting the bot with the code "npm run start"
I'm running the bot in a docker container on my server and where it works for EFT and some other random games I tried, it refuses to find any valid streams for New World
.
My logs message line up with those posted by @m7zr. Here is an example snippet with the following ID's in the config:
"493597",
"491931"
[2022-01-01 19:32:06] [info] Processing campaign: New World The Wheel of Time Drops
[2022-01-01 19:32:08] [info] Found 0 active streams
[2022-01-01 19:32:08] [info] Found 0 potential streams
[2022-01-01 19:32:08] [info] No streams!
[2022-01-01 19:32:08] [info] Processing campaign: Escape from Tarkov EFT Holiday Drops day 5
[2022-01-01 19:32:09] [info] Found 30 active streams
I ensured the Twitch account is linked. The bot is running in a headless mode. I'm more than happy to provide any other data you might need.
I've gone ahead and tried to debug this, I found that Twitch API returns only the following as allowed channels for the New World drops event:
"allow":{
"channels":[
{
"id":"465463608",
"displayName":"pdxtest_michaels",
"__typename":"Channel"
},
{
"id":"539570738",
"displayName":"pdxtest_jacobl",
"__typename":"Channel"
},
{
"id":"743978432",
"displayName":"pxtest_alexd",
"__typename":"Channel"
},
{
"id":"509727100",
"displayName":"irvtest_chrisd",
"__typename":"Channel"
},
{
"id":"750827607",
"displayName":"dauealel",
"__typename":"Channel"
},
{
"id":"710323845",
"displayName":"pdxtest_brandonr",
"__typename":"Channel"
},
{
"id":"693209966",
"displayName":"tsstocke",
"__typename":"Channel"
}
],
"isEnabled":false,
"__typename":"DropCampaignACL"
},
Whereas, the ID's we get from Twitch API for active streams returns:
552120296, 44741426, 32085830, 97782735, 38811904, 8180455, 74051626, 122256358, 78566531, 51207713, 152854195, 48642944, 181229509, 55572703, 217892201, 78603455, 138954063, 90759009, 653118103, 488737102, 179739262, 103205995, 99720080, 637052005, 409185670, 180172636, 27243963, 82073617, 157825357, 56673767
None of the channels reported by Twitch API as in participating with the drops campaign match. Which is odd, because there's a ton of channels participating
I haven't worked out how to run the application in debug, so I just been doing logger.info(...)
this whole time and it's time consuming so that's all I can prepare for you. Possible causes I can think of could be in relation to the campaign that's being retrieved? Perhaps Twitch messed up and created two campaigns, and we only retrieve the first one? No clue how that logic is handled by the bot as I haven't looked at it.
FYI @FelipeCalliari
Thanks for the help @LethalsLoaded! I think this issue has to do with the isEnabled
field that the API returns. It seems to be false
for New World, whereas for most other games it was true
. I'm assuming that when it is false
, the allow
filter should not be applied, so I've just pushed a fix for this.
@TychoTheTaco so what should i do cuz i will miss the drops
Just pull the new code and then start the bot. Or if you are using docker pull the new image and start it
so i fixed everything and now working good, but now there's a lot of active streams and with "Drops Enabled" and it keep saying there's no strems active now, how do i fix this , thanks for your support guys <3 @TychoTheTaco @FelipeCalliari [2021-12-30 00:53:50] [info] Updating drop campaigns... [2021-12-30 00:53:50] [info] Found 85 campaigns. [2021-12-30 00:53:50] [info] Found 1 pending campaigns. [2021-12-30 00:53:50] [info] Processing campaign: New World The Wheel of Time Drops [2021-12-30 00:53:55] [info] Found 0 active streams [2021-12-30 00:53:55] [info] Found 0 potential streams [2021-12-30 00:53:55] [info] No streams! [2021-12-30 00:53:55] [info] No campaigns active/streams online. Checking again in 4.9 min. [2021-12-30 00:58:50] [info] Processing campaign: New World The Wheel of Time Drops [2021-12-30 00:58:54] [info] Found 0 active streams [2021-12-30 00:58:54] [info] Found 0 potential streams [2021-12-30 00:58:54] [info] No streams! [2021-12-30 00:58:54] [info] No campaigns active/streams online. Checking again in 4.9 min. [2021-12-30 01:03:50] [info] Processing campaign: New World The Wheel of Time Drops [2021-12-30 01:03:55] [info] Found 0 active streams [2021-12-30 01:03:55] [info] Found 0 potential streams [2021-12-30 01:03:55] [info] No streams! [2021-12-30 01:03:55] [info] No campaigns active/streams online. Checking again in 4.9 min.