mishl-dev / Discord-AI-Chatbot

This Discord chatbot is incredibly versatile. Powered incredibly fast Groq API
GNU Affero General Public License v3.0
1.32k stars 417 forks source link

Error: FileNotFoundError when running bot on NAS without Docker #125

Closed Virusf closed 1 year ago

Virusf commented 1 year ago

Hello,

I'm trying to run the bot on my NAS, but I can't install Docker on my Nas. However, I do have Python installed and I encountered the following problem:

Traceback (most recent call last):
  File "/main.py", line 24, in <module>
    with open('config.json') as config_file:
FileNotFoundError: [Errno 2] No such file or directory: 'config.json'

In my search for a solution, I came across the following code snippet:

BASE_PATH = os.path.dirname(os.path.realpath(__file__))
with open(BASE_PATH+'/config.json') as config_file:
    config = json.load(config_file)

Here is a little code improvement. Thank you for your attention.

ps: I apologize because I do not speak English and the message little was not clear.

mishl-dev commented 1 year ago

@Virusf I would like to inform you that I have made some important changes to the configuration file. We have transitioned from using JSON to YAML format. This update brings a more streamlined and efficient structure to our configuration.

Virusf commented 1 year ago

OK thank you for the information and great work on this project

mishl-dev commented 1 year ago

OK thank you for the information and great work on this project

Stay up-to-date by joining our Discord community at https://discord.gg/aJvH48QZ.