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

[Bug] fails to parse errors from curseforge #138

Open
fayer3 opened this issue Dec 18, 2024 · 3 comments
Open

[Bug] fails to parse errors from curseforge #138

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

Comments

@fayer3
Copy link

fayer3 commented Dec 18, 2024

Description

just had the plugin fail to publish a file to curseforge, and it only shows an error where it tried to parse a http response as a json
https://github.com/Vivecraft/VivecraftMod/actions/runs/12402760680/job/34625589433

Expected Behavior

show the complete error

Actual Behavior

only shows Error: SyntaxError: Unexpected token '<', "<!DOCTYPE "... is not valid JSON

Version

3.3

Environment

GitHub Actions

Configuration

No response

Logs

Run Kir-Antipov/[email protected]
  with:
    modrinth-id: wGoQDPN5
    modrinth-token: ***
    modrinth-featured: false
    curseforge-id: 667903
    curseforge-token: ***
    files: ./vivecraft-1.21.4-1.1.14-b4-fabric.jar
    name: Vivecraft 1.21.4-1.1.14-b4-fabric
    version: 1.21.4-1.1.14-b4-fabric
    version-type: beta
    loaders: fabric quilt
    modrinth-unfeature-mode: subset
    game-version-filter: releases
    retry-attempts: 2
    retry-delay: 10000
    fail-mode: fail
📤 Uploading assets to CurseForge
Error: SyntaxError: Unexpected token '<', "<!DOCTYPE "... is not valid JSON

Other Information

No response

@fayer3 fayer3 added the bug Something isn't working label Dec 18, 2024
@anviaan
Copy link

anviaan commented Dec 19, 2024

I got the same error as shown, but this about 6 hours ago it was working correctly

@Kir-Antipov
Copy link
Owner

To be quite frankly honest with you, I always thought it was reasonable to assume that a JSON API wouldn't throw an HTML page at you :) That said, this is CurseForge we're talking about. What likely happened here is that their API went down, and due to the poor Cloudflare configuration on their side, you received a standard shield page instead of something like HTTP 503. There's not much we can do in such scenarios, unfortunately. However, I could probably make the error message a bit more informative for users in this case?

@fayer3
Copy link
Author

fayer3 commented Dec 22, 2024

yeah, if it would show the raw html doc or something I can at least know what the issues is

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