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

401 on checkout #417

Open
laur89 opened this issue Dec 20, 2024 · 3 comments
Open

401 on checkout #417

laur89 opened this issue Dec 20, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@laur89
Copy link

laur89 commented Dec 20, 2024

Describe the bug

Checkout fails with 401

Logs

Detected distro: debian
Run on startup: true
[2024-12-20 12:35:35.816 +0100] INFO: Started epicgames-freegames-node
    COMMIT_SHA: "4d0fc205aa9be4869eee2e14b72403ed3929cd77"
    BRANCH: "master"
    DISTRO: "debian"
[2024-12-20 12:35:36.229 +0100] INFO: Checking free games for [email protected] 
    user: "[email protected]"
[2024-12-20 12:35:36.885 +0100] INFO: searchStrategy is `all`: searching for weekly and promotional games
    user: "[email protected]"
[2024-12-20 12:36:07.483 +0100] INFO: Available free games
    user: "[email protected]"
    availableGames: [
      "Vampire Survivors"
    ]
[2024-12-20 12:36:07.658 +0100] ERROR: Entitlements/cartOffersValidation: Request failed with status code 401
    user: "[email protected]"
    err: {
      "type": "Error",
      "message": "Entitlements/cartOffersValidation: Request failed with status code 401",
      "stack":
          Error: Entitlements/cartOffersValidation: Request failed with status code 401
              at PuppetFreeGames.canPurchase (/usr/app/src/puppet/free-games.ts:294:13)
              at async Promise.all (index 0)
              at PuppetFreeGames.getPurchasableFreeGames (/usr/app/src/puppet/free-games.ts:310:28)
              at PuppetFreeGames.getAllFreeGames (/usr/app/src/puppet/free-games.ts:436:30)
              at redeemAccount (/usr/app/src/index.ts:46:20)
              at async file:///usr/app/node_modules/p-queue/dist/index.js:187:36
    }
[2024-12-20 12:36:07.666 +0100] WARN: Current version
    COMMIT_SHA: "4d0fc205aa9be4869eee2e14b72403ed3929cd77"
    BRANCH: "master"
    DISTRO: "debian"
[2024-12-20 12:36:07.743 +0100] INFO: Exiting successfully
Run once: false
Setting cron schedule as 0 3,9,15,21 * * *

Additional context

version 4d0fc205aa9be4869eee2e14b72403ed3929cd77

@laur89 laur89 added the bug Something isn't working label Dec 20, 2024
@laur89
Copy link
Author

laur89 commented Dec 20, 2024

Could be a coincidence/red herring, but after manually logging into my epic account via browser, I was greeted by a new end user license agreement which I accepted. After that restarting the container successfully processed the checkout.

Feel like we should introduce a new config item allowing service to send push notification on errors so they can be dealt with. This 401 simply fails silently.

@Dared87
Copy link

Dared87 commented Dec 20, 2024

Yes, it was the same for me. I had the same 401 error and then logged in to Epic Games and went to the store. There, I was also greeted with a new End User License Agreement, and after accepting it, I was able to grab games again. Many thanks for that!

@claabs claabs pinned this issue Dec 21, 2024
@jroneilky
Copy link

Thank you! This same thing happened to me. 401 error. [2024-12-24 15:43:47.798 -0600] ERROR: Entitlements/cartOffersValidation: Request failed with status code 401

I was already logged in on my browser with cookies. Browsed to epicgames and the EULA popped up. Hit accept and closed the tab. Restarted the container and now it's working again.

I agree would be nice if these errors did not fail silently.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants