ausboss / PygDiscordBot

Discord bot that uses KoboldAI. Supports tavern cards and json files.
63 stars 29 forks source link

Setup.bat causes this error - Help? #16

Closed Webslug closed 1 year ago

Webslug commented 1 year ago

user site = 1 safe_path = 0 import site = 1 is in build tree = 0 stdlib dir = 'C:\Program Files\Python310\Scripts\Lib' sys._base_executable = 'C:\Python311\python.exe' sys.base_prefix = 'C:\Program Files\Python310\Scripts' sys.base_exec_prefix = 'C:\Program Files\Python310\Scripts' sys.platlibdir = 'DLLs' sys.executable = 'C:\Python311\python.exe' sys.prefix = 'C:\Program Files\Python310\Scripts' sys.exec_prefix = 'C:\Program Files\Python310\Scripts' sys.path = [ 'C:\Python311\python311.zip', 'C:\Program Files\Python310\Scripts\DLLs', 'C:\Program Files\Python310\Scripts\Lib', 'C:\Python311', ] Fatal Python error: init_fs_encoding: failed to get the Python codec of the filesystem encoding Python runtime state: core initialized ModuleNotFoundError: No module named 'encodings'

Current thread 0x00004574 (most recent call first):

Press any key to continue . . .
Webslug commented 1 year ago

I solved the problem by adding the following lines to the setup.bat file. Hope this helps someone else.

SET PYTHONNOUSERSITE=1
SET PYTHONPATH=
SET PYTHONHOME=
ausboss commented 1 year ago

thanks for sharing your fix. I apologize i'm not as diligent about checking the issues on this repo. I want to eventually give this project some more love. I am learning some more advanced language model techniques that I will eventually bring back to this project to make it better.

unsureboolean commented 1 year ago

@Webslug did you include the paths or leave it like that?

ausboss commented 1 year ago

@unsureboolean if you tried the bot yesterday it was probably broke because of yesterdays push. I just pushed another one that fixed issues.