gd3kr / BlenderGPT

Use commands in English to control Blender with OpenAI's GPT-4
MIT License
4.36k stars 312 forks source link

Key error api key #24

Open BrechtCorbeel opened 1 year ago

BrechtCorbeel commented 1 year ago

Blender 3.4

Python: Traceback (most recent call last):
  File "C:\Users\brech\AppData\Roaming\Blender Foundation\Blender\3.4\scripts\addons\BlenderGPT-main\__init__.py", line 227, in execute
    openai.api_key = get_api_key(context)
  File "C:\Users\brech\AppData\Roaming\Blender Foundation\Blender\3.4\scripts\addons\BlenderGPT-main\__init__.py", line 58, in get_api_key
    addon_prefs = preferences.addons[__name__].preferences
KeyError: 'bpy_prop_collection[key]: key "BlenderGPT-main" not found'

after which typing key in box provides:

No API key detected. Please set the API key in the addon preferences.

also doesn't save key

wpegley commented 1 year ago

Similar error Chat GpT said :Thank you for providing the screenshot. From the error message, it appears that you are encountering an error related to the installation of the transformers library, specifically the tokenizers module.

To resolve this issue, you can try the following steps:

Ensure that you have the latest version of pip installed. You can upgrade pip by running the following command:

css Copy code pip install --upgrade pip Install the tokenizers library separately before installing the transformers library. Run the following command:

Copy code pip install tokenizers After successfully installing tokenizers, try installing the transformers library again:

Copy code pip install transformers If the issue persists, please provide more information about your system environment, such as the version of Python you're using, any specific package versions you have installed, and any other relevant details. This additional information will help in troubleshooting the problem further.****