Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Website not working #29

Open
pixo2000 opened this issue Aug 31, 2024 · 7 comments
Open

Website not working #29

pixo2000 opened this issue Aug 31, 2024 · 7 comments
Assignees
Labels
bug Something isn't working

Comments

@pixo2000
Copy link

i tried to set the api key on the website but it wouldnt accept the key.
also: the installation on my server is not working and yeah idk what i am supposed to do cuz i cannot add a bot in the panel

@SilkePilon
Copy link
Owner

Hello @pixo2000 what os are you running?

@SilkePilon
Copy link
Owner

Atm (sadly) the website connects to a localhost for the backend so the website can only be opened on the same pc the backend is running on. I will probably change this in a future update

@SilkePilon
Copy link
Owner

For setting an api key:
If you press the button on the top right for setting an api key (make shure no bot is currently active or connected) in the dialog that appears there are steps to obtain an Nvidia api key

@SilkePilon SilkePilon added the bug Something isn't working label Sep 1, 2024
@SilkePilon SilkePilon self-assigned this Sep 1, 2024
@pixo2000
Copy link
Author

pixo2000 commented Sep 1, 2024

ok... i am running the server on linux.
this is my server error:

/var/lib/pufferpanel/servers/fa024184/main.js:887
res.json({ response: completion.choices[0]?.message?.content || "" });
^

SyntaxError: Unexpected token .
at Module._compile (internal/modules/cjs/loader.js:723:23)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:831:12)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:623:3)

after i fix this, can i open the website on my server and then run the bots on my server or is it the same problem with your website? 

@SilkePilon
Copy link
Owner

Linux is fine, the website and backend need to be ran on the same pc, the website connects to the backend using localhost:3000, the error seems to be a thing with the ai make sure you follow the setup instructions in the dialog for the api key the key should start with nvapi-*********

@pixo2000
Copy link
Author

pixo2000 commented Sep 1, 2024

yeah i wanted to run it on my server, but when i tried installing it on my local pc, i got this error:

C:\Users\Paul\Documents\mineflayer>node main.js
node:internal/modules/cjs/loader:1080
throw err;
^

Error: Cannot find module '../build/Release/canvas.node'
Require stack:

  • C:\Users\Paul\Documents\mineflayer\node_modules\canvas\lib\bindings.js
  • C:\Users\Paul\Documents\mineflayer\node_modules\canvas\lib\canvas.js
  • C:\Users\Paul\Documents\mineflayer\node_modules\canvas\index.js
  • C:\Users\Paul\Documents\mineflayer\main.js
    at Module._resolveFilename (node:internal/modules/cjs/loader:1077:15)
    at Module._load (node:internal/modules/cjs/loader:922:27)
    at Module.require (node:internal/modules/cjs/loader:1143:19)
    at require (node:internal/modules/cjs/helpers:119:18)
    at Object. (C:\Users\Paul\Documents\mineflayer\node_modules\canvas\lib\bindings.js:3:18)
    at Module._compile (node:internal/modules/cjs/loader:1256:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1310:10)
    at Module.load (node:internal/modules/cjs/loader:1119:32)
    at Module._load (node:internal/modules/cjs/loader:960:12)
    at Module.require (node:internal/modules/cjs/loader:1143:19) {
    code: 'MODULE_NOT_FOUND',
    requireStack: [
    'C:\Users\Paul\Documents\mineflayer\node_modules\canvas\lib\bindings.js',
    'C:\Users\Paul\Documents\mineflayer\node_modules\canvas\lib\canvas.js',
    'C:\Users\Paul\Documents\mineflayer\node_modules\canvas\index.js',
    'C:\Users\Paul\Documents\mineflayer\main.js'
    ]
    }

Node.js v18.18.2

@SilkePilon
Copy link
Owner

try npm install -g canvas

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants