Skip to content

Failure due to Json Error when Running test/exec #144

Closed
@ngin8-beta

Description

@ngin8-beta

Despite correctly specifying the session and csrf config, I encounter the following error. I have also performed leetcode data --delete and cleared the cache.

leetcode test 1

[INFO  leetcode_cli::plugins::leetcode] Sending code to judge...
JSON error: expected value at line 2 column 1, please double check your session and csrf config. JSON error: expected value at line 2 column 1, please double check your session and csrf config.

leetcode -d test 1

[2024-01-02T01:08:08Z INFO  leetcode_cli::plugins::leetcode] Sending code to judge...
[2024-01-02T01:08:08Z DEBUG reqwest::connect] starting new connection: https://leetcode.com/
JSON error: expected value at line 2 column 1, please double check your session and csrf config. JSON error: expected value at line 2 column 1, please double check your session and csrf config.
leetcode exec 1

[INFO  leetcode_cli::plugins::leetcode] Sending code to judge...
JSON error: expected value at line 2 column 1, please double check your session and csrf config. JSON error: expected value at line 2 column 1, please double check your session and csrf config.

leetcode -d exec 1

[2024-01-02T01:08:48Z INFO  leetcode_cli::plugins::leetcode] Sending code to judge...
[2024-01-02T01:08:48Z DEBUG reqwest::connect] starting new connection: https://leetcode.com/
JSON error: expected value at line 2 column 1, please double check your session and csrf config. JSON error: expected value at line 2 column 1, please double check your session and csrf config.
cat leetcode.toml

[code]
editor = 'vim'
lang = 'golang'

[cookies]
csrf = "${csrftoken}"
session = "${LEETCODE_SESSION}"

[storage]
cache = 'Problems'
code = 'code'
root = '~/.leetcode'
scripts = 'scripts'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions