Skip to content

[Bug] Invalid JSON format in debug_mpo.json causes JSONDecodeError #1265

@xueyunfeng123

Description

@xueyunfeng123

Checklist

  • 1. I have searched related issues but cannot get the expected help.
  • 2. The bug has not been fixed in the latest version.
  • 3. Please note that if the bug-related issue you submitted lacks corresponding environment info and a minimal reproducible demo, it will be challenging for us to reproduce and resolve the issue, reducing the likelihood of receiving feedback.

Describe the bug

I encountered a JSONDecodeError when loading the dataset configuration file:

ds_collections = json.loads(open("shell/data/debug_mpo.json").read())

The error message is:

json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 16 column 1 (char 572)

Root Cause:

The file shell/data/debug_mpo.json contains a trailing comma after the last element, which makes it invalid JSON.

Suggested Fix:

Remove the trailing comma in the JSON file:

{
    "m3cot_train_extracted_pairs_vqa_format_rules": {
        "root": "MMPR-v1.2/images/M3CoT",
        "annotation": "MMPR-v1.2/annotations/m3cot_train_extracted_pairs_vqa_format_rules.jsonl",
        "data_augment": false,
        "repeat_time": 1,
        "length": 201
    }
}

Reproduction

internvl_chat_gpt_oss/shell/internvl3_5_qwen3/internvl3_5_4b_mpo.sh

Environment

it is not important

Error traceback

json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 16 column 1 (char 572)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions