2 months ago
**I am trying to make a discord bot but it crashes every time **
Attachments
82 Replies
2 months ago
it looks like your discord bot token is missing
2 months ago
how your code looks like?
2 months ago
^ you have to pass the bot token in the env variable
2 months ago
where'd you paste it?
here
Attachments
2 months ago
why'd you add it as a shared variable? is there a particular reason? or did you mean to add it to your bot service?
Attachments
2 months ago
I'll assume you did it mistakenly
You'll want to paste those in your service variables instead:
- Click on your CyberNet Bot service
- Click on the Variables
- Put your variables in there
thanks it worked
Attachments
2 months ago
huge!
2 months ago
glad I could help
2 months ago
sure, I'll keep it open and close it when I go to bed, if it crashes after I go to bed then you're welcome to open a new thread
2 months ago
around 10 hours from now probably
2 months ago
i mean it doesn't matter ultimately, even if someone closes it now you can always open another one
2 months ago
good luck
Attachments
2 months ago
that is definitely an issue within your code somewhere, you'll want to check your server logs
i updated the the codes from "gemini-2.0-flask" to "gemini-1.5-flask-latest" but the result is same
Attachments
2 months ago
did you check server logs?
2 months ago
any errors?
Attachments
only this
Attachments
2 months ago
yea it looks like your google generative-ai is erroring with 404 for something, meaning there's something it cant find
2 months ago
you'll want to fix whatever's causing that
i tried changing it from Gemini to Hugging face as Railway told me but still
Attachments
2 months ago
Railway told you to switch from gemini to huggingface?
2 months ago
wait actually im very confused
Attachments
2 months ago
earlier you showed a screenshot of python code, but in your errors I notice there's node_modules, and you're also using a bun function
2 months ago
what happened?
2 months ago
Didn't you have a gemini api key already though?
2 months ago
Don't worry that's not necessary
2 months ago
I know what happened
2 months ago
I just don't understand why
2 months ago
if you had working python code then why have railway's AI agent remake the same code in a different language for you?
2 months ago
why not just run the existing working code you had on replit on Railway?
i can't accse it
Attachments
2 months ago
that's the AI though, not the code
2 months ago
can you send a wider screenshot? like of your entire screen maybe?
Attachments
2 months ago
Try doing this:
- Click on the canvas or the cybernet dashboard dropdown
- Click on workspace/file view
then send another screenshot
2 months ago
(note this is steps I found online, I don't use replit, so idk if this is actually how you access code on replit, so I may be wrong)
sorry the doctor came to take my blood so i went offline here is the image when i click on canvas
Attachments
2 months ago
and what happens when you click on the dropdown
Attachments
Attachments
2 months ago
man, who knew it'd be this difficult finding the code
can i do this?
Attachments
2 months ago
alright well I'm clearly out of my depths here lol
my recommendation is finding the code replit has for your bot, upload it on github and use it on railway
2 months ago
I'm pretty sure limited outbound internet access only applies to limited trial plans (i could be wrong though)
2 months ago
I can't unfortunately, I'm at my server limit, I can't join more servers
I am loosing my temper
Attachments
2 months ago
💀 60%-70%
2 months ago
Let me ask you this, what's your goal? Are you trying to run a completely free AI chatbot?
i am trying to make a bot that will run my youtube server and can talk to members using ai
it worked before but it crashed on Replit
Attachments
2 months ago
Are you trying to source your AI for free?
2 months ago
Yea no wonder you're struggling
2 months ago
I'd recommend using openrouter then, they usually have a handful of free AI models
thanks for your but i don't want to make this su#$@ thing anymore
Attachments
2 months ago
💀 alright fair
2 months ago
it's a routing platform, they route your requests to AI models but take a cut of the cost in return
2 months ago
i got it
Status changed to Solved dev • 2 months ago