terry3041 / pyChatGPT

An unofficial Python wrapper for OpenAI's ChatGPT API
GNU General Public License v3.0
1.35k stars 255 forks source link

'NoneType' object has no attribute 'group' #151

Open Mrithul-E opened 1 year ago

Mrithul-E commented 1 year ago

'NoneType' object has no attribute 'group' File "C:\Users\Administrator\Desktop\python projects\python yt_video auto\image_scrape.py", line 13, in chatgpt resp = api.send_message(prompt) ^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\Administrator\Desktop\python projects\python yt_video auto\image_scrape.py", line 57, in print(chatgpt("hi")) ^^^^^^^^^^^^^ AttributeError: 'NoneType' object has no attribute 'group'

This can be fixed by removing the .group() in the 460th line of pychatgpt issue of this step is that we not get conversation id EG: {'message': 'Hello! How can I assist you today?\n\n', 'conversation_id': None}

Kolhax commented 1 year ago

@Mrithul-E i fixed it: pyChatGPT.zip

Kolhax commented 1 year ago

ill do a edit request to update it in the repo