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
703 stars 34 forks source link

error File "<frozen runpy>", line 198, in _run_module_as_main #27

Open Kmfernan5 opened 12 months ago

Kmfernan5 commented 12 months ago

? Enter the path to the zip file : C:\Users\djtlm\Documents\GitHub\chatgpt-history-export-to-md\openai-export cd833544d 1e9d430427877b3357ec5b40df5d0062769dde85ac4b09bc0e74a93-2023-11-12-21-19-05.zip ? Enter the path to the output folder : C:\Users\djtlm\Documents\GitHub\chatgpt-history-export-to-md\output ? 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 📂 ...

Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "C:\Users\djtlm\AppData\Local\Programs\Python\Python311\Lib\site-packages\convoviz__main.py", line 5, in main() File "C:\Users\djtlm\AppData\Local\Programs\Python\Python311\Lib\site-packages\convoviz\cli.py", line 38, in main entire_collection = ConversationSet.from_zip(user.configs["zip_filepath"]) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\djtlm\AppData\Local\Programs\Python\Python311\Lib\site-packages\convoviz\models_conversation_set.py", line 55, in from_zip return cls.from_json(convos_path) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\djtlm\AppData\Local\Programs\Python\Python311\Lib\site-packages\convoviz\models_conversation_set.py", line 47, in from_json return cls(array=loads(file.read())) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\djtlm\AppData\Local\Programs\Python\Python311\Lib\site-packages\pydantic\main.py", line 164, in init pydantic_self.pydantic_validator.validate_python(data, self_instance=pydantic_self__) pydantic_core._pydantic_core.ValidationError: 50 validation errors for ConversationSet array.28.mapping.b5afe8ed-de76-4dd5-a0cf-04e7ab3845a9.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.28.mapping.b5afe8ed-de76-4dd5-a0cf-04e7ab3845a9.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.28.mapping.87ef3fb6-ba31-4233-ba3d-e3eece62f9e5.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.28.mapping.87ef3fb6-ba31-4233-ba3d-e3eece62f9e5.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.28.mapping.aa5a68eb-ce8d-4e56-802d-38b43eba4a4f.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.28.mapping.aa5a68eb-ce8d-4e56-802d-38b43eba4a4f.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.28.mapping.75d9db25-b16f-4987-9aa2-f94dc515d4f8.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.28.mapping.75d9db25-b16f-4987-9aa2-f94dc515d4f8.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.28.mapping.a971f12b-6607-48dc-a624-242d80ca7122.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.28.mapping.a971f12b-6607-48dc-a624-242d80ca7122.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.28.mapping.ff5b1d57-9293-458c-8845-7dee437142a7.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.28.mapping.ff5b1d57-9293-458c-8845-7dee437142a7.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.29.mapping.aaa20e83-8756-4729-a9ba-9c45b0961f63.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... None, 'metadata': None}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.107.mapping.aaa2442a-8d2f-42b0-b932-c2db3887f7d8.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... None, 'metadata': None}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.288.mapping.46e1e809-8d4b-45cd-9617-c183a017f7e1.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.288.mapping.46e1e809-8d4b-45cd-9617-c183a017f7e1.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.288.mapping.44778564-808a-4900-a0fb-0b9be15e4d64.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.288.mapping.44778564-808a-4900-a0fb-0b9be15e4d64.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.340.mapping.3358dd23-e3c0-4a9e-a217-51ba0584d2eb.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.340.mapping.3358dd23-e3c0-4a9e-a217-51ba0584d2eb.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.341.mapping.88559ce0-f97f-44fa-a630-ca9fedf38edc.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.341.mapping.88559ce0-f97f-44fa-a630-ca9fedf38edc.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.342.mapping.7a23b8f1-f01c-4b33-ab50-baa58647c7a5.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.345.mapping.3d38b27b-794b-4a0b-9b3e-6e5c3106a510.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.345.mapping.3d38b27b-794b-4a0b-9b3e-6e5c3106a510.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.345.mapping.8364c1b8-7ade-4071-9a84-380d232f0e93.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.345.mapping.8364c1b8-7ade-4071-9a84-380d232f0e93.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.345.mapping.84d7d509-faa2-4ad8-82e5-10ffaa162f9b.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.345.mapping.84d7d509-faa2-4ad8-82e5-10ffaa162f9b.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.345.mapping.957392d5-a02d-4dae-8dab-fd8c0b960fd7.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.345.mapping.957392d5-a02d-4dae-8dab-fd8c0b960fd7.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.345.mapping.b7842137-42c9-4c11-a119-065c7a8e6851.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.345.mapping.b7842137-42c9-4c11-a119-065c7a8e6851.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.345.mapping.e2fe2f68-bb3e-4eae-b430-06f101d347be.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.bc9e0305-a1af-4399-a6db-38f56ec4519b.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.bc9e0305-a1af-4399-a6db-38f56ec4519b.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.bc9e0305-a1af-4399-a6db-38f56ec4519b.message.content.parts.2 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.bc9e0305-a1af-4399-a6db-38f56ec4519b.message.content.parts.3 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.ee61c5c2-5122-4d0d-bb1c-75e126865117.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.ee61c5c2-5122-4d0d-bb1c-75e126865117.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.ee61c5c2-5122-4d0d-bb1c-75e126865117.message.content.parts.2 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.ee61c5c2-5122-4d0d-bb1c-75e126865117.message.content.parts.3 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.82f4daf3-332e-4434-8fbe-356a6b53ff78.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.82f4daf3-332e-4434-8fbe-356a6b53ff78.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.82f4daf3-332e-4434-8fbe-356a6b53ff78.message.content.parts.2 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.82f4daf3-332e-4434-8fbe-356a6b53ff78.message.content.parts.3 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.5bc365ac-6368-491f-9ad2-3bdd43b40ae8.message.content.parts.0 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.5bc365ac-6368-491f-9ad2-3bdd43b40ae8.message.content.parts.1 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.5bc365ac-6368-491f-9ad2-3bdd43b40ae8.message.content.parts.2 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type array.492.mapping.5bc365ac-6368-491f-9ad2-3bdd43b40ae8.message.content.parts.3 Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... generation metadata'}}}, input_type=dict] For further information visit https://errors.pydantic.dev/2.5/v/string_type PS C:\Users\djtlm\Documents\GitHub\chatgpt-history-export-to-md\openai-export cd833544d1e9d430427877b3357ec5b40df5d0062769dde85ac4b09bc0e74a93-2023-11-12-21-19-05>

Kmfernan5 commented 12 months ago

https://chat.openai.com/share/f048580b-5433-4509-901b-952a0264cb35

https://share.zight.com/nOuQJ0EE

v4lue4dded commented 11 months ago

I seem to have the same issue:

? 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 📂 ...

Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "C:\Tools\miniconda3\Lib\site-packages\convoviz\__main__.py", line 5, in <module>
    main()
  File "C:\Tools\miniconda3\Lib\site-packages\convoviz\cli.py", line 38, in main
    entire_collection = ConversationSet.from_zip(user.configs["zip_filepath"])
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Tools\miniconda3\Lib\site-packages\convoviz\models\_conversation_set.py", line 55, in from_zip
    return cls.from_json(convos_path)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Tools\miniconda3\Lib\site-packages\convoviz\models\_conversation_set.py", line 47, in from_json
    return cls(array=loads(file.read()))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Tools\miniconda3\Lib\site-packages\pydantic\main.py", line 164, in __init__
    __pydantic_self__.__pydantic_validator__.validate_python(data, self_instance=__pydantic_self__)
pydantic_core._pydantic_core.ValidationError: 3 validation errors for ConversationSet
array.38.mapping.aaa27a09-3786-4b9e-b31c-f259a5492e3a.message.content.parts.0
  Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... None, 'metadata': None}, input_type=dict]
    For further information visit https://errors.pydantic.dev/2.5/v/string_type
array.38.mapping.aaa27a09-3786-4b9e-b31c-f259a5492e3a.message.content.parts.1
  Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... None, 'metadata': None}, input_type=dict]
    For further information visit https://errors.pydantic.dev/2.5/v/string_type
array.40.mapping.aaa24f7d-aa2f-4e27-a275-aaaf92491ee6.message.content.parts.0
  Input should be a valid string [type=string_type, input_value={'content_type': 'image_a... None, 'metadata': None}, input_type=dict]
    For further information visit https://errors.pydantic.dev/2.5/v/string_type
ethnzhng commented 11 months ago

It seems like it's some issue with the newer versions, downgrading fixed it for me: pip install --force-reinstall -v "convoviz<=0.1.2"

DevLimK1 commented 10 months ago

It seems like it's some issue with the newer versions, downgrading fixed it for me: pip install --force-reinstall -v "convoviz<=0.1.2"

I typed it in like you said and it worked, thanks!