mohamed-chs / chatgpt-history-export-to-md

A script to effortlessly extract your entire ChatGPT data export from JSON files to nicely-formatted markdown files.
MIT License
707 stars 35 forks source link

No valid content found in message #36

Open yayaQAQ opened 8 months ago

yayaQAQ commented 8 months ago

Describe the bug after use yb66's code. I meet another problem.

OS

Additional context

image
python -m convoviz
Welcome to ChatGPT Data Visualizer βœ¨πŸ“Š!

Follow the instructions in the command line.

Press 'ENTER' to select the default options.

If you encounter any issues πŸ›, please report 🚨 them here:

➑️ https://github.com/mohamed-chs/chatgpt-history-export-to-md/issues/new/choose πŸ”—

? Enter the path to the zip file : /Users/apple/Downloads/75749080309a59310137b8f011a91137c34a6e18fc2683dfe935b8d2458b4d9d-2024-03-26-08-06-14/75749080309a59310137b8f011a91137c34a6e18fc2683dfe935b8d2458b4
d9d-2024-03-26-08-06-14.zip
? Enter the path to the output folder : /Users/apple/Documents/ChatGPT Data
? Enter the message header (#) for messages from 'system' : ### System
? Enter the message header (#) for messages from 'user' : # Me
? Enter the message header (#) for messages from 'assistant' : # ChatGPT
? Enter the message header (#) for messages from 'tool' : ### Tool output
? Select the LaTeX math delimiters you want to use : default
? Select the YAML metadata headers you want to include : done (9 selections)
? Select the font you want to use for the word clouds : RobotoSlab-Thin

? Select the color theme you want to use for the word clouds : prism
? Enter custom stopwords (separated by commas) : use, file,

And we're off! πŸš€πŸš€πŸš€

Loading data πŸ“‚ ...

Writing Markdown πŸ“„ files:   0%|▏                                                                                                                                          | 1/619 [00:00<00:03, 201.06it/s]
Traceback (most recent call last):
  File "/usr/local/anaconda3/envs/gpt4/lib/python3.10/runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/local/anaconda3/envs/gpt4/lib/python3.10/runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "/usr/local/anaconda3/envs/gpt4/lib/python3.10/site-packages/convoviz/__main__.py", line 5, in <module>
    main()
  File "/usr/local/anaconda3/envs/gpt4/lib/python3.10/site-packages/convoviz/cli.py", line 56, in main
    entire_collection.save(markdown_folder, progress_bar=True)
  File "/usr/local/anaconda3/envs/gpt4/lib/python3.10/site-packages/convoviz/models/_conversation_set.py", line 80, in save
    conversation.save(filepath)
  File "/usr/local/anaconda3/envs/gpt4/lib/python3.10/site-packages/convoviz/models/_conversation.py", line 214, in save
    file.write(self.markdown)
  File "/usr/local/anaconda3/envs/gpt4/lib/python3.10/site-packages/convoviz/models/_conversation.py", line 192, in markdown
    content = close_code_blocks(node.message.text)
  File "/usr/local/anaconda3/envs/gpt4/lib/python3.10/site-packages/convoviz/models/_message.py", line 90, in text
    raise ValueError(err_msg)
ValueError: No valid content found in message: 7a6cab36-b71a-47e9-a7cb-c7d774776a36