Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Program Terminated: GQLException ['viewerDropCampaigns'] #651

Closed
Gabri404 opened this issue Dec 30, 2024 · 13 comments
Closed

Program Terminated: GQLException ['viewerDropCampaigns'] #651

Gabri404 opened this issue Dec 30, 2024 · 13 comments

Comments

@Gabri404
Copy link

Error During Program Execution

Problem Description

The application terminates with a fatal error when a GQLException occurs. The issue seems related to a service error involving the path ['channel', 'viewerDropCampaigns'].

Terminal Output

Here is the complete output showing the encountered error:

File "main.py", line 155, in main File "twitch.py", line 587, in run File "twitch.py", line 747, in run File "twitch.py", line 1660, in bulk_check_online File "asyncio\tasks.py", line 571, in wait_for_one File "twitch.py", line 1390, in gql_request

Output
15:00:04: Fatal error encountered:
15:00:04:
15:00:04: Traceback (most recent call last):
15:00:04:
15:00:04: exceptions. GQLException: [{'message': 'service error', 'path': ['channel', 'viewerDropCampaigns']}]
15:00:04:
15:00:04: Exiting...
15:00:04:
15:00:04: Application Terminated.
15:00:04: Close the window to exit the application

Attached Screenshot

Immagine 2024-12-30 150020
Immagine 2024-12-30 150125
Immagine 2024-12-30 150134

Additional Information

  • Operating System: Windows 11 Pro, 64Bit, Version 23H2 (Build SO 22631.4602).
  • Application Version: Dev-Build commit 1cd408f ( release 2024-12-25 16:37:53+00:00).
@iv8512
Copy link

iv8512 commented Dec 30, 2024

I am trying to do the Tarkov drops as well and I also got a Fatal error :: #650 (comment)

@DonatPlayZ
Copy link

Yes same for me. Worked Perfect till today! Sadly He also said that there is currently only a not 100% Working Version of the Tool. Was just wondering that it worked perfectly till today. Looks like Twitch changed something

@LuWoody
Copy link

LuWoody commented Dec 30, 2024

got the same error, seems to be the same issue / behavior as in #415

effected drop this time is the "Winter Drops day 1 pt.1", game "Escape from Tarkov" which is available from "Mon, Dec 30, 2:00 PM - Tue, Dec 31, 1:59 AM GMT+1"

possible workaround is to temporarily add "Escape from Tarkov" to the exclude list

2024-12-30_15-58-45

or configure it manually in the settings.json

"exclude": {
    "__type": "set",
    "data": [
        "Escape from Tarkov"
    ]
}

@DonatPlayZ
Copy link

Oh Okay! i use it only for Escape From Tarkov. Yesterday it worked for it... I will wait till th 31. maybe it work then

@villario
Copy link

villario commented Dec 30, 2024

It looks like it caused by some Twitch's limitation of number of gql reqests (I assume they added it today).
I've updated
self._qgl_limiter = RateLimiter(capacity=10, window=1) line 434 in twitch.py to
self._qgl_limiter = RateLimiter(capacity=5, window=1)
(I've picked a random number 5, it could be that any value less than 10 will work) and miner start working again.

I use direct Pyhton execution:
Prepare to run:

python -m virtualenv -p python venv
.\venv\Scripts\activate
pip install -r requirements.txt

Miner run:
python .\main.py

At the moment, miner is mining R6 drops (top priority) before it mined 65% of EFT's first drop.

@DonatPlayZ
Copy link

Looks like this works. Changed it to 5! Currently i Farm Escape from Tarkov! I will come back here when i mined some time to give Feedback!

@MysfitLeaf
Copy link

Looks like this works. Changed it to 5! Currently i Farm Escape from Tarkov! I will come back here when i mined some time to give Feedback!

Where do you find the file to edit this ?

@villario
Copy link

Looks like this works. Changed it to 5! Currently i Farm Escape from Tarkov! I will come back here when i mined some time to give Feedback!

Where do you find the file to edit this ?

No need to update anything. Please download the latest build https://github.com/DevilXD/TwitchDropsMiner/actions/runs/12549969180
DevilXD already updated the value

@DevilXD
Copy link
Owner

DevilXD commented Dec 30, 2024

Hello. Yeah, if that works, I figured I'd change it right away. The downside is that the miner will take longer to fetch all the channels, especially if you have many games added to the priority list. But better waiting a little while longer than crashing ig.

I'm still yet to add "service error" handling during claim, as well as handling "service error" in a less error-prone way than it currently is.

@NikolaJyun
Copy link

Using the version from https://github.com/DevilXD/TwitchDropsMiner/actions/runs/12549969180, errors are still occurring.

03:08:31: Fatal error encountered:
03:08:31:
03:08:31: Traceback (most recent call last):
03:08:31: File "main.py", line 155, in main
03:08:31: File "twitch.py", line 587, in run
03:08:31: File "twitch.py", line 648, in _run
03:08:31: File "inventory.py", line 259, in claim
03:08:31: File "inventory.py", line 142, in claim
03:08:31: File "inventory.py", line 158, in _claim
03:08:31: File "twitch.py", line 1390, in gql_request
03:08:31: exceptions.GQLException: [{'message': 'service error', 'path': ['claimDropRewards']}]
03:08:31:
03:08:31: Exiting...
03:08:32:
03:08:32: Application Terminated.
03:08:32: Close the window to exit the application.

@DevilXD
Copy link
Owner

DevilXD commented Dec 30, 2024

@NikolaJyun This is from claiming the rewards, as I said, I'm still working on that one. The original error that originated from fetching campaigns information (what this issue was about) was resolved.

#590 tracks that instead, and will be closed together with claim handling being implemented.

@DonatPlayZ
Copy link

Hey, just one little Update if it helps.. For me Its working now since 6 Hours straight mining with the change of the qgl to 5!

@DevilXD
Copy link
Owner

DevilXD commented Dec 30, 2024

The GQL rate limit was always supposed to be adjusted "by feel", as in: setting the value high, and gradually lowering it if one encounters problems. This ends at a point where there's no longer any problems occurring.

If 5 works reliably, I'll take it. Just note that lowering the rate limit will make the miner take longer during the reload process, which is something you may notice, depending on how many games you have added to the priority list, how many you have your account linked to, as well as what Priority Mode is set.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants