Open XCraftTM opened 1 year ago
It appears that Bard is not responding correctly. Are you sure that config.aicookie
is defined in your new environment?
Yeah it is... i checked it multiple times and it does work on windows but not on the ubuntu server. The config is a JSON file that i imported using require...
I have already pretty much created a CRE... But everything i have tried doesn't work... it throws the same error as of the start of this issue. I tried reimporting the Module, Making a new Project, trying a new File, Trying a ES6 Project, importing it using the import() function... Even just putting the Cookie Secret as a string into the function... Do you guys have any idea how i might be able to fix this?
Weirdly enough i have now tried running this Project in a Ubuntu 20 VM on my PC and it works there.. So i think there might be something wrong with my Server i am running it on....
Hello, This error happens to me when I try to use the chat function without passing the ids form the export function first. Other than that it works.
Any updates? Closing otherwise.
I still haven't found a solution for the issue but i do want to use it without a id...
Try with bard-ai
v2. Just released.
There are quite a few breaking changes though 😅
Overall, the experience should be more streamlined and modern.
It did? Okay i will test that... i will report tomorrow if it works or not...
file:///Bot/node_modules/bard-ai/index.js:242
const answer = chatData[4][0];
^
TypeError: Cannot read properties of null (reading '4')
at #query (file:///Bot/node_modules/bard-ai/index.js:242:32)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Chat.ask (file:///Bot/node_modules/bard-ai/index.js:344:32)
at async /Bot/test.js:7:17
Node.js v18.17.0
Getting this error now... but works on my PC again... No idea why it happens...
Using:
import("bard-ai").then(async ({ default: Bard }) => {
let bard = new Bard({
"__Secure-1PSID": "COOKIE SECRET",
"__Secure-1PSIDTS": "COOKIE SECRET",
});
let conv = bard.createChat();
console.log(await conv.ask("test"));
});
Can you give a minimal recreation of your problem?
Like complete code to recreate the problem you are having.
The Code i sent is everything i tested it with...
Prerequisites
bard-ai
Bug Description
So i coded a Discord Bot in Discord.JS in CJS and imported it correctly and everything works when using it in Windows, but when i upload it to a Linux Server(Running Ubuntu 20) it crashes when using
Bard.Chat().ask()
trying to ask something...Reproduction Steps
Using:
After i start the Bot it Gives this Error:
Other information
No response
Occurance Rate
I can reproduce this bug 100% of the time.