#development

1 messages · Page 1635 of 1

river panther
#

oh nice

#

i also poor

earnest phoenix
#

same

strange pike
earnest phoenix
#

I'm using Glitch

strange pike
#

Oh

earnest phoenix
#

Because my credit card is gay

strange pike
#

I sell credit cards.

earnest phoenix
strange pike
earnest phoenix
strange pike
#

I have 2000 nitro codes

earnest phoenix
#

checked?

umbral zealot
strange pike
#

With 200 are 1 year discord nitro zzz_Akshay

#

Yes @earnest phoenix

earnest phoenix
strange pike
#

7 times checked

earnest phoenix
strange pike
#

Do i look like an idiot

earnest phoenix
#

yes

#

a little

strange pike
#

Type f to pay me respect

earnest phoenix
#

G

strange pike
earnest phoenix
lucid prawn
#

how do i make my bot server mute

waxen fog
#

@pliant gorge

#

@gilded plank

earnest phoenix
lusty quest
sharp thicket
#

Hi!
So I'm having this weird error with fs look..
code:

const fs = require("fs")
exports.twitch = async(bot) => {
const files = await fs.readdirSync("../commands/twitch/").filter(f => f.endsWith(".js") || f.endsWith(".ts"))
for(const file of files){
    const command = require(`../commands/twitch/${file}`)
    bot.tcommands.set(commands.name, command)
    if(command.aliases) command.aliases.forEach(alias => {
        bot.tcommands.set(alias, command)
    });

}
}
exports.discord = async(bot) => {
    const files = await fs.readdirSync("../commands/discord/").filter(f => f.endsWith(".js") || f.endsWith(".ts"))
    for(const file of files){
        const command = require(`../commands/discord/${file}`)
        bot.dcommands.set(commands.name, command)
        if(command.aliases) command.aliases.forEach(alias => {
            bot.dcommands.set(alias, command)
        });
    
    }
    }

Errors:

(node:10636) UnhandledPromiseRejectionWarning: Error: ENOENT: no such file or directory, scandir '../commands/twitch/'
(node:10636) UnhandledPromiseRejectionWarning: Error: ENOENT: no such file or directory, scandir '../commands/discord/'```
file tree:
old latch
#

in which file is this code written in?

sharp thicket
#

commands.js

sudden geyser
#

fs uses your project root directory

sharp thicket
#

so i should just remove the dots?

sudden geyser
#

remove the ../

sharp thicket
#

k

#

Ty that worked

#

fs confuses me

lucid prawn
ancient nova
#

does anyone know how to write a script that will auto type the text in c#?

earnest phoenix
#

how can i catch this error

#

if there is this error something else will return

lament rock
#

putting the UserManager.fetch method inside a try catch block

earnest phoenix
#

yes true

plain seal
earnest phoenix
#
await m.message.guild.members.fetch(deger.replace(/[<@!>]/g, ""), { cache: false, withPresences: true }).catch(() => {})
#

async (message) =>

plain seal
#

ok i'm just dumb

lethal trout
#
const client = require('../index')
const Discord = require('discord.js')
const logs = require('../models/logs')

client.on("messageUpdate", async (oldMessage, newMessage) => {
   //const channel = oldMessage.guild.channels.cache 
const channel = oldMessage.channels
    if (oldMessage.content === newMessage.content) return;
    //const oldchannel = oldMessage.channel.id;
    const data = await logs.findOne({
        guildID: newMessage.guild.id,
        channelID: channel.id,
        MessageUpdate: true
    });
    //const channell = await logs.findOne({
      //  channelID: newMessage.channel.id
   // });
    //const channel = client.channels.cache.get(scheme);
    if (data) {
const targetchannel = newMessage.guild.channels.cache.get(`${data.channelID}`)


        const embed = new Discord.MessageEmbed()
            .setAuthor('A message has been edited!')
            .setThumbnail(oldMessage.author.displayAvatarURL({ dynamic: true }))
            .setColor('#FF0000')
            .addField("Edited by:", oldMessage.author.tag)
            .addField("Edited in:", oldMessage.channel)
            .addField("Edited at:", oldMessage.createdAt)
            .addField("Before:", oldMessage.content)
            .addField("After:", newMessage.content)
            .addField("URL:", `[Click Me](${oldMessage.url})`)
            .setTitle('Message Edited!')
            .setTimestamp()
        targetchannel.send(embed)
    } else {
        return
    }

})```
https://media.discordapp.net/attachments/766116919983079434/818131355048083476/unknown.png
plain seal
lethal trout
crimson vapor
#

Well channels isn’t a property on a message lol

lusty quest
#

did you get the channel as partial?

crimson vapor
#

This code should be in a message event lol

#

@plain seal

unreal estuary
#

lol

plain seal
#

aight then

#

thanku

lethal trout
crimson vapor
#

client.on(“message”, (message) => {
// code here

})

lethal trout
unreal estuary
#

show ur code

#

@lethal trout

crimson vapor
#

Those quotes are apples quotes so no work in code

crimson vapor
unreal estuary
#

ah ill scroll up

crimson vapor
#

Scroll up and replace channels with channel

lethal trout
# unreal estuary show ur code
const client = require('../index')
const Discord = require('discord.js')
const logs = require('../models/logs')

client.on("messageUpdate", async (oldMessage, newMessage) => {
   //const channel = oldMessage.guild.channels.cache 
const channel = oldMessage.guild.channel
    if (oldMessage.content === newMessage.content) return;
    //const oldchannel = oldMessage.channel.id;
    const data = await logs.findOne({
        guildID: newMessage.guild.id,
        channelID: channel.id,
        MessageUpdate: true
    });
    //const channell = await logs.findOne({
      //  channelID: newMessage.channel.id
   // });
    //const channel = client.channels.cache.get(scheme);
console.log(data.channelID)
    if (data) {
const targetchannel = newMessage.guild.channels.cache.get(`${data.channelID}`)


        const embed = new Discord.MessageEmbed()
            .setAuthor('A message has been edited!')
            .setThumbnail(oldMessage.author.displayAvatarURL({ dynamic: true }))
            .setColor('#FF0000')
            .addField("Edited by:", oldMessage.author.tag)
            .addField("Edited in:", oldMessage.channel)
            .addField("Edited at:", oldMessage.createdAt)
            .addField("Before:", oldMessage.content)
            .addField("After:", newMessage.content)
            .addField("URL:", `[Click Me](${oldMessage.url})`)
            .setTitle('Message Edited!')
            .setTimestamp()
        targetchannel.send(embed)
    } else {
        return
    }

})```
unreal estuary
#

just replace it with

#

const channel = oldMessage.channel

lethal trout
#

k

unreal estuary
#

instead of const channel = oldMessage.guild.channel

lusty quest
#

guild.channel is not valid, its a manager if you use channels

lethal trout
#

btw it has data

lusty quest
#

targetchannel is not defined

lethal trout
#

it is

lusty quest
#

bcs newmassge.guild.channel is not a thing

lethal trout
#

?

lusty quest
#

guild only got the channels property and this is a manager

plucky geyser
#

THIS is going above from my brain

#

🗜️

lusty quest
#

this is basic d.js

lethal trout
#
const client = require('../index')
const Discord = require('discord.js')
const logs = require('../models/logs')

client.on("messageUpdate", async (oldMessage, newMessage) => {
const channel = oldMessage.channel
    if (oldMessage.content === newMessage.content) return;
    const data = await logs.findOne({
        guildID: newMessage.guild.id,
        channelID: channel.id,
        MessageUpdate: true
    });
console.log(data.channelID)
    if (data) {
const targetchannel = newMessage.guild.channels.cache.get(`${data.channelID}`)
        const embed = new Discord.MessageEmbed()
            .setAuthor('A message has been edited!')
            .setThumbnail(oldMessage.author.displayAvatarURL({ dynamic: true }))
            .setColor('#FF0000')
            .addField("Edited by:", oldMessage.author.tag)
            .addField("Edited in:", oldMessage.channel)
            .addField("Edited at:", oldMessage.createdAt)
            .addField("Before:", oldMessage.content)
            .addField("After:", newMessage.content)
            .addField("URL:", `[Click Me](${oldMessage.url})`)
            .setTitle('Message Edited!')
            .setTimestamp()
        targetchannel.send(embed)
    } else {
        return
    }
})```
#

here edit my code and give pls

lusty quest
#

we are not allowed to spoonfeed

lime panther
#

x)

lethal trout
feral aspen
lethal trout
lethal trout
feral aspen
plucky geyser
#

😋

feral aspen
#

Does this work for normal if statements as well?
https://discord.js.org/#/docs/main/stable/class/GuildMember?scrollTo=hasPermission

Example pseudo

if(check /* but if user is admin or owner, return false*/)
lusty quest
#

also you dont need to pass the channelid as a string in your case

#

this could be the issue

#

const targetchannel = newMessage.guild.channels.cache.get(data.channelID)

#

try this

#

also make sure the channel is cached, otherwise you have to fetch the channel

lusty quest
lusty quest
#

the check returns a boolean

feral aspen
#
if(/*if the user doesn't have a specific role, it would return as true, otherwise, if the user is an admin, it would return false*/)
feral aspen
#

Yes, but I want the second part of the pseudo.

lusty quest
#

look at my snipped

#

this returns a boolean

feral aspen
#

Let's consider the first part of the code as this

#
if(userhasnorole)
lusty quest
#

message.member.permissions.has("ADMINISTRATOR") ? false : true something like this could work there is probably a more elegant way for this but it will return false if the message author got Admin permissions and true if the author doesnt have Admin permission

feral aspen
#

Ah,

#

I did do this tho in pseudo

#
if(!userHasNoRole) {
return "oh damn, has no role"
} else /* if the user is an admin or an owner*/ then it would continue and bypass the check.
#

Didn't figure out the second part.

lusty quest
#

then you dont need the last snipped ive send

#

just use the Aministrator check

#

i dont think you need to check for Owner since the Guild owner usually got instantly Full permissions

#

if you mean Bot owner you can just add a check for this

feral aspen
feral aspen
lusty quest
#

if (message.member.permissions.has("ADMINISTRATOR")) -> returns true if the author got Admin permissions

feral aspen
#

That is the else statement.

lusty quest
#

and false if not

feral aspen
#

Wait.

#

One second.

lusty quest
#

also you could make your code maybe a bit nicer

feral aspen
lusty quest
#

what did you want to check? if a user got certain role or is Admin it runs the code?

feral aspen
#
if(!message.member.roles.cache.has(server.moderatorRole)) {
    embedError.setDescription(noModerator);
    return await message.channel.send(embedError);
};
#

If the user is an admin, then it would bypass the above if statement.

#

I'm trying to do that.

lament rock
#

you can use a logical and to check if the user doesn't have admin permissions in that if statement

feral aspen
lament rock
#

No

#

if (not mod && not admin) error
else doStuff

feral aspen
#

Wait, can I do it like this?

lusty quest
#

wrap all the stuff inside a other if statement

feral aspen
#

Yes.

lusty quest
#

but this method above is more efficent

feral aspen
#
if(the user is not an admin) {
if(!message.member.roles.cache.has(server.moderatorRole)) {
    embedError.setDescription(noModerator);
    return await message.channel.send(embedError);
};
}
hollow saddle
#

why do you have return await MarioFP

lament rock
#

That's literally the easiest way I can think of you could do that???

I'm giving you an answer to your question.

if (not a mod and not an admin) error

condition: they are a mod

if (false && not an admin) error
short stopped and fall to the else

condition: they are an admin
if (true && false) error

// not true. && checks for truthiness of multiple values. true && false returns false

condition: they are neither
if (true && true) error

self explanatory

condition: they are both
if (false && false) error

Short stopped by first false and falls to the else

#

your else should have code to run if they do have permissions

lethal trout
#
const client = require('../index')
const Discord = require('discord.js')
const logs = require('../models/logs')

client.on("messageUpdate", async (oldMessage, newMessage) => {
const channel = oldMessage.channel
    if (oldMessage.content === newMessage.content) return;
    const data = await logs.findOne({
        guildID: newMessage.guild.id,
        channelID: channel.id,
        MessageUpdate: true
    });
console.log(data.channelID)
    if (data) {
const targetchannel = newMessage.guild.channels.cache.get(data.channelID)
        const embed = new Discord.MessageEmbed()
            .setAuthor('A message has been edited!')
            .setThumbnail(oldMessage.author.displayAvatarURL({ dynamic: true }))
            .setColor('#FF0000')
            .addField("Edited by:", oldMessage.author.tag)
            .addField("Edited in:", oldMessage.channel)
            .addField("Edited at:", oldMessage.createdAt)
            .addField("Before:", oldMessage.content)
            .addField("After:", newMessage.content)
            .addField("URL:", `[Click Me](${oldMessage.url})`)
            .setTitle('Message Edited!')
            .setTimestamp()
        targetchannel.send(embed)
    } else {
        return
    }
})```
vivid fulcrum
#

because the return type of execute will be Promise<Message> and not Promise<Promise<Message>>

lusty quest
feral aspen
vivid fulcrum
#

hm?

feral aspen
#

Do you mean the module.exports.run?

vivid fulcrum
#

oh yeah

#

same thing

#

whatever the method is that runs your command

feral aspen
#

Yes.

#

I did this as an example.

#
const { MessageEmbed } = require("discord.js");
const { cyan } = require("../../other/colors.json");

module.exports = {
    config: {... config stuff ...),
    run: async (bot, message, args) => {

        if(!message.guild.me.hasPermission(["SEND_MESSAGES", "EMBED_LINKS"])) return;
        
        const dice = Math.floor(Math.random() * 5) + 1;

        const embed = new MessageEmbed()
        .setDescription(`Your dice landed on ${dice}!`)
        .setColor(cyan)

        return await message.channel.send(embed);
    },
};
#

Is that correct?

vivid fulcrum
#

also

#

here's a pro tip

lusty quest
lament rock
#

return await has no effect on that expression there

lethal trout
lusty quest
#

then fetch the channel

#

bcs the channel is not cached

lethal trout
lusty quest
#

?

#

the first id is from your mongodb

lethal trout
#

like how can i fetch it?

feral aspen
lusty quest
#

i asked you to console.log the channel

lethal trout
lusty quest
#

const targetchannel = newMessage.guild.channels.fetch(data.channelID)

#

also why did you get the channelid from MongoDB? you get it already from the event

vivid fulcrum
#

instead of stacking arguments in your run method, create a context object and pass that in, so your code would look like this

//in your command handler
command.run({
  bot: yourbot,
  message: msg,
  args: args
  //... add as many properties as you'd like
});

//in your command file
run: async (context) => {
  //context.bot ...
}
lethal trout
lusty quest
vivid fulcrum
lethal trout
lusty quest
feral aspen
#

But yo, cry. Is return await message.... something bad or?

vivid fulcrum
#

i just tested it out

#

it's redundant

#

it isn't bad, it's just redundant

#

js really does not make sense at all

pale vessel
#

how

feral aspen
#

...

pale vessel
#

you'll still have to await it when executing the function

vivid fulcrum
#

i guess it's the promises being stacked

pale vessel
#

so it's redundant

vivid fulcrum
#

yeah, you'd expect run (without return await) to return a Promise<Promise<Message>> because it's an underlying one

feral aspen
#

Do I keep it as return await? or what should I do?

vivid fulcrum
#

your choice really

feral aspen
#

What is better?

vivid fulcrum
#

they both do the same thing

#

without await is less typing

feral aspen
#

Any other important difference?

pale vessel
#

no

feral aspen
#

So writing await or without it literally does the same thing except it would await for the things before it to execute before doing this, right?

vivid fulcrum
#

that's not doing the same thing - they both do the same thing because js allows promise chaining

pale vessel
#

but you're not catching it

feral aspen
#

Oh, so the difference is what, in conclusion?

#

If I type await, will it decrease the promise chaining?

vivid fulcrum
#

there is no difference

#

virtually they're the same

earnest phoenix
#

Hey how to make bot is typing...?

#

Hi

vivid fulcrum
#

returning an awaited promise means you manually resolve it
returning an unawaited promise means the top level await will resolve it

returning an unawaited promise is basically doing this

await run().then(x => djs internal code here);

where then is the send method

#

so there's no difference

#

both do the same thing, except one is with async/await and the other is promise pattern

pale vessel
#
// your command file
{
    async run() {
        return message.channel.send("text");
    }
}

// your handler
try {
    await command.run();
}

catch (error) {
    // handle
}```does the same thing, whether you put `await` before return or not. if it returns a promise, it'll catch the error. if not (`return await`), it'll still catch it since you're `await`ing the function. the only important part is the `await` in your handler (`await command.run()`)
plucky geyser
#

👀

#

This shows that how new am I in coding

solemn latch
#

Everyone starts somewhere

feral aspen
#

oh.

#
// Before.
if(commandfile) commandfile.run(bot, message, args);

// After
if(commandfile) await commandfile.run(bot, message, args);
#

?

pale vessel
#

yes, and use try/catch or promise.catch()

lusty quest
feral aspen
pale vessel
#

you forgot the important part

#

await

#

yeah

feral aspen
#

Question.

feral aspen
earnest phoenix
#
const deger = "Veld#0001";
await m.message.guild.members.fetch({ cache: false, query: deger, limit: 1 })

no results are returned. how can i search by the user's tag.

feral aspen
#

Or Do I keep them?

pale vessel
#

you can remove them to make your code less redundant

#

it doesn't matter

#

but you still have to await your promises inside your commands so that your handler can catch errors

#

this is only redundant when returning

feral aspen
#

Example

pale vessel
#

just any promise

feral aspen
#
await perform();
pale vessel
#

yes

#

sure I guess

feral aspen
#

Like that? If it didn't work, what does it do? Does it error?

pale vessel
#

if it returns a promise, await it

#

your handler will catch it and you can handle the error

#

otherwise it might stop the node process (not sure what node version you're running)

earnest phoenix
#
if(message.content === "lol hi") {
message.channel.startTyping()
message.channel.send("Hi")
message.channel.stopTyping()
}```

Is this correct?
feral aspen
#

v12

pale vessel
cinder patio
#

that's a pretty old node.js version

pale vessel
#

await the send method so that it stops typing after it sends the message

earnest phoenix
#

Ohok

feral aspen
earnest phoenix
#

I have a problem

#
const Discord = require("discord.js")
const db = require("quick.db")

module.exports = async (client, message) => {
  
if (!message.guild || message.channel.type === "dm") return;
if (message.author === client.user) return;
db.set(`snipe.${message.guild.id}.content`, message.content);
db.set(`snipe.${message.guild.id}.channel`, message.channel.id);
db.set(`snipe.${message.guild.id}.user`, message.author);
setTimeout(function() {
  db.delete(`snipe.${message.guild.id}`);
  }, 600000);
    let data = db.get(`snipe.${message.guild.id}`);
    let content = data.content;
    let user = data.user;
    let channel = data.channel;
    const logsmessagedelete = message.guild.channels.cache.find(channel => channel.name === 'suggestion')
    const entry = await message.guild.fetchAuditLogs({limit: 1, type: 'MESSAGE_DELETE'}).then(audit => audit.entries.first())

if (user.id === message.author.id){
    const userembed = new Discord.MessageEmbed()
    .setColor("RANDOM")
    .setTimestamp()
    .setTitle("Un message supprimé a été retrouvé !")
    .setDescription(`J'ai retrouvé un message de <@${user.id}> dans le channel <#${channel}> !\n\n${content}\n\nSupprimé par : <@${user.id}>`);
    logsmessagedelete.send(userembed)

}else{

    const anotheruserembed = new Discord.MessageEmbed()
    .setColor("RANDOM")
    .setTimestamp()
    .setTitle("Un message supprimé a été retrouvé !")
    .setDescription(`J'ai retrouvé un message de <@${user.id}> dans le channel <#${channel}> !\n\n${content}\n\nSupprimé par : <@${entry.executor.id}>`);
      logsmessagedelete.send(anotheruserembed)

  }
}
#

oh

#

My messagedelete.js have a problem with embeds

#

the problem is:

#

When I delete my own message, the bot says another user deleted my message

pale vessel
earnest phoenix
#

or other, when someone delete my message, the bot says I deleted my own message

#

pls help

#

where is the event?

#

code

#

messageDelete

#

at events

#

the bot sends embed

earnest phoenix
#

but when he needs to declare who deleted the message, its wrong

#

yes

lethal trout
#

here

#

sry for late reply

lusty quest
#

you could try to resolve the channel tho with your way

lethal trout
feral aspen
lusty quest
lethal trout
pale vessel
#

If you use any methods that return a promise, make sure to await them too

feral aspen
lethal trout
lusty quest
#

or use .then()

lethal trout
#

brb

lusty quest
old cliff
#

Wait...

lusty quest
#

yes?

old cliff
#

I faced some issues when I did this in node 12 and didn't put in then

pale vessel
lusty quest
cinder patio
#

it doesn't cause fetch returns a promise

old cliff
#

yes

lusty quest
#

ohh wait

#

yea

#

but .then() should work

old cliff
lusty quest
#

does it error?

old cliff
#

Blah blah is not a function

#

in then it worked

lusty quest
#

const { data } = await fetch('https://google.com').then(response => response.json());this works for me

old cliff
#

Yes that will work

sacred aurora
old cliff
#

Let me eval that

vivid fulcrum
#

that isn't equivalent to what superbrain sent

sacred aurora
#

Oh

earnest phoenix
old cliff
#

I know

old cliff
feral aspen
#

Btw, if I dragged if(!message.guild.me.hasPermission(["SEND_MESSAGES", "EMBED_LINKS"])) return; to my message.js, does it check for all of my commands?

old cliff
sacred aurora
#

hm

lusty quest
#

hasPermission is still deprecated

fleet plinth
#

On which program can i programing a bot ?

vivid fulcrum
#

anything that is capable of writing to a file

fleet plinth
#

Ok

#

Do you have a suggestion?

unreal estuary
fleet plinth
#

Ok thx

unreal estuary
#

np

solemn latch
#

notepad best

lusty quest
earnest phoenix
#

why is this happening

    const x = fs.readFileSync(__dirname+"/../meta.json", "utf-8");
    x.prefix = args;
    fs.writeFileSync(__dirname+"/../meta.json", JSON.stringify(x, null, 4));
old cliff
#

it won't work cause the promise won't be resolved

vivid fulcrum
#

stop using json as your database

lusty quest
#

i know

vivid fulcrum
#

read this

lusty quest
#

people think they "save" time by using json as a database, but they are just lazy

solemn latch
#

honestly, json databases seem like more work

unreal estuary
#

is quick.db a good option too for beginners?

lusty quest
#

idk ive suggested someone else here to switch to a proper db asap and he said: nah im fine i will do it when im ready for it

vivid fulcrum
#

setting it up takes less time than a proper database
but making json databases actually work properly is going to take more time than just setting up a proper database and forgetting about it

fleet plinth
#

I have Intel j idea is that good ?

feral aspen
earnest phoenix
#

_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ perhaps

old cliff
#

The best option for beginners and intermediates is Josh

modest maple
lusty quest
#

enmap is nice, but can be quite heavy to run

earnest phoenix
#

ok but that doesnt answer the question

#

is formatting bad?

old cliff
vivid fulcrum
#

your answer was to not use a json database

modest maple
unreal estuary
#

is quick.db also good for databases

#

or nah

lusty quest
#

quick.db is a database

vivid fulcrum
#

"doctor!! my leg is broken!! why???"
"you should stop jumping off high structures"
"WELL THAT DOESN'T ANSWER MY QUESTION WHY IS MY LEG BROKEN!!"

lusty quest
#

good if you start out, but if you want to grow large dont use it i would say, sqlite can work if you know what you do

solemn latch
#

its not my first or second choice using quick.db, but it works.

lusty quest
#

it is easy to use and works

earnest phoenix
#

@vivid fulcrum are you mentally challenged

umbral zealot
vivid fulcrum
#

no, are you?

umbral zealot
#

Though, obviously, my opinion on that matter is highly biased.

lusty quest
#

but if you want to get most out of sqlite you are better of using native sqlite

#

gives you way more controll

old cliff
lusty quest
#

Brain is also green

#

i guess they took some vacations

modest maple
#

the SQLite syntax generally is very easy aswell as it has a more minified versions of the SQL spec by default (extensions go brrr)

solemn latch
umbral zealot
modest maple
solemn latch
#

isnt that what he wants?

old cliff
#

No

modest maple
#

the output you have at the bottom is what it generally should look like

solemn latch
#

thats what he will get if he uses it

modest maple
#

the file is actually
\"\\r\\n\" etc...

solemn latch
#

the bottom is what was returned using it

earnest phoenix
#

na problem was

#

it was a string

modest maple
old cliff
solemn latch
#

^ yeah probably best option

modest maple
#

or he should just use an actual db mmLol

novel snow
#

Aight so I lost my thought process, How would I be able to get a bot to find a specific guild using a ID to then in that guild find the id of a channel in the guild?

solemn latch
#

dont forget to backup your db periodically since json isnt stable

#

preferably automatically every few minutes

modest maple
#

thats massive overkill lol

modest maple
#

JSON files are bad but they're not that bad lol

umbral zealot
novel snow
# old cliff client.guilds.cache.get(id)

Well, Not like that since I do not want to specify the id of the channel, but I do want to specify the guilds ID, Then while having specified the guilds id, Find a channel in that guild.

old cliff
#

if channel then go for
client.channels.cache.get(id)

#

This will also have guild

#

channel#guild

modest maple
#

their issue is the fact that they're slow and eat memory, not so much the corruption issues, as long as you read and write the file sanely or if your framework is nice then your corruption chance isnt massive

solemn latch
#

we get reports of json db corruption in this channel quite a lot

umbral zealot
solemn latch
#

few times a month atleast.
with prefix's imo thats data you dont want to ever lose.

novel snow
#

Something like;
client.guilds.cache.get('ID').channels.find(Find string here).send("message)

modest maple
#

I mean i never said that people weren't idiots

#

or the fact that JS just goes "yeah... you deal with it"

novel snow
earnest phoenix
#

damn only problem was i didnt .parse it when reading xd

novel snow
#

Would that work?

#

Lemme try brb

old cliff
umbral zealot
#

It't not about stupidity here - it's about inexperience (and some amount of arrogance/dunning-kruger, beginners thinking they actually know better)

modest maple
novel snow
#

oh and how could I specify what type of channel it should find?

old cliff
#

Yes it can't be opened

lusty quest
#

just buy a better VPS

modest maple
#

technically it can be opened but it cant be parsed by most parsers

old cliff
#

Just use an actual db

lament rock
#

read streams are cool

lusty quest
#

nah get a dual Socket Epyc CPU equiped Server with 4TB ram to open your Json DB

modest maple
#

there are some JSON parsers that allow for partial data extraction but they assume that the context outside of the data given to them does not matter

solemn latch
#

4tb of ram is key

umbral zealot
#

I love the smell of "But if I can use JSON after 10 years of programming experience, everyone should be able to!" discussions in the morning.

#

Always gotta be people arguing on both sides. Can't ever mention JSON without this debate happening!

lament rock
#

node is pretty heavily single threaded. Would like to see someone make something numa aware

lusty quest
#

JSON is fine for static stuff, not for dynamic stuff

old cliff
#

Dont use json

lusty quest
#

json configs are fine

modest maple
#

i mean JS is fundamentally build around being single threaded

umbral zealot
old cliff
#

Use js module exports objects

modest maple
#

it's just it's nature just like Python

lament rock
#

WebJS threads and worker_threads are cool

quartz kindle
#

Json db is best json db > postgres

#

:^)

lusty quest
lament rock
#

write sql parser with json as backend!!!

quartz kindle
#

Their*

#

:^)

earnest phoenix
#

json only contains prefix doubt its gonna be a massive problem

lusty quest
#

this is how it usually starts. its "only" a prefix. then after a few weeks its "only" a prefix and a few channel ids

#

after a month for some reason your bot gets popular and you try to load a 1 GB json file

novel snow
#

TypeError: client.guilds.cache.get(...).channels.find is not a function

#

Fuck.

sudden geyser
#

I'm working on my userinfo command and adding a special case for when multiple members with the same username/nickname could be found via searching. I almost have the implementation, but I feel my wording is off: ```txt
A list of members with similar names were found.

  1. Lite#6155 (Lite)
  2. Bot1#0001 (Bot1)
  3. Bot2#0002 (Bot2)

Select a number between 1 and 3. This will timeout in 30 seconds.

What's a better way of writing this?
solemn latch
#

prefix's are important.
if a server changes a prefix, and then that prefix stops working they might just kick the bot because it doesnt work.

old cliff
novel snow
novel snow
old cliff
lament rock
earnest phoenix
#

its private bot tho idk why everyone screaming about json 💩

old cliff
#

😂

quartz kindle
#

At 2k guilds my json db was 15mb big

lusty quest
lament rock
#

That was probably when the demand was high for a poke bot since one of the big ones shut down or had issues. idk

vivid fulcrum
#

you just have to find the right audience

#

(kids)

modest maple
#

My jesus bot gained something dumb like 1.5k servers in 3 days bloblul

quartz kindle
#

jesus

modest maple
#

turns out people seem to like a bot that shouts the bible at you every time you say some profanity

lament rock
#

My bot gained over 1000 whenever YT started to ban IPs, so all the big bots got fucked and mine survived

lusty quest
#

if you find some thing you could do with a bot and it creates a demand no one knew they want it you can gain a lot of guilds quickly

old cliff
#

Just add a webpanel to your bot.... your guilds would increase drastically cause most people don't like command configuration

lament rock
#

Easier said than done

vivid fulcrum
#

true and true

lusty quest
#

i work on this now for almost 8 Months

lament rock
#

Web dev sucks

vivid fulcrum
#

end users are as smart as an insect

lusty quest
#

yea

#

just expect they are donkeys

quartz kindle
#

No

modest maple
quartz kindle
#

An insect is smarter

modest maple
#

JS time baby

lament rock
#

Woo

quartz kindle
#

Insects can find food kilometers away

old cliff
#

Lol

old cliff
#

On page?

modest maple
lusty quest
#

theoretical a Panda would be fitting, they are sort of dying out bcs they dont want to reproduce either in a Zoo or in the wilderness

modest maple
#

but i am a bigbrain which is how it works for me

old cliff
#

I thought it was disabled cause of xss

modest maple
#

it is

old cliff
#

Ok

quartz kindle
#

You can do a lot of cool shit with css only

modest maple
#

spot the iframe bloblul

sage bobcat
#

One message removed from a suspended account.

#

One message removed from a suspended account.

modest maple
vivid fulcrum
#

i got locked out of my main and it's been over a week since i sent an email to support

sage bobcat
#

One message removed from a suspended account.

vivid fulcrum
#

no response whatsoever

sage bobcat
#

One message removed from a suspended account.

quartz kindle
#

What happened?

#

Lost oauth2 device?

sage bobcat
#

One message removed from a suspended account.

vivid fulcrum
#

i got logged out on all devices

#

then when i tried logging back in, it asked for 2fa

#

i don't have the device i had my 2fa on anymore

quartz kindle
#

Rip

sage bobcat
#

One message removed from a suspended account.

#

One message removed from a suspended account.

lusty quest
#

no backup codes saved?

vivid fulcrum
#

nope

lusty quest
#

rip

old cliff
#

Sed

quartz kindle
#

Put 2fa on something like authy

#

So you can backup and sync

vivid fulcrum
#

yup i'm using authy on this account

sage bobcat
#

One message removed from a suspended account.

old cliff
#

No

quartz kindle
#

I dont think it does

sage bobcat
#

One message removed from a suspended account.

#

One message removed from a suspended account.

quartz kindle
#

I got rid of mine

boreal iron
vivid fulcrum
#

discord's whole login system is absolute trash

boreal iron
#

aye, it is

vivid fulcrum
#

the reason why they added qr code login is because the desktop login would log you out randomly so frequently

wide wharf
#

What code (permissions=?) do I need in the bot invite url for all perms?

sage bobcat
#

One message removed from a suspended account.

brittle idol
#

can someone point me to the guy that works with adding new tokens

boreal iron
#

thinking I provide them my real phone number... bullshit

brittle idol
#

?

cinder patio
#

Weird cause I've never experienced any issues with discord's login system

sage bobcat
#

One message removed from a suspended account.

wide wharf
# vivid fulcrum 8

but that's admin only, I mean how to set all opt-in at the role settings

quartz kindle
#

Wdym adding new tokens

sage bobcat
#

One message removed from a suspended account.

brittle idol
#

to the tipcc bot

sage bobcat
#

One message removed from a suspended account.

quartz kindle
#

Wrong server?

sage bobcat
#

One message removed from a suspended account.

brittle idol
#

lols

#

sorry guys

sage bobcat
#

One message removed from a suspended account.

brittle idol
#

weird i got here

#

bye

boreal iron
#

pain in the ass to rent a random number always just to receive a stupid verification code even if you disabled that shit

quartz kindle
#

Can you make it send an sms to another number?

boreal iron
#

sure... imma using (payed) local SMS APIs to receive infos about my server monitoring or messages where ever I've included it into my code to stay about to date about things

#

it's been used to send/receive SMS using random numbers as sender, a costum name etc.

quartz kindle
#

I had tons of issues with some stuff because my phone number was not available outside of the country

#

So i couldnt receive verification smss

boreal iron
#

well and I don't wanna share my number online so I've choosed one from GB this time, PL last time, US before... Discord doesn't give a fuck if geo location has changed during verifications

#

tried some free online available numbers before, but most of them are blocked, not so payed services offering SMS(ervices) for 24h/7d ... for a few bucks

#

some of these services even accept bitcoins just to stay a little more "anon"

quartz kindle
#

Btc and eth suck so much for payments these days

boreal iron
#

wouldn't make sense to provide my credit card to a strange service just because I don't wanna provide my phone nr to Discord KEKW

quartz kindle
#

Transaction fees are ridiculous

boreal iron
#

can't complain yet, but I know what u mean, yeah

solemn latch
#

isnt the transaction fees so high because mining is so profitable?

boreal iron
#

hmm "profitable"... got a little more so since the chart is going up

quartz kindle
#

Its not exacty profitable anymore

solemn latch
#

not for you and me, but for someone with a ton of money it is right?

boreal iron
#

if you steal the energy somewhere and don't have to pay for the hardware... I'm sure it is

quartz kindle
#

Well yeah, with the right equipment and low power cost

crystal wigeon
#

Was I pinged

#

Just hit 2k servers

solemn latch
#

there are apartments with no electricity bill in my area 👀

#

move in, start mining, ez profit

quartz kindle
#

They will kick you out fast

solemn latch
#

ez profit for 2 weeks

#
  • security deposit
quartz kindle
#

After they see the buildings energy bill skyrocket

#

xd

boreal iron
solemn latch
#

I wonder what you could reasonably mine before being noticed.

boreal iron
#

test it out lol

solemn latch
#

like, 4gpus, would you get away with it 👀

quartz kindle
#

The most profitable coin atm is ravencoin i think

#

Or ethereum

#

I ran some simulations, and my laptop could earn about 10 bucks a month from mining

#

After energy bills

boreal iron
#

not really a fan of these second-rate products

solemn latch
#

for a laptop that seems good

#

power bills are low in my area since we are a huge provider of coal for the country.

boreal iron
quartz kindle
#

XD

boreal iron
#

might sound funny but it actually isn't...

summer acorn
#

this may sound stupid but it's actually complicated for some reason; how the fuck do I check if a reaction is a heart reaction

boreal iron
#

just shithole countries and states everywhere... gonna create my own

summer acorn
#

I've tried using the unicode emoji, that doesn't work

#

same with heart and :heart:

quartz kindle
summer acorn
#

but it doesn't

boreal iron
#

that's mostly an indication of you're doing something wrong

summer acorn
quartz kindle
#

Whats the output

summer acorn
#

when I tried with that unicode, it returned with true

#

that extra unicode

lament rock
#

\❤️

quartz kindle
#

The extra unicode is the color selector

lethal trout
lament rock
#

If you escape built in emojis, Discord gives you a clean version you can copy which is raw unicode

quartz kindle
#

The color of the heart is defined with the extra unicode

summer acorn
#

I see,

lusty quest
#

like after you make your embed use client.channels.fetch(channelID).then(c=>c.send(embed))

earnest phoenix
#

how can i get all users? there are currently no users in my cache

cinder patio
#

when do you access the cache? It must be after the client has logged in

#

so after the ready event gets fired

earnest phoenix
#

ok I did it. i was making a mistake

earnest phoenix
#

i don't get any users and emojis cached

cinder patio
#

that wasn't a boolean question

cinder patio
#

you're supposed to replace channelId with a valid variable or a string literal

lethal trout
#

man i am very bad at db

cinder patio
#

maybe? I don't know how your code looks

earnest phoenix
#

Does anyone know how to show database ping in mongodb?

lethal trout
#

wow

cinder patio
#

data.channelId isn't a valid channel id

lethal trout
#

it is chaning the last 3 digits of the id

#

even if i change in it manually it becomes that

#

smh

lament rock
cinder patio
lethal trout
earnest phoenix
cinder patio
#

you're storing them as an integer, that's why they're getting rounded

lament rock
#

You can do it with eval derp

lethal trout
#

this is mine

cinder patio
#

store them as a string

lethal trout
#

u want to make it string?

lethal trout
#

like this?

cinder patio
#

maybe, I don't know what db you're using

lethal trout
#
const { Schema, model } = require("mongoose");
module.exports = model(
    "logging",
    new Schema({
        req: {
            required: true,
            type: Boolean,
            default: false
        },
        channelID: {
            type: String
        },
        guildID: {
            type: Number
        },
        MessageUpdate: {
            required: true,
            type: Boolean,
            default: false
        },
        MessageDelete: {
            required: true,
            type: Boolean,
            default: false
        }
    })
);```
cinder patio
#

sure

#

make guildID also a string

lethal trout
#

hope it works

#

trin to fix it since 3 days

#

ngl

cinder patio
#

that's the issue

#

You can also store them as BigInts

quartz kindle
#

Javascript doesnt normally support big numbers like discord ids, thats why

lament rock
quartz kindle
#

Numbers that are too large get rounded

lethal trout
#

why?

quartz kindle
#

Youre still doing something else wrong

#

Show code

lethal trout
#

which code?

#
const { Schema, model } = require("mongoose");
module.exports = model(
    "logging",
    new Schema({
        req: {
            required: true,
            type: Boolean,
            default: false
        },
        channelID: {
            type: String
        },
        guildID: {
            type: String
        },
        MessageUpdate: {
            required: true,
            type: Boolean,
            default: false
        },
        MessageDelete: {
            required: true,
            type: Boolean,
            default: false
        }
    })
);```
quartz kindle
#

The code that is causing the error

lament rock
#

a get from database usually returns an entry or null if the key doesn't exist in the database

quartz kindle
#

msgedit.js

lethal trout
#

k

lethal trout
# quartz kindle msgedit.js
const client = require('../index')
const Discord = require('discord.js')
const logs = require('../models/logs')

client.on("messageUpdate", async (oldMessage, newMessage) => {
const channel = oldMessage.channel
    if (oldMessage.content === newMessage.content) return;
    const data = await logs.findOne({
        guildID: newMessage.guild.id,
        channelID: channel.id,
        MessageUpdate: true
    });
console.log(data.channelID)
    if (data) {
//const targetchannel = client.channels.fetch(data.channelID)
//console.log(targetchannel)
        const embed = new Discord.MessageEmbed()
            .setAuthor('A message has been edited!')
            .setThumbnail(oldMessage.author.displayAvatarURL({ dynamic: true }))
            .setColor('#FF0000')
            .addField("Edited by:", oldMessage.author.tag)
            .addField("Edited in:", oldMessage.channel)
            .addField("Edited at:", oldMessage.createdAt)
            .addField("Before:", oldMessage.content)
            .addField("After:", newMessage.content)
            .addField("URL:", `[Click Me](${oldMessage.url})`)
            .setTitle('Message Edited!')
            .setTimestamp()
        client.channels.fetch(data.channelID).then(c=>c.send(embed))
    } else {
        return
    }
})```
cinder patio
#

you probably have to empty the data inside your current database

#

because guild and channel ids are stored as numbers

quaint wasp
#

Guys

#

at that config part..

#

I tryed everything

#

../config.json

#

/config.json

#

../../config.json

#

./config.json

#

I know how it works

#

But...

#

rn

boreal iron
#

" " `

quaint wasp
#

o

#

...

#

wait

#

never mind

#

🙂

boreal iron
#

now test your examples again and see which one works

quaint wasp
#

How do I define channel?

#

😐

#

I never defined channel...

#

It usally defineded it self..

obtuse jolt
quartz kindle
quartz kindle
#

logs.findOne did not find anything

lethal trout
#

pls tell how to fix it?

quartz kindle
#

The error says data is null

lethal trout
#

but how?

quartz kindle
#

console.log data

tired panther
#

Mongodb eyesLeft

zenith terrace
#

@quartz kindle uwu green name

quartz kindle
#

uwu

tired panther
proven lantern
#

in discordjs-light is there some way to use the GuildMember.hasPermission function without cacheRoles: true option?

tired panther
proven lantern
#

i was using the msg.guild.me object originally, but i believe that required caching. now i do this const client = await discordClientPromise; const me = await msg.guild.members.fetch({user: client.user.id});
me.hasPermission("MANAGE_ROLES")

tired panther
lusty quest
#

but iirc you need to have the roles cached

lusty quest
tired panther
tired panther
proven lantern
#

the permissions field is a 0 bitwise unless i add the caching

proven lantern
#

yeah

tired panther
quartz kindle
#

You can fetch roles without caching, if you dont mind hitting the api more often

#

If your commands are not being used lots of times per second it should be fine

#

Another alternative is to manually manage the permissions for the bot member

#

By keeping them synced using memberUpdate and the role events

#

But it wont be easy because discord.js roles are a clusterfuck

proven lantern
#

i should be okay with only the cacheRoles and cacheGuilds options enabled. my memory usage with discord.js was getting out of control so hopefully this will be enough

quartz kindle
#

Yes, should be fine like that, roles are relatively cheap to cache

tired panther
proven lantern
#

i noticed that the memory usage with discord.js doesn't grow instantly. right after a restart it only takes up about <100mb. after a day it's at about 200mb. hopefully it's discord.js cache issue and not a memory leak issue with my code

feral aspen
feral aspen
tired panther
misty sigil
#

370mb for 390 servers

#

Bloody hell

tired panther
misty sigil
#

tim uses more than 3x less than that for 7k

feral aspen
#

Somehow my users cache (1 month ago) decreased from 220k members to 50k so it started using less which is about 300mb maximum.

proven lantern
#

i'm basically getting the same ram usage for the same server count

feral aspen
#

Indeed.

#

bot.users.cache.size;

tired panther
#

thats the reason

proven lantern
#

discord.js-light is going to solve all my problems

misty sigil
#

I use djs-light and I’ve got 100mb for 430 servers

feral aspen
#

Difference?

proven lantern
#

discord.js-light lets you control what is cached

summer torrent
#

i got 190 mb for 800+

quartz kindle
feral aspen
tired panther
#

Everyone Shiba_Love discord.js-light

quartz kindle
#

discord doesnt give you online members anymore without the intent

#

Before you would receive all online members at bot start

#

Now you only receive members in voice channels and the bot itself

#

Unless you explicitly ask for members with the intent

feral aspen
#

I have both presence and guild intents, does that affect anything or yet, same?

quartz kindle
#

If you enabled both of them, then your members should be like before

feral aspen
#

It's yet at 60k.

quartz kindle
#

Did you use fetchAllMembers before?

feral aspen
#

I don't think so, no.

quartz kindle
#

Hmm weird

feral aspen
quartz kindle
#

Ah i know why

feral aspen
#

Go ahead.

quartz kindle
#

Thats an instant -100k lmao

feral aspen
#

Well my bot's cache remained the same for about 3 weeks then it decreased.

#

Why that huge delay, though?

#

Was it trying to remove from the cache?

quartz kindle
#

Was your bot always online during that period?

#

No restarts?

tired panther
#

I am to lazy to invite it xD

feral aspen
quartz kindle
#

Then idk

feral aspen
#

Rather than that, i'm a good guy who restarts it every hour.

#

😂

quartz kindle
#

I dont know how top.gg removed the bots

#

Could have taken a while

feral aspen
#

I guess they fetched all bots and removed them?

#

🤷‍♂️

tired panther
quartz kindle
#

All bots

feral aspen
wanton phoenix
#

Sa

feral aspen
#

Yeah, they removed all the bots from top.gg.

tired panther
feral aspen
#

Indeed.

tired panther
feral aspen
#

😂

tired panther
feral aspen
#

I deleted the message, lol

#

Peace out.

lament rock
#

Lol. I've got 80MB for 3k servers :)

quartz kindle
#

Nice

tired panther
humble gyro
#

machine learning is pog

lament rock
#

No lol

humble gyro
lament rock
lament rock
#

Yes 👀

quartz kindle
tired panther
# humble gyro

do you use your own api or a public one like dialogflow?

#

oh no i pinged them BantmuoXD

humble gyro
tired panther
humble gyro
#

it's free

stable nimbus
humble gyro
#

it's just a C# library

tired panther
tired panther
proven lantern
#

are you using a jupyter notebook to do machine learning in?

opal plank
lusty quest
# humble gyro

ive submitted a bot yesterday that would flag you for this

lusty quest
feral aspen
#

Why is it like this?

lusty quest
#

empty embed?

tired panther
lusty quest
#

or did you send a Image?

feral aspen
#

No.

lusty quest
#

bcs this looks also like a Invalid image url

feral aspen
#

I have a .setDesription

lusty quest
#

only the Description?

vivid fulcrum
#

show your code

feral aspen
#
                        const embedTwo = new MessageEmbed()
                        .setColor(cyan)
                        
                        if(boxes === 1) {
                            embedTwo.setDescription(`You collected your weekly reward of **$${reward}** and **${boxes} Mystery Box**. Your new balance is **$${data.money}**!`);
                        } else if(boxes >= 2 && boxes <= 3) {
                            embedTwo.setDescription(`You collected your weekly reward of **$${reward}** and **${boxes} Mystery Boxes**. Your new balance is **$${data.money}**!`);
                        };
                        
                        message.channel.send(embedTwo);
vivid fulcrum
#

none of those statements were true so the description wasn't set

feral aspen
#

🤦‍♂️

#

Thank you!

vivid fulcrum
#

always, np

feral aspen
#

😀

cinder patio
#

Also doing all that just do make a single word plural...

#
.setDescription(`.... and ${reward} Mystery Box${boxes === 1 ? "":"es"}`);
earnest phoenix
#
  return message.channel.send(new MessageEmbed().setColor("BLUE").setDescription("3 karakterden uzun bir prefix oluşturamazsın!"));
  }``` is there an error here? I saw an error called "length of undefined" on the console
vivid fulcrum
#

you tell us

#

if that error appeared it means that args[0] returned undefined

cinder patio
#

Check if args[0] exists before doing anything with it

earnest phoenix
#
  return message.channel.send(new MessageEmbed().setColor("BLUE").setDescription("Lütfen bir prefix giriniz."));
  }```
cinder patio
#

yeah that works

earnest phoenix
#

already existed 😄

ancient grove
#

Hello Can soemone help me with my bot i cant have node.js and the other one. can someone pls help.

summer torrent
#

what is the issue

tired panther
#

Cannot read property issue of undefined

rustic patrol
#

Guys

#

How to add my bot in here?

vivid fulcrum
#

your bot will not be invited here

#

but you can add it to the list

rustic patrol
#

Yeh I wanna add it to the list

proven lantern
#

i just deployed the discord.js-light library update and it is now taking up 67 mb right after boot with discord.js-light. it was taking up 87mb on startup before. hopefully the memory doesn't grow too much. thanks Tim

rustic patrol
#

Pls tell me how I'm lazy to read on faq

#

Idk where to read

vivid fulcrum
#

sucks to be you

rustic patrol
#

I mean idk where to add it

#

there is SO many letters therw

vivid fulcrum
#

ok

#

it's like a minute long read

rustic patrol
#

can u tell me what it starts with

vivid fulcrum
#

scroll and you'll see

rustic patrol
#

Up or down

vivid fulcrum
#

✨ brain exercises ✨

misty sigil
#

gotta flex that brain

misty sigil
rustic patrol
#

K

quartz kindle
#

If you had done so since the beginning instead of asking, it would have been faster and less effort

#

So youre not actually lazy

rustic patrol
#

My bot name is Tenjo

#

Like wtf

misty sigil
#

what

elder onyx
#

Hi

#

Hmm

#

I want to make a bot

#

And i will learn jave script

#

So

#

Where can i learn it?

dreamy gulch
#

on youtube you can find a lot of material

tired panther
wanton prism
#

is this a good idea to use raspberry pi for 7/24 working discord bot?

lament rock
#

YouTube is a bad resource for JS tutorials

#

and coding in general

quartz kindle
#

If your internet is good, yes @wanton prism

unreal estuary
modern granite
#

idk guys kinda strange question, but... So I am using discord.py and I have the following error: Command raised an exception: Forbidden: 403 Forbidden (error code: 50013): Missing Permissions. I read the docs and as it turned out the bot has to be upper than the highest role of the member, I am trying to change the nickname of. So here is the actual question: How to make the bot set his role higher itself, or the admins must do it themselves? Yeah I know idiot question but pls help lol

slender wagon
#

i am working on a clear command but i want it to clear a certain user that's been pinged. How am i supposed to do that

modern granite
wanton prism
quartz kindle
#

Mbps, ping, stability

tired panther
#

@quartz kindle** Why do the "Internal_Server_Error" occur?**

quartz kindle
#

One of the main advantages of paying for a vps is that they have super good internet

tired panther
tired panther
quartz kindle
#

Stability is the most important thing

crimson vapor
#

realistically no

quartz kindle
#

Even if your bot doesnt use a lot

crimson vapor
#

my bot doesn't use nearly 10mbps

quartz kindle
#

Neither does mine

tired panther
wanton prism
crimson vapor
#

way less

quartz kindle
#

About 5KB/s which is about 40kbps

wanton prism
#

ok i got 34mpbs and 4 ping, no packet loss

tired panther
wanton prism
#

then its ok

crimson vapor
#

chip's dedi is only using 50mbps up and down

tired panther
crimson vapor
#

because the images are small

#

the images I generate are only 61KB

quartz kindle
#

With hundreds of music streams?

tired panther
crimson vapor
#

idk if ll does things differently tho

#

ok well I do mine ~60 tims are 200

#

even then

#

tims bot isnt the biggest

quartz kindle
crimson vapor
#

wait tim did your images require basic trig knowledge to make?

quartz kindle
#

Sometimes i get 10 commands per minute, other times 1 command in 5 minutes

quartz kindle
tired panther
crimson vapor
#

that seems like fun /s

quartz kindle
#

Yes /s

quartz kindle
wanton prism
#

my bot going to do less but just collect some points per command, then 34 mpbs is ok i think

quartz kindle
#

Should be fine

#

Is it both dosnload and upload?

#

Upload speeds are very important

wanton prism
#

nope upload is 5 mpbs

quartz kindle
#

Should still be fine

tired panther
quartz kindle
#

But watching netflix will likely interfere with your bots stability

crimson vapor
#

no one saw that

crimson vapor
#

fuck circles

#

idk if im ready for that hell again

wanton prism
#

then ok i'll try, it looks easier to me to use raspberry pi

#

thanks

crimson vapor
#

raspberry pis are nice but realistically the upfront cost and power will cost more than a cheap vps

tired panther
quartz kindle
crimson vapor
#

realistically my 4gb one can handle 30k guilds

tired panther
quartz kindle
#

Depends what it does

crimson vapor
#

not on djs tho

wanton prism
crimson vapor
#

just the way my bot is written

#

yea, its a bit annoying being forced into paying kinda

quartz kindle
#

Paying per year is nicer

crimson vapor
#

yea

#

pay for the vps when you do your domains

quartz kindle
#

Gives you peace of mind plus you get discounts

crimson vapor
#

yeah I think I could save ~20 if I payed by the year

wanton prism
#

its kinda hard for me to make some updates

tired panther
wanton prism
#

thats why raspberry way easier i think

tired panther
crimson vapor
#

I could use it but im not gonna risk hosting things on my home network

#

if I accidentally post my vps ip somewhere idc

#

but home ip

#

yikes

tired panther
#

Run it on a vpn Shiba_Cool

crimson vapor
#
  1. then I would need a vpn
  2. added ping