#development

1 messages · Page 1699 of 1

pale vessel
#

\u202b

#

i don't want rose since i prefer structured response

#
  • discord api docs is not that good for me
rapid wharf
#

OP counter

#

BTW

pale vessel
nova wadi
#

wtf

#

are u guys real?

pale vessel
#

We're bots

rapid wharf
#

i am working on a command to add reaction to a msg tried this code but not working (py)

        aemoji = {<":"+emoji.name+":"+emoji.id>}
        await message.add_reaction(aemoji)```
cant figure out how to get the recent msg and add a particilat reaction to it
#

We all are bots. mmulu

slender thistle
#

What the fuck

#

Just use f-strings

rapid wharf
#

what are f-strings

#

i m new

#

i have less knowledge

pale vessel
#

f"{emoji.name} text" like this

rapid wharf
#

aree but the code is wrong

#

its not working

slender thistle
#

actually wait

#

can't you just str() it

rapid wharf
#

wait

#

let me explain

#
async def react(ctx):
    for m in ctx.channel.history(limit=1):
        await m.add_reaction(":hatbc:")
pale vessel
rapid wharf
#

this is the final code and its not working

pale vessel
#

hatbc?

rapid wharf
#

emoji name

#

🙃

pale vessel
#

you need to provide the emoji class or identifier

#

just the name isn't enough

rapid wharf
#

i used in <:emojiname:emoji_id>

#

the way bots process the emoji

#

but the code is not working

#

no respone

#

and no error

pale vessel
#

Try emojiname:id without <>

rapid wharf
#

but i wnat to add reaction on a particular msg

#

like NQN does

pale vessel
#

I see

#

then you need to fetch the message that you want to react too

rapid wharf
#

yes yes

#

and for that i used for m in ctx.channel.history(limit=1): but not working

pale vessel
#

Why not?

#

Got any error?

rapid wharf
#

??

#

no error

#

no response

pale vessel
#

you need to use async for since it returns an async iterator

#

or if you want it to be a list, use await channel.history().flatten()

rapid wharf
#

ohhhhhh

#

let me try it

onyx hare
#

how would i setTimeout() this without it sending blank embeds? i removed the setTimeout as its effecting the text being sent

const Discord = require("discord.js");
const fs = require('fs');
const path = require('path');
const charactersPerMessage = 1600 - 50;
const acheats = fs.readFileSync(path.resolve(__dirname, '../cheats/acheats.txt'));
const numberOfMessages = Math.ceil(acheats.length / charactersPerMessage);
exports.run = async (client, message, args, utils) => { 
    const embed = new Discord.MessageEmbed().setTitle(`The Sims 4 Adult Skill Cheats`).setColor("GREEN");
    for (i = 0; i < numberOfMessages; i++) {
      message.channel.send(
           embed.setDescription(
            acheats.slice(i * charactersPerMessage, (i + 1) * charactersPerMessage)
            )
           )}
  message.delete()
}
umbral zealot
#

ok and what did it look like with the setTimeout?

#

Also are you sure you didn't mean setInterval ?

onyx hare
#
const embed = new Discord.MessageEmbed().setTitle(`The Sims 4 Adult Skill Cheats`).setColor("GREEN");
    for (i = 0; i < numberOfMessages; i++) {
      setTimeout(() => message.channel.send(
           embed.setDescription(
            acheats.slice(i * charactersPerMessage, (i + 1) * charactersPerMessage)
            )
           ), 2000)}
umbral zealot
#

yeah so what's going on here is that you have code that says "hey for each message, after 2 seconds send it" and what it does is, it sends them all at the same time, after 2 seconds kek

onyx hare
#

ya but it doesnt send whats in the txt if i have the timeout

umbral zealot
#

Now, interestingly, the other problem you have is that you will probably need to setDescription outside of the message.send

#

embed.setDescription("Blah")
mesage.channel.send(embed)

umbral zealot
#

what are you actually trying to do?

pale vessel
#

it returns the class so that should work

onyx hare
#

so basically when the txt triggers it sends each embed in like 0.5ms and ratelimtes b4 it finishes all the embeds

umbral zealot
#

Alright. try this. multiply the 2000 by i

#

so it's 2000, 4000, 6000, 8000

#

isntead of all being sent after 2 seconds

#

see if that helps it

onyx hare
#

itll be this part i do tht for right (i + 1)?

umbral zealot
#

no

#

the 2000 milliseconds timeout

#

multiply it

#

by the i variable

#

Also, if that doesn't work, add a let in front of your declaration of i, as you should have done to start with, you need let or const when declaring variables in scope

onyx hare
#

it worked but still sent empty embeds

umbral zealot
#

did you add the let

#

for (let i = 0; i < numberOfMessages; i++) {

onyx hare
#

ya i forgot to add, now thats in its worked with the txt ty

umbral zealot
unreal estuary
#

what is php mainly used for

umbral zealot
#

programming

unreal estuary
#

wow

umbral zealot
#

back-end of websites usually

unreal estuary
#

so its a serverside language

umbral zealot
#

well yes there is only one front-end language so all other languages are server side

#

technically

unreal estuary
#

true

#

is it abit like node or python?

umbral zealot
#

yes, pretty much

unreal estuary
#

thanks

#

im looking at this basic hello world

#

and it looks like some kind of html server side stuff

west wyvern
#

Hey guys, Im getting an HTTPException due to an error 429 when I run my bot. This error is because I "have exceeded the rate limit frequently". I believe it's because I have many users accessing at the same time, the server number has been growing fast. How can I get around this? My bot is running on repl.it

#

The only API calls I make are "if message.embeds" and "message.add_reaction"

slender thistle
#

Could you show your code?

west wyvern
#

Here it is

#

I modified the strings

slender thistle
#

Aaa... seems... yeah, can you try printing the times when the messages that pass the condition are sent?

west wyvern
#

you mean print on line 30 to check how many times I send the message.add_reaction?

slender thistle
#

Eh, works too

#

You could probably print more helpful information like channel ID and current time

modest crane
#

bruh

#

why are you still trying lol

silk wadi
earnest phoenix
#

Im having trouble setting up a subdomain on git jit book

earnest phoenix
#

When i try to set up the domain on my jitbook it says using cloudflare is discouraged and you shouldnt do that. I ignored and pressed next and it threw an unknown error

#

Any halp?

#

|| when in doubt, ping @quartz kindle||

west wyvern
prime glacier
#

Discord.js v11.6.4
code : if (!users[person]) { makeUser(person); }
error
TypeError: makeUser is not a function

vivid fulcrum
#

well it's not a function

#

also update to v12

prime glacier
#

my code is in v11 so i cant update to 12 rn

prime glacier
vivid fulcrum
#

so update your code to v12 lol

#

that's such a stupid reason

#

v11 already started breaking

prime glacier
#

ok

vivid fulcrum
#

and most likely, it's going to be fully out of function by the end of the year

umbral zealot
#

Actually it's fully out of function now, the second you hit a server with a Stage channel, it's dead

earnest phoenix
#

@prime glacier im gonna purposely add your bot to a server with a stage channel and break it to force you to update to v12

crimson vapor
#

my friend got his token reset

#

because of stages

urban surge
#

Twitter acces token secret
Twitter user id
Twitter acces token
Twitter consumer secret
Twitter consumer key

Are these necessary to transfer tweets to automatic discord channel?

torn ravine
#

If my commands are stored like this, How would I get each of the commands in the same category

#

Description is not final

vivid fulcrum
#

filter the modules where the category is the same

#

ok

near igloo
#

why does js message.author.send(content) in discord.js return this error:(node:17248) UnhandledPromiseRejectionWarning: DiscordAPIError: Unknown Channel

#

ive used that before

#

it should work

#

i dont get it

earnest phoenix
#

How can I check if a arg contains all capital letters in js?

near igloo
earnest phoenix
#

thx

near igloo
#

idk if the touppercase is correct but vscode intellesense should have you covered

#

standard js function

#

so it should

near igloo
earnest phoenix
#

toUpperCase is for put all sentence in upper case

near igloo
#

you just need to see if string == string.toUpperCase()

#

ping me if need anything else

#

i was a green name before disc banned me for no reason

earnest phoenix
#

and how i check if sentence have 5 or more caps @near igloo

near igloo
#

uhhm

earnest phoenix
#

i have try with > 5 but doesn’t work

near igloo
#

you need to turn it into an array of characters... 🤔

crimson vapor
#
<String>.split('').filter(e => e.toLowerCase() !== e).length```
#

that should work

near igloo
#

thatll work

#

you could also do uppercase and not have the ! but either works

crimson vapor
near igloo
#

👍

#

tho i will warn you @earnest phoenix if you are doing automod, Four Caps Limit Is Really Small.

onyx hare
#

i dont get why this isnt wrting into the json file as instructed to some of it might be cutting off b4 it gets to the write? no err

const fs = require('fs');
const path = require('path');

exports.run = (client, message, args) => {
    message.channel.send('Fetching Servers...').then(sent => {
        sent.edit(`I Am In ${client.guilds.cache.size} Servers, Proudly Serving On <https://discord.com>`);
      }).catch(console.error);
      let guild = client.guilds
      let servercount = { 
        Guildname: `${guild.name} | ID ${guild.id}`
    };
    message.delete({timeout:10});
    fs.writeFileSync(path.resolve(__dirname, 'servers.json'), JSON.stringify(servercount)).catch(console.error);
}
earnest phoenix
#

@crimson vapor :


const getCount = sentence.split('').filter(e => e.toLowerCase() !== e).length;

if(getCount > 5) console.log(`No, the sentence have only ${getCount} caps!`);
else console.log(`Yes, the sentence have 5 or more caps. Caps count : ${getCount}`);```

He tell me « yes » but have only 2 and no 5 or more
crimson vapor
#

your log is backwards

near igloo
#

like just replace JSON.stringify(servercount with that

onyx hare
#

oki

near igloo
earnest phoenix
#

uh yes lol

slender wagon
#

welp, so i am trying to get someones pfp and put it in the dashboard as a gif

user3.user.avatarURL({size: 64, format: 'gif'}) 

the problem is that if this user doesn't have a gif pfp it doesn't show up at all

#

is there a way through this

earnest phoenix
#

Use the dynamic option

slender wagon
#

thanks!

marble juniper
#

@earnest phoenix do you know how to parse codeblocks and get what language the codeblock has (in typescript / javascript)

#

how do I do it

#

lol

earnest phoenix
#

You mean what the codeblock's specified language is?

#

Like

```<language> <- here?
Code
```

marble juniper
#

yes

#

and also what the code itself is

#

its for my eval command

#

lol

earnest phoenix
#

JavaScript or TypeScript? Which one are you writing it in

marble juniper
#

typescript

#

the executing of typescript code is not gonna be a problem lol

crimson vapor
#

it might be

marble juniper
#

do you just use some kind of regex or an npm package

marble juniper
crimson vapor
#

how do you parse types in an eval

marble juniper
#

the typescript package has a way of transpiling strings that have typescript code to javascript

crimson vapor
#

ah

marble juniper
#
import * as ts from "typescript";

let code: string = `({
    Run: (data: string): string => {
        console.log(data); return Promise.resolve("SUCCESS"); }
    })`;

let result = ts.transpile(code);
#

see

earnest phoenix
#
function parseCodeblock(input: string) {
  const [, language, code] = (input.match(/\`\`\`(\w+)\s*?\n([\s\S]*)\n\`\`\`/) || []);

  return { language, code };
}```
marble juniper
#

oh so its a regex party

#

I see

#

lol

marble juniper
#

how would I check that

#

lol

earnest phoenix
#

If there are no codeblocks it would return { language: undefined, code: undefined }

vocal trellis
#

how to get an custom image on top.gg like the background of your bot preview

#

like this

marble juniper
#

kinda hot ngl

#

love it

earnest phoenix
#

👍

#

Can someone help me with the pull request of js.org? Idk what to do

#

The subdomain

#

Idk what i should do with the pull request

#

Can someone help me?

heady sable
#

I found this bot, https://top.gg/bot/782309258620305438
How is it making the profile picture of the bot move up and down?
ik its the markdown css thing, but a ton of people have it and I wanted to know what it was

earnest phoenix
#

It's just CSS, with keyframes and animations, find the div that holds the avatar of the bot and apply the animation on it

unreal estuary
#

um

#

what language is this lol

#

'PLEASE GIVE UP'

summer torrent
#

i

crimson vapor
#

The Compiler Language With No Pronounceable Acronym (INTERCAL) is an esoteric programming language that was created as a parody by Don Woods and James M. Lyon, two Princeton University students, in 1972. It satirizes aspects of the various programming languages at the time, as well as the proliferation of proposed language constructs and notatio...

unreal estuary
#

thanks lol

crimson vapor
unreal estuary
#

wow

#

does anybody actually use it

marble juniper
#

@earnest phoenix How would you rate this

#

it may or may not be a little bit ugly

#

but I tried my best ok

#

its the code for my eval command

#

lol

earnest phoenix
#

Not that bad, wanna see mine?

marble juniper
#

sure

#

maybe I can learn from urs

earnest phoenix
marble juniper
#

looks like a bit of a mess

#

lol

earnest phoenix
#

Type checks moment much?

marble juniper
#

juuust a little bit

#
if (typeof output !== 'string') output = util.inspect(output)
output = output.replace(/`/g, `\`${String.fromCharCode(8203)}`).replace(/@/g, `@${String.fromCharCode(8203)}`)
#

I added this now

#

to my code

#

lol

#

forgot that you had to do that or something

#

well whatever I have it now

#

time to wait 10 minutes or less for docker to build and run my bot

#

its a docker compose file with my bot container and a mongodb container

#

lol

#

cuz yes my bot is completely dockerized

#

docker ontop

earnest phoenix
#

guys i have a paragraph in my web and i want when the button is pressend add 1 to that paragraph like
clicks
1
clicks
2

earnest phoenix
#

@umbral zealot

#

anyone?

pale vessel
#

Don't ping people, they're not here to help you 24/7

umbral zealot
#

I like the "let's ping the person that keeps telling me to google and learn shit, surely they will help when I call!" Attitude.

earnest phoenix
#

sorry

#

ill do that myself

marble juniper
#

feels like a help vampire lol

#
The Help Vampire problem is the idea that some users will continually ask the same tired questions in the hope that someone else will do their work for them, irrespective of whether the same question has already been asked or whether they could easily find the solution elsewhere.
#

maybe not the part with the continually asking the same questions

#

but defenitly the last part

#

lol

#

I recommend you to search ur question using a search engine first and then asking here

near igloo
#

Can someone help me please

marble juniper
#

maybe ur bot doesn't have a dm channel open which is why it says Unknown channel

#

lol

earnest phoenix
marble juniper
#

not rly sure tbh

earnest phoenix
#

u right

marble juniper
#

use message.author.createDM()
I think

#

idk if thats the method

#

lol

#

u can find what method it is in the docs

#
near igloo
earnest phoenix
marble juniper
near igloo
marble juniper
#

at least try it

odd stratus
#

message.author.send works for me

earnest phoenix
marble juniper
near igloo
#

Cuz that happened recently

marble juniper
#

uh what

odd stratus
#

Mines verified and the message.author.send way works for me

#

Not sure if this even matters for being able to send users DMs but does your bot have both intents enabled

marble juniper
#

I don't think ur bot being verified changes the way sending a dm works

#

lol

near igloo
#

Also try making your bot dm a user it hasn’t dmed before?

odd stratus
marble juniper
#

@near igloo I would suggest just adding a try catch block to send a message to chat so the user knows it failed to send the dm

#

lol

pale vessel
#

It doesn't have to do with intents since DMs are handled by REST

marble juniper
#

I hope you know how to use a try catch black

#

lol

#

or what it even is

near igloo
zealous verge
#

dm yourself through the bot ez owoThink

earnest phoenix
#

can someone help me with lua

marble juniper
#

idk how to use lua sorry

#

lol

earnest phoenix
#

😔

vivid fulcrum
#

🚽

marble juniper
#

the only person ik that knows lua is voltrex

#

maybe try asking him

marble juniper
earnest phoenix
#

@earnest phoenix

near igloo
zealous verge
#

the person should be in your server

odd stratus
#

@near igloo Still worked

near igloo
near igloo
zealous verge
#

message.author => the author of the message in the server S3RoPeek

#

are you trying to dm someone outside of your current guild WBHoloThink

near igloo
marble juniper
zealous verge
#

well yeah

near igloo
marble juniper
#

message.author is a user object

#

lol

near igloo
#

Lmao yes ik what it is

zealous verge
#

WBChinoRock did i say anywhere what it returns i mean sorry i couldnt explain it better lmao

#

but yeah u shouldnt have problem to dm people

marble juniper
#

yes

zealous verge
#

also typescript oop

near igloo
umbral zealot
#

It if was you wouldn't be able to do anything

#

DMing a user works fine as long as the user shares a guild and hasn't blocked your bot.

#

It doesn't require any intents.

zealous verge
#

discord doesnt really lock ips - only tokens on alot of ratelimits or when u get server banned

near igloo
odd stratus
#

I'm confused as to why it's an Unknown Channel error though

umbral zealot
#

I ahve a feeling the error isn't coming from that particular line

#

¯_(ツ)_/¯

odd stratus
#

If it couldn't DM the User you would get "DiscordAPIError: Cannot send messages to this user"

umbral zealot
#

But that's my theory

#

Theory is you're looking in the wrong place

near igloo
odd stratus
#

Is there any other line in your command causing the unknown channel error

umbral zealot
#

Show the full command or event code related to what produces this.

blissful coral
#

Wait so are stage channels audio streams the same as voice channels?

near igloo
umbral zealot
near igloo
zealous verge
#

yey and thats why more people should use typescript

near igloo
umbral zealot
#

when you are, let us know

near igloo
#

But it’s basic eval and send results

blissful coral
potent monolith
#

hi

odd stratus
blissful coral
#

Then yeah its the same

#

its the identifying them part and there attributes because they have more

vivid fulcrum
#

stage channels are just glorified voice channels

blissful coral
#

yers

#

yes

zealous verge
#

too op voice channels with messed up perms

potent monolith
#

hi

blissful coral
#

Eh ima just edit djs to have it work with stage channels KEKW

odd stratus
blissful coral
#

where the hell are the stage channeld ocs

zealous verge
#

PooshKek problem with stage channels is u cant give members specific perms if u want to have an event where someone can mute or unmute u have to five the person the manager role which gives them all perms for the vc malLunaaAA

blissful coral
#

wait were docs not updated yet?

#

aren't deployed on stable site but are on the github lulw

zealous verge
#

ikr PooshKek

waxen bough
#

this is what my code looks like when transpiled. tsc added some funcs for importing. I assume what it means import * as Puppeteer is that correct? That's probably reason why i had to put .default

pale vessel
#

Then it's like Erwin said

#

import() is different than import

#

It works the same as require or import * as something

blissful coral
#

I found the response of a StageChannel

#

Time to do shit with it now KEKW

rustic nova
#

oh no

#

since when can voice channels be marked as nsfw

blissful coral
#

Yeah thats what I am saying

quartz kindle
#

naughty

blissful coral
#

I mean

#

You can't set them

#

To nsfw or not

#

I got kinda scared when I saw nsfw for stage channels lmfao

quartz kindle
#

could be a bug/oversight

blissful coral
#

Eh

quartz kindle
#

the docs are still not merged

blissful coral
#

It is apart of regular voice channels too

#

@quartz kindle

quartz kindle
#

welp

#

¯_(ツ)_/¯

blissful coral
#

Its time KEKW

#

lulw

quartz kindle
#

djs master has a PR for stage channels

blissful coral
#

Ik

quartz kindle
#

from what i heard it pretty much works

#

so just copy that

blissful coral
#

Oh?

#

I didn't know it worked KEKW

#

Saw a few flaws

#

Guess ima pr the pr lulw

quartz kindle
#

xD

#

they are just delaying it because the api docs are not finalized

#

djs never merges until discord merges the docs for it

blissful coral
#

Do you by chance know where this pr is

#

I may be blind

#

nvm

#

its literally the last one

quartz kindle
#

xD

blissful coral
#

Alright time to just

#

delete djs

#

Nah jk just gotta find files to change

quartz kindle
#

djs is pain

blissful coral
#

I agree

#

But I don't feel like switching rn

quartz kindle
#

everytime they change stuff i have to study what they did to make sure it doesnt break djslight

blissful coral
#

lmfao

#

They always make changes that you HAVE to change all your code

#

lmao

quartz kindle
#

xD

earnest phoenix
#

there a way to make a inventory command using an array?

there's duplicates in the array and I want it to appear as

item — item_count

and not
[item, item, item2, item, item]

quartz kindle
#

better use an object

umbral zealot
#

You should probably use an object instead then.

#

There, the 2 proficient people agree.

quartz kindle
#

unless your inventory doesnt join items of the same type

#

if you want to display all items separately, including duplicates, then use an array

earnest phoenix
#

its already an array

quartz kindle
#

if you want to show item count, use an object

umbral zealot
#

Ok but why not use an object

#

Don't you have a unique identifier for each object?

earnest phoenix
#

no

umbral zealot
#

Well they should KEKW

quartz kindle
#

how do you know there are duplicates then?

#

you have to have something to identify them

earnest phoenix
#

because multiple items can be added to the array at once

#

wait

quartz kindle
#

yes but what makes one a duplicate of another?

#

a name? an id? a number?

umbral zealot
#

That's not answering the question

earnest phoenix
#

same name

quartz kindle
#

alright

#

so use the name and create an object

#

like this

#
{
  item1: {
    ... data about item one,
    count: 1
  },
  item2: {
    ... data about item two,
    count: 42
  }
}
#

instead of having item2 42 times in an array, you have it once with a count field

earnest phoenix
#

what language is that

quartz kindle
#

what language are you using?

earnest phoenix
#

python

quartz kindle
#

then use a dictionary

#

its python's version of an object

earnest phoenix
#

ok but how would I add to the count and if its there

quartz kindle
#

access it and increment the count

#

idk how python does it, but should be something like variablename[itemname]["count"]++

onyx hare
#

I Cant Get This To Write In The Assugned File (File is in the same place as index)

const fs = require('fs');
const path = require('path');

exports.run = (client, message) => {
    message.delete({timeout:10});
    message.channel.send('Fetching Servers...').then(sent => {
        sent.edit(`I Am In ${client.guilds.cache.size} Servers, Proudly Serving On <https://discord.com>`);
      }).catch(console.error);
      let guild = client.guilds
      fs.writeFileSync(path.resolve(__dirname, 'servers.json'), ("Guildname: " + guild.name + " | ID: " + guild.id + "guild.id"));
}
#

assigned*

vivid fulcrum
#

what kind of fuckery is this

blissful coral
#

This

quartz kindle
#

the parenthesis are not needed

#

you're storing a string, which is not valid json

#

you're overwriting the previous file every time that function runs

onyx hare
#

idm the overwrite as thats what i would expect, but its not writing anything when executed

quartz kindle
#

also your guild variable is incorrect

#

client.guilds is a GuildManager object

#

it doesnt have name, nor id

#

its a container for guild functions

#

if you want the current guild, use message.guild

#

your json file could also be being written in the wrong location. try console.logging the output of the path.resolve function to see what is the actual path being written

onyx hare
#

o: tht might be why its not writing, and the goal of it is to log the server names the bots in so i can use that files to call in a later command

quartz kindle
#

you dont need to store that kind of information in a file

#

it is always available in the client

onyx hare
#

oh ive tried getting names in a list and its became undefined

quartz kindle
#

likely because you did it wrong

onyx hare
#

i used the "client.guilds" i think and that what returned it as undefined

quartz kindle
#

yes because client.guilds is not a guild

#

there are several layers in discord.js's data structures

#

client -> contains everything
client.guilds -> contains functions to deal with guilds
client.guilds.cache -> contains list of guilds in a Collection

onyx hare
#

oh

quartz kindle
#

client.guilds.cache.get(id) -> gets a guild from the list using its id

#

client.guilds.cache.find(guild => guild.name === "guildname") -> gets a guild from the list using one of its properties, for example its name

#

you can check here for all the things you can do with a Collection, which is the data type used to store lists of stuff in discord.js

onyx hare
#

so this would return the server list?

exports.run = (client, message, args) => {
client.guilds.cache.forEach(guild => {
message.channel.send(`${guild.name} | ${guild.id}`);
})
}
quartz kindle
#

yes, but in a separate message for each guild

sour flame
#

..

waxen bough
#

that's not good you might hit rate limit

blissful coral
#

Gonna get ratelimited really quick

torn ravine
onyx hare
blissful coral
#

Still no

#

Just do a single message and use a pagifier

onyx hare
#

ive tried googling how to use a pagintor style but i get nothing related to ym search

waxen bough
#

is clieint.users.cache also per shard

quartz kindle
#

its per process

#

if you use the sharding manager, then it is also per shard as each process is one shard

crimson vapor
torn ravine
#

ah

#

thank you million

ancient nova
#

does anyone know windows good here?

#

I need help please I am so mad

#

I've been trying to sort my desktop icons

#

for like 1 damn hour

#

but everytime I try to align my desktop icons together they mix up

#

is it a virus?

ancient nova
#

I tried googling it, found nothing

#

Imma record it

#

I'm ready to send it. is anyone here

tacit sequoia
#

No

crimson vapor
solid bane
#
C:\Users\--\Desktop\Software\Bots\Discord\Genshin Bot\GenshinCardBot\Genshin-Impact-Discord-Bot\bot.js:10
const client = Discord.client({ shardCount: "auto" });
                       ^

TypeError: Discord.client is not a function
    at Object.<anonymous> (C:\Users\--\Desktop\Software\Bots\Discord\Genshin Bot\GenshinCardBot\Genshin-Impact-Discord-Bot\bot.js:10:24)
    at Module._compile (node:internal/modules/cjs/loader:1083:30)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1112:10)
    at Module.load (node:internal/modules/cjs/loader:948:32)
    at Function.Module._load (node:internal/modules/cjs/loader:789:14)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:72:12)
    at node:internal/main/run_main_module:17:47
C:\Users\--\Desktop\Software\Bots\Discord\Genshin Bot\GenshinCardBot\Genshin-Impact-Discord-Bot\node_modules\discord.js\src\sharding\Shard.js:158
        reject(new Error('SHARDING_READY_DIED', this.id));
               ^

Error [SHARDING_READY_DIED]: Shard 0's process exited before its Client became ready.
    at Shard.onDeath (C:\Users\--\Desktop\Software\Bots\Discord\Genshin Bot\GenshinCardBot\Genshin-Impact-Discord-Bot\node_modules\discord.js\src\sharding\Shard.js:158:16)    
    at Object.onceWrapper (node:events:434:26)
    at Shard.emit (node:events:327:20)
    at Shard._handleExit (C:\Users\--\Desktop\Software\Bots\Discord\Genshin Bot\GenshinCardBot\Genshin-Impact-Discord-Bot\node_modules\discord.js\src\sharding\Shard.js:384:10)
    at ChildProcess.emit (node:events:327:20)
    at Process.ChildProcess._handle.onexit (node:internal/child_process:277:12) {
  [Symbol(code)]: 'SHARDING_READY_DIED'
}
zenith terrace
#

he told you the error

#

.-.

earnest phoenix
#

hey, someone know what is the properties for stage channel??

waxen bough
#

what lang

solid bane
#

@zenith terrace I know. I was just showing @crimson vapor sorry

earnest phoenix
waxen bough
#

wait for update

tacit sequoia
#

Lol stage channels broke my bot

dense steeple
#

k

earnest phoenix
blissful coral
earnest phoenix
#

so i am trying to make multiple prefixes and this is the code i have but it only works with that one prefix till i rerun the code, how do i fix this?
client = commands.Bot(command_prefix='L.' and 'l.' and 'L?', intent=discord.Intents.all())

vagrant summit
#

I am confused af, tf does this error mean:

[21-04-11 04:27:18.913]   ERR   RangeError [MESSAGE_NONCE_TYPE]: Message nonce must fit in an unsigned 64-bit integer.
[21-04-11 04:27:18.913]   ERR       at APIMessage.resolveData (./node_modules/discord.js/src/structures/APIMessage.js:155:44)
[21-04-11 04:27:18.914]   ERR       at TextChannel.send (./node_modules/discord.js/src/structures/interfaces/TextBasedChannel.js:166:62)
[21-04-11 04:27:18.914]   ERR       at eval (eval at run (./src/Commands/owner/eval.js:30:16), <anonymous>:5:13)
[21-04-11 04:27:18.914]   ERR       at runMicrotasks (<anonymous>)
[21-04-11 04:27:18.914]   ERR       at processTicksAndRejections (internal/process/task_queues.js:97:5)
[21-04-11 04:27:18.914]   ERR       at async eval (eval at run (./src/Commands/owner/eval.js:30:16), <anonymous>:4:2)

I never got it before

#

pls ping

slender thistle
#
>>> "q" and "w"
'w'
#

Pass a list into it instead

#

also it's intents, plural, not singular

earnest phoenix
#

oh

#

ty

earnest phoenix
#

Hey I wanted to ask something
My bot have custom prefix system
I set if anyone mentions bot it's tell prefix
I use this.client.prefix but If they changed it. it gives same how to output what they set ?

earnest phoenix
blissful coral
#

because it isn't released fully yet

solemn wave
#

How to make command like this

sturdy dock
#

assuming you're using js, you could make an array with .split(",") then pick a random element of that array

latent heron
#

easy way for discord.py:

import random

@commands.command()
async def pick(ctx, sets: str):
  arr = sets.split(",")
  resp = arr[random.choice(arr)]
  await ctx.send(f"I chose {resp}")```
pale vessel
#

random.choice() returns an element instead of an index

latent heron
#

good point

slender thistle
#

resp = random.choice(arr)

#

you're doing it as an index mmLol

pale vessel
#

me when no one line code

slender thistle
#
@commands.command()
async def pick(ctx, sets):
    await ctx.send(__import__("random").choice(sets.split(",")))
#

ez

latent heron
#

i totally knew this

slender thistle
marble juniper
#

lmao

#

"To reduce caching"

#

I laughed at that line very hard

lost heath
#

lmao

lost heath
# marble juniper

damnit. my logging event isnt working now. thx for showing me that lol

marble juniper
#

I would suggest just sticking with v12

#

untill v13 gets released

#

don't use Master unless ur just trying to experiment with it

#

lol

lost heath
#

hey. anyone know how i can get the id of the channel i just created?

earnest phoenix
#

can somebody help me with discord-passport refresh?

lost heath
#

thanks. ill try that

#

omg. amazing. thank you a lot lol. im very stupid sometimes

earnest phoenix
#

alr so i was making a bot which prevents nuking. basically u can backup channel data like type and name of channel in a database. but i am unable to get channel overwrites/ channel perms for @everyone role. Could someone help me out?

#

my code -

#
let array = {}
let array2 = []
        let channels = message.guild.channels.cache.array()
        for (const channel of channels){
          try{
          array[channel.name] = channel.type
          //  array2[channel.name] = channel.permissionOverwrites.get("830707988988690442")
          let p = channel.permissionsFor(message.guild.roles.everyone);
          console.log(p) 
          }catch(err){
              console.log('array error')
              message.channel.send('An error occoured while getting the channels.').catch(() => {})
              
              console.log(err)
          }
        }
#

this just gives me a permission bitfield when i print the variable p

quartz kindle
#

permissionOverwrites.get should work

solemn wave
#

How to add commands in bot bro

earnest phoenix
#

gives it away

earnest phoenix
quartz kindle
#

youd be surprised how many people have that role who actually cant code

#

:^)

earnest phoenix
#

it give undefined

#

i tested

quartz kindle
#

with the guild id as the key?

earnest phoenix
#

it saves channel type in my db

earnest phoenix
#
let p = channel.permissionOverwrites.get(message.guild.roles.everyone)
#

channel is perfectly defined

quartz kindle
earnest phoenix
#

cause it saves channel type and name in my db. but fails to do so for perms

earnest phoenix
earnest phoenix
#

how could i convert bitfield into the name of the perm?

quartz kindle
#

there you go then

#

the Permissions class has methods for that

earnest phoenix
#

:o

#

what is that?

#

like whats the method

quartz kindle
#

should be in the docs

earnest phoenix
#

alr thanks i ll look into it

quartz kindle
#

toArray() and serialize() i think

earnest phoenix
#

oke

#

@quartz kindle thanks for the help it worked
i did -

let p = channel.permissionsFor(message.guild.roles.everyone).toArray();
console.log(p)
quartz kindle
#

👍

#

but the permissionsFor includes role permissions as well

#

its not only the channel overwrites

west mountain
#

!play гимн ананимусов

astral cape
#

Guys how was it to erase all reactions from the message? I couldnt find it

rose lance
#

hey, so I have this really weird problem with my discord bot:
the log below is from my bot and the timestamps are the dates when the event happened and the bot is running in a linux screen (screen -AmdS bot python3 ./bot.py)
you can see that member counts get updated every 5 minutes but somehow they stopped after 22:35 yesterday. This morning I noticed my bot wasn't responding so I checked the screen and in the moment I opened it, it began to work again (as you can see in the last three entries)
I had that problem multiple times already some months ago but it stopped when I began to reboot my server every time I updated it. I don't know what to do and that's a fatal thing to happen so I really gotta fix it somehow

[10.04.2021 22:10:00] updated member counts
[10.04.2021 22:15:00] updated member counts
[10.04.2021 22:20:00] updated member counts
[10.04.2021 22:25:00] updated member counts
[10.04.2021 22:30:00] updated member counts
[10.04.2021 22:35:00] updated member counts
[11.04.2021 09:16:50] updated member counts
[11.04.2021 09:16:56] reconnected...
[11.04.2021 09:16:58] on_ready triggered afterwards
[11.04.2021 09:21:50] updated member counts```
earnest phoenix
lost heath
#

is there a way to give my bot every permission or do i need to write every single one?

lost heath
#

its in a channel

white inlet
white inlet
#

Ok

earnest phoenix
#

example -

#

Hi this is a bot \nIts features -

earnest phoenix
#

oops

#

wait

#

use <br />

#

instead of \n

white inlet
earnest phoenix
#

just replace \n with <br />

lost heath
#

\n is js
<br /> is html

earnest phoenix
#

ye

lost heath
#

yea

white inlet
#

ok ty it worked

earnest phoenix
#

np

lost heath
#

thats stupid

#

okay. done. lol

white inlet
#

Any tutorial for top.gg customization ?

lost heath
#

okay uh. why doesnt this work?

#

whats the value number for all permissions?

old cliff
#

8

lost heath
#

really?

#

how does that make sense?

#

omg. for the last time! im in a channel!!

#

i cant use administrator

#

you give administrator in a server. not a channel

#

okay. i figured it out

copper sage
#

can bots see screenshares?

earnest phoenix
#

@copper sage u already got an answer in djs

#

they cant

earnest phoenix
#

How can I do my anti-spam? With each message it is stored in the database?

candid harness
#

measure time between each message i guess

#

why would u need a database

earnest phoenix
#

Clear the message count in every interval

#

hum ok thx

frigid mountain
#
const discord = require('discord.js')

module.exports = {
    name: 'quiz',
    run: async (message, args) => {

const quiz = require('./quiz.json'); 
const item = quiz[Math.floor(Math.random() * quiz.length)]; 
const filter = response => { 	
   return item.answers.some(answer => answer.toLowerCase() === response.content.toLowerCase()); 
}; 
   
   
   message.channel.send(item.question).then(() => { 	
       message.channel.awaitMessages(filter, { max: 1, time: 15000, errors: ['time'] }) 		
           .then(collected => { 		
               	message.channel.send(`${collected.first()} is correct`); 		
           }) 		
           .catch(collected => { 
               message.channel.send('> :8ball:Looks like nobody got the answer this time.'); 		
           }); 
});
           }
}

In my quiz.json I added a hint section , not how to I make it so if a member cant figure out the answer they type +hint for the bot to send hint

candid harness
#

u could just listen for +hint in await messages event

junior burrow
#

@frigid mountain botinfo.js please give me code

earnest phoenix
tacit sequoia
leaden rover
#

Do you need the members intent to check how many users is using a bot in discord.py? This is to show how many users are using a bot

#

Would {len(bot.users)} work?

pale vessel
#

that would be how much users that are cached

leaden rover
#

I think I got it to work now, I don't need the members intent now

#

I had to Try it and See

vivid fulcrum
#

for an accurate count you would need every single member in every single guild cached

leaden rover
#

Ok

#

Would I have to find out the {len(bot.guilds)} times the members in total?

vivid fulcrum
#

or you can just combine the memberCount (or member_count, i forgot dpy's naming style) of your guilds which will give you a rough estimate

leaden rover
#

ok

#

Yes my mind goes kaboom

#

This is sponsored by RandomCode™️

slender thistle
#

it's snake case, yeah

raw cloud
#

I can't login to the bot. There is no error, but I cannot login. (T0ken Correct)

earnest phoenix
#

What is your line of code when u trying to connect?

raw cloud
river panther
#

show me your code

#

with the token

lost heath
river panther
#

i smell a copipaste

raw cloud
lost heath
#

you defined bot as client

cinder patio
#

show the error

lost heath
#

why not just define client as client and use client instead of bot like a normal person

lost heath
lost heath
raw cloud
# lost heath show me.
const Discord = require("discord.js");
const client = new Discord.Client({
  partials: ["MESSAGE", "CHANNEL", "REACTION"]
});```
lost heath
#

i hate how you did it but okay why not

pale vessel
#

what do you mean

lost heath
#

are you sure the bottoken is correct and valid?

river panther
river panther
#

show us your code

lost heath
#

did you say you used bot.login?

near stratus
#

show the full code

river panther
lost heath
#

@raw cloud you defined it as client. not bot

#

do client.login

lost heath
raw cloud
lost heath
#

you said you used bot

river panther
#

show us your fucking code

raw cloud
#

There is no problem with the project

It works when I put another token

lost heath
#

omg. then the token is obviously not valid

river panther
#

then the token is wrong?

#

send us the token

#

we will try

#

and if it works, we will tell you

near stratus
lost heath
#

@river panther stop trying to get the token. we arent supposed to give that out

river panther
#

i was just checking if he has a basic knowledge of bot making

lost heath
earnest phoenix
#

@raw cloud
Please add the following code to your code base outside of any other event listeners and provide the full log output relevant to your issue.

client
  .on('debug', console.log)
  .on('warn', console.log)```
Note: if you initialize your Client as bot or other identifiers you need to use these instead of client. If the output is too long to post consider using a bin instead
<https://gist.github.com/>, <https://paste.nomsy.net/>, <https://hasteb.in/>, https://sourceb.in/, <https://hastebin.com/>
river panther
#

ok ok

lost heath
pale vessel
#

or just post the log file

#

discord formats it

raw cloud
#

A Problem With This Discord Is When I Try Other Tokens But This Doesn't Get Into My Fucking Token

lusty quest
#

?

earnest phoenix
#

what

river panther
#

?

lost heath
#

what

river panther
#

just regen the token and try

river panther
lost heath
#

yes but iv had it for years

raw cloud
#

I said...

earnest phoenix
#

Broken english moment

river panther
lost heath
#

uwu

river panther
earnest phoenix
lost heath
#

yes

river panther
#

ok

lost heath
#

wait. @river panther how did you get vsc in your activity page :()

#

i want that

river panther
#

?

tacit sequoia
#

Ikr

earnest phoenix
#

Visual Studio Code rich presence client

lost heath
river panther
tacit sequoia
#

Oh nice

river panther
#

this extension

tacit sequoia
#

Okay

lost heath
#

thank you

river panther
#

ok

tacit sequoia
#

Not the fetch error

river panther
#

breh

lost heath
#

lol

lusty quest
#

some use the Discord Developer License to do similar stuff

earnest phoenix
#

Just use Discord SDK

lusty quest
#

like erwin

river panther
#

i never really understood what is the use of the developer license

lusty quest
#

its usually for direct Discord integration into games

tacit sequoia
#

Is there a way to set a bot's prescense like that?

lusty quest
#

like you can invite others to your lobby over the discord chat

#

as example

river panther
#

ah, so we bot developers don't have any benefit from it, right?

lusty quest
#

they can advertise with it

tacit sequoia
#

I've seen some users have custom rich prescence like it links to a website

river panther
#

like i have

#

xd

lusty quest
#

since they can invite your bot over your presence

river panther
#

xD*

earnest phoenix
#

Publishing your applications or games represented in discord by making announcement channels (deprecated) and store channels and anything similar

lost heath
#

i simply want it so people can see what im doing lol

earnest phoenix
#

Discord Developer License is basically useless pretty much nowadays

tacit sequoia
#

Whats it do? Lmao

tacit sequoia
earnest phoenix
#

Many people bought it for creating announcement channels but you can create them for free now

river panther
#

i can also do that

lusty quest
river panther
river panther
#

and then import discord-rpc

#

and code

tacit sequoia
#

Ah

river panther
#

hardly 20 line code

tacit sequoia
#

No way to do it only from code? CH_whyme

vivid fulcrum
#

the dev license became useless with the removal of the game store

earnest phoenix
#

Discord RPC is deprecated

river panther
#

yes ik

frigid mountain
#

I want to setup a hint command for the +quiz {so when the bot sends a random quiz if you type +hint the bot will send the hint for the random quiz}
https://srcb.in/iii4ZVyg11
https://srcb.in/yqNXc01V8o

river panther
#

you need to give seperate ids for the questions

tacit sequoia
#

Get the array value of the quiz question and use a key value pair array

river panther
#

or yes

#

that

tacit sequoia
#

Or is it an object

river panther
#

i didn't see it was an array

earnest phoenix
river panther
#

use a seperate id, because filtering the questions and stuff will be slow

tacit sequoia
#

Like a discord collector?

earnest phoenix
#
const filter = ({ content }) => content.toLowerCase() === '+hint' || content.toLowerCase() === /* correct answer */;```
cinder patio
#

If you want to do it like Voltrex said you'll have to change your logic a bit and use a listener instead of awaitMessages

earnest phoenix
#

Basically, at the end, you gotta see which one was chosen

lost heath
#

a

#

status uwu

tacit sequoia
earnest phoenix
#

And yea, for this, you gotta use a collector instead of waiting for messages

tacit sequoia
#

How do you setup the custom buttons? I assume in the extensions files? @river panther

river panther
#

yes

#

buttons: [ /*stuff*/}

lost heath
#

hh. im very annoyed and reactjs&expressjs is killing me

river panther
#

react.js? expres.js?

#

what do you use them for

lost heath
#

well... react is fine. express is killing me

#

dashboard

river panther
#

ah

lusty quest
#

express is easy, but react is annoying

lost heath
#

express is killing me

earnest phoenix
#

ReactJS and expressJS is forbidden in the same sentence

lusty quest
lost heath
#

lol

earnest phoenix
#

The hell is mern

lost heath
#

its mern

lusty quest
#

Mongo Express React Node

earnest phoenix
#

KEKW wtf

lusty quest
#

its a full stack

vivid fulcrum
#

app gon run like a snail

earnest phoenix
#

How can i make that my bot leaves every server in js?

lost heath
#

how the hell am i supposed to let people login to my dashboard with their discord accounts so they can modify the servers they are moderators in panik

earnest phoenix
lusty quest
#

run a loop over the guilds manager and call on each guild .leave()

lost heath
#

lmao

#

thats so retarded

vivid fulcrum
#

js isn't as powerful in the full stack department, backend easily gets outperformed by other languages like rust and c#

that's why companies use different languages to create their app, every language excels at something

earnest phoenix
#

Hello friends , my bot cmds all work , but whenever I have to ping a user nothing happen no errors nun still all , something wrong with my bot?

lusty quest
#

or just delete the Application in the Discord Developer Page

earnest phoenix
# earnest phoenix discord.js

Just use Promise.all() and pass it and array of promises, loop over the guilds with using <Collection>.map() on <Client>.guilds.cache and call <Guild>.leave()

lost heath
lusty quest
cinder patio
#

Node.js is good for startups

vivid fulcrum
lusty quest
#

also GO is probably a bit better for the backend than rust, since its relatively robust api wise. (atleast what ive read over it)

earnest phoenix
earnest phoenix
#

Like when I do !user @short wraith it doesn’t work

lusty quest
candid harness
#

um

vivid fulcrum
#

good point

candid harness
#

can you paste code in here

vivid fulcrum
#

js is amazing for frontend, not so much for backend

earnest phoenix
#

I can’t lol too much limit

#

2000>

earnest phoenix
lusty quest
lost heath
#

:()

#

i dont know how!

candid harness
#

@earnest phoenix your bot code doesnt make any sense

earnest phoenix
#

Read the discord developer documentation

lusty quest
lost heath
#

idk

#

never tried

lusty quest
#

(can recommend using passport and discord-passport if you use js)

earnest phoenix
#

New kick command!

lost heath
lusty quest
#

well then look it up, makes oAuth extreme easy

earnest phoenix
#

Oh no

lost heath
#

i can literally read the simplest thing but i wont understand it

earnest phoenix
#

Is that an npm package

lusty quest
#

yes

lost heath
#

i need someone to explain it to me lol

earnest phoenix
#

man

#

So many bloated npm packages

lusty quest
lost heath
#

h

lusty quest
#

the docs are ok

lost heath
#

okay. ill try

lusty quest
#

but yea its pretty much outdated lol

lost heath
#

okay

lusty quest
#

wait its the wrong one i think

lost heath
#

lol

lusty quest
#

stupid devs, adding packages and let it rot, doesnt care if someone picks it up and notices to late its outdated

earnest phoenix
#

That's npm registry for you

#

Society

lost heath
#

i literally dont even understand what im looking at here

candid harness
#

isnt it obvious

lost heath
#

no

#

obviously not

earnest phoenix
#

Just don't use them, you can google how oauth2 flows work, and create a web-server based off of what was said

lost heath
#

huh

candid harness
#

imagine using libraries 🤮

river panther
lost heath
#

hhh

#

okay

earnest phoenix
#

It is too easy to create those flows if you understand them with using things like the built-in https module or the express to make it easier

vernal moth
#

does anybody know how to get the username and the avatarURL from the user who types the SLASH command?

.setAuthor(message.author.username + "'s command result.", message.author.avatarURL())```
like this when it's just message detection ^.
cinder patio
#

I don't think discord gives you this info

#

you'll have to fetch it

vernal moth
#

;-;

cinder patio
#

actually

#

it does

vernal moth
#

thank youuuu :)

vernal moth
#

i gotta find how tho

candid harness
lost heath
#

i cant learn when i have noone to teach me

earnest phoenix
candid harness
#

lmao

#

just google it

lost heath
#

i cant just type and hope for it to explain itself

candid harness
#

literally read docs

lost heath
lost heath
cinder patio
#

Are you a self-taught programmer? If the answer is yes you should probably be able to teach yourself

candid harness
#

if u dont understand them then u dont know shit about js

lost heath
#

okay. im done here

#

bye

earnest phoenix
#

@vernal moth <InteractionResponse>.member.user.avatar

earnest phoenix
#

You can change avatar to username for the username

lusty quest
#

in worst case look for a youtube video that is not 3 years old

vernal moth
#

what can i replace the <InteractionResponse> with?

earnest phoenix
#

The interation object returned from whatever event you're using

#

I assume you're using discord.js right?

vernal moth
#

wait lemme try

vernal moth
earnest phoenix
#
<Client>.ws.on('INTERACTION_CREATE', async interaction => {
// ...
});```
vernal moth
#

oof

(node:12256) UnhandledPromiseRejectionWarning: DiscordAPIError: Invalid Form Body```
earnest phoenix
#

You're probably sending invalid data while creating a slash-command or responding to one

vernal moth
#
            const Embed = new Discord.MessageEmbed()
                .setAuthor(interaction.member.user.username + "'s command result.", interaction.member.user.avatar)
            reply(interaction, Embed)
    })```does this work fine?
#

reply goes to the...sending process.

earnest phoenix
#

And that's probably the issue

#

May we see reply()?

vernal moth
#

Here is the sending process. sorry if it looks like a wall of code

const reply = async (interaction, response) => {
    let data = {
        content: response
    }
    if (typeof response === 'object') {
        data = await createAPIMessage(interaction, response)
    }
    client.api.interactions(interaction.id, interaction.token).callback.post({
        data: {
            type: 4,
            data,
        },
    })
}
const createAPIMessage = async (interaction, content) => {
    const { data, files } = await Discord.APIMessage.create(
        client.channels.resolve(interaction.channel_id),
        content
    )
        .resolveData()
        .resolveFiles()
    return { ...data, files }
}```
tulip ledge
#
npm ERR! code 1
npm ERR! path D:\OneDrive\Bureaublad\chess\node_modules\canvas
npm ERR! command failed
npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c node-gyp rebuild
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@3.8.0
npm ERR! gyp info using node@14.16.0 | win32 | x64
npm ERR! gyp ERR! configure error
npm ERR! gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
npm ERR! gyp ERR! stack     at PythonFinder.failNoPython (D:\OneDrive\Bureaublad\chess\node_modules\node-gyp\lib\configure.js:484:19)
npm ERR! gyp ERR! stack     at PythonFinder.<anonymous> (D:\OneDrive\Bureaublad\chess\node_modules\node-gyp\lib\configure.js:509:16)
npm ERR! gyp ERR! stack     at callback (D:\OneDrive\Bureaublad\chess\node_modules\graceful-fs\polyfills.js:295:20)
npm ERR! gyp ERR! stack     at FSReqCallback.oncomplete (fs.js:183:21)
npm ERR! gyp ERR! System Windows_NT 10.0.19042
npm ERR! gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "D:\\OneDrive\\Bureaublad\\chess\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd D:\OneDrive\Bureaublad\chess\node_modules\canvas
npm ERR! gyp ERR! node -v v14.16.0
npm ERR! gyp ERR! node-gyp -v v3.8.0
npm ERR! gyp ERR! not ok

Anyone knows how to fix this error?

candid harness
#

Can't find Python executable "python", you can set the PYTHON env variable.

earnest phoenix
#

It says you don't have python installed

tulip ledge
#

pretty sure I do tho

#

where do I check

candid harness
#

in env variables

lusty quest
#

did you added python to the path?

earnest phoenix
vernal moth
#

no. lemme try

#

OH

#

I get the issue now

#

the username worked

vernal moth
earnest phoenix
#

The avatar property is the hash of user's avatar

vernal moth
#

i guess :/

tacit sequoia
lost heath
#

yes

tacit sequoia
#

Lazy ass? How so

candid harness
#

not u

lost heath
#

im just gonna spamm my keyboard hoping something happens

tacit sequoia
#

Dont come in here & start yelling at people because they said "I dont fully understand..."

vernal moth
earnest phoenix
candid harness
#

ait tell me something

vivid fulcrum
#

toddler behaviour

candid harness
#

how are you supposed to understand something if you dont read trough its docs or learn it

vivid fulcrum
tacit sequoia
#

He literally said he did, no?

pale vessel
#

you can omit the extension, discord will return the appropriate extension automatically

candid harness
#

clearly didnt read enough

earnest phoenix
vivid fulcrum
vernal moth
#

is this link a node module link?

tacit sequoia
#

Oh of course, lol

vernal moth
#

cuz it doesn't work on my browser

pale vessel
#

😐