#development

1 messages Β· Page 1976 of 1

boreal iron
#

I doubt that it has something to do with the activity at all

#

We just had that talk (again) yesterday

#

The people experiencing this issue are quite different, while I update the presence every 45s and have issues very rarely, others don't update their presence and the issue happens every now and then

subtle kiln
#

I can't be more sure. Every time that client.user.setActivity is called, it's immediately followed by no answers from the API for at least 4 seconds. So when interactions finally arrives they are older than 4s and are not valid anymore. I can observe that after EACH client.user.setActivity calls. When I remove it, the bug disappear.

rigid lark
#

(not sure if this is the right place) how do i transform this to an image? (it's a guild's icon id)

subtle kiln
boreal iron
#

I don't have Chrome and will never do

subtle kiln
#

Me neither, use chromium

boreal iron
#
  • In the case of endpoints that support GIFs, the hash will begin with a_ if it is available in GIF format. (example: a_1269e74af4df7417b13759eae50c83dc)
boreal iron
#

I update the presence every 45s

Also since I mentioned this I guess I would have more trouble when spamming interactions to test

rigid maple
#

Continues the code without waiting for the output of the function even though I use await

#

Function:

round cove
#

If my bot fails to give the user the role they react-role'd for, should the bot DM them about the fail saying Hey I don't have the correct permissions to give you this role alert the server's respective moderator etc etc?

#

Or would DMs be too annoying for those kind of fails.

subtle kiln
rigid maple
subtle kiln
round cove
#

Or users changing perms etc.

rigid maple
#

Why does the code continue without waiting for the return inside the function to return?

rigid maple
vivid fulcrum
#

because that's an event listener

#

the arrow function will get executed once the end event is fired

rigid maple
#

oh

vivid fulcrum
#

you need to wait for it

#

you can use promises for that

rigid maple
#

but i can't wait for it

heavy marsh
#

Does anyone know a good voice package for v13

#

as @discordjs/voice is deprecated

cinder patio
#

What the fuck is going on? Am I going insane or is git fucking up everything? Little changes from previous commits get deleted???

#

I think I'm losing my sanity

subtle kiln
#

we all are

#

it's programming after all

earnest phoenix
#

is ```js
if(!array.includes(arraytwo))

#

with "!"

sudden geyser
#

Do you want to check if an array contains the same elements in another array?

#

You can use the !, but you can't use .includes like that since it's for actual elements (e.g. if "e" is in alphabet, not if vowels is in alphabet)

#

You can use .every if you want to make sure every element is a subset

rigid maple
#

what can I do ?

sudden geyser
#

That's because you're passing a function that'll probably be called some time in the future.

#

Not immediately, but some time later.

#

So there's no guarantee gender will receive a value by time you use it in other parts of your code.

rigid maple
#

there is actually a guarantee that gender will get a value

#

sendFiletoWeb function definitely returns a value

sudden geyser
#

It doesn't look like it'll receive one in time

rigid maple
#

So is there a way to fix this?

#

this function combines audio files and converts them to wav format

sudden geyser
#

Yeah, you could signal response with promises, for example

rigid maple
#

then i have to pass this file to sendFiletoWeb function so i can get the gender

sudden geyser
#

For example,

function appendFiles() {
  if (!chunks.length) {
    return new Promise((res) => {
      outputStream.end(async () => {
        let gender = await ...;

        res(gender);
      })
    });
  }

  // ...
}

// This is fancy for promises.
appendFiles().then((gender) => doStuff(gender));
rigid maple
#

What is the doStuff function?

sudden geyser
#

Nothing special.

#

It's just a demo. It could be anything, like console.log

#

What's important is gender will have the value from let gender = await ...;

rigid maple
#

understood thanks

earnest phoenix
#

why

#

it worked before

#
let find = await cardss.items.find(item => item.name === card.name)
^
TypeError: Cannot read properties of undefined (reading 'find')
at Object.run (/workspace/commands/user/card.js:33:34)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
#

maybe cardss is undefined/null

#

but it worked fine

rigid lark
#

How do I check if my permissions in a guild contains admin (0x8)? example: 2147483647

tulip ledge
#

try logging them

rigid maple
heavy marsh
#

Why ...

- TypeError: o is not a function
sudden geyser
#

what is o

heavy marsh
#
connection = joinVoiceChannel({
                      channelId: message.member.voice.channel.id,
                      guildId: message.guild.id,
                    });
#

I dont known where 0 is

rigid maple
sudden geyser
sudden geyser
rigid maple
#

I assigned the gender variable to the value from the function

#

"Erkek"

#

but it doesn't expect the value from sendFiletoWeb function

heavy marsh
sudden geyser
#

what do you mean by "expect the value from sendFiletoWeb"? it looks like it logged fine. maybe at .then((gender) => console.log(gender)) is the issue, but that looks correct given res is called. Since that log did show a value, it looks correct.

heavy marsh
rigid maple
#

I'm using google translate
That's why I can't say exactly what I want to say

simple stump
#

If I have:

{
  "0": {
    match: {
      id: "i like cows"
    }
  },
  "1": {
    match: {
      id: "i like cats"
    }
  },
  "2": {
    match: {
      id: "i like animals"
    }
  }
}

How would I loop through the JSON data? I can't loop through it normally since data contains strings of numbers, not arrays.

for (var i = 0; i < data.length; i++) {
  // Do something with data[i].match.id
}

I'm working with Challonge API, but this is a general JavaScript question I guess. This is my code:

cha.matches.index({
    id: tourneyID,
    callback: (err, data) => {
      // Should be able to get the match ID based on whether the participant ID atches.
    }
});
heavy marsh
rigid maple
tulip ledge
cinder patio
#

It's in, not of

simple stump
#

Thank you πŸ‘

tulip ledge
#

I always use of

#

kek

simple stump
#

Huh. It says that data isn't iterable.

      for (const key of data) {
        let value = data[key];
        console.log(value.match);
      }
/home/container/index.js:576
      for (const key of data) {
                        ^

TypeError: data is not iterable
    at callback (/home/container/index.js:576:25)
spark flint
#

background-image: url("https://picsum.photos/1920/1080"); how to change that with js

#

the class name is bgBlur

tulip ledge
simple stump
#

ah. Ty

fiery stream
#
import dotenv from "dotenv";

dotenv.config();

class Tempesta extends Client {
  constructor() {
    super({
      intents: [
        "GUILDS",
        "GUILD_MESSAGES",
        "GUILD_MEMBERS",
        "GUILD_INTEGRATIONS",
      ],
    });

    this.login(process.env.TOKEN);
  }
}```
#

how do i run that class without exporting it

sudden geyser
#

Use it like any other class? Create an instance of it?

const bot = new Tempesta();
#

And make sure you require whatever file uses that class.

fiery stream
#
class Tempesta extends Client {
  constructor() {
    super({
      intents: [
        "GUILDS",
        "GUILD_MESSAGES",
        "GUILD_MEMBERS",
        "GUILD_INTEGRATIONS",
      ],
    });

    this.login(process.env.TOKEN);
  }
}

new Tempesta();``` anyway to run it without new tempesta();
sudden geyser
#

Well, what do you mean by "run" in this context?

#

You want to "make it like a module", but not export it?

#

Which is how modules are used.

fiery stream
#

actually nvm im not sure yet

woeful pike
#

90% of the classes people who ask questions in this channel write here don't need to be a class

#

if you have a class with just a constructor or a constructor + 1 method, your class is doing nothing

wheat mesa
#

Classes in js/ts are usually more or less meant for tracking state within an object, since everything else can just be done with a function more easily

#

Just make a function called start or something and have it do the work for you

dry imp
#

damn

wheat mesa
#

best formatting ever

earnest phoenix
dry imp
#

indentation moment

sudden geyser
#

I better not be the only one to immediately gaze away from code formatted like that

#

our eyes are programmed like that

earnest phoenix
#

How exactly does passport attach the user prop to the session?

#

is it just
<Request>.session.passport.user = {...}

fiery stream
#

why am i getting that error

wheat mesa
#

can you post the snippet of code

#

it's difficult to see what's before it

sudden geyser
fiery stream
#

it goes both way if i do semi colon it asks me to use :

sudden geyser
#

then can you show your code but without that hovering thing in the way

#

pretty sure the issue is the colon but might as well see

fiery stream
#

forget about it lol

#

that was my side project either way

#

btw is quart built on top of flask ?

sudden geyser
#

I don't think it uses Flask as a dependency

#

but it does expose the same api structure

fiery stream
#

hmm i see

#

btw you know how to make a local callback request from discord dashboard

fiery stream
#

this aint working for me

sudden geyser
#

You can use it like Flask

fiery stream
#

wym

fiery stream
sudden geyser
#

Referring to Quart

fiery stream
#

ohh btw you know how to do a redirect uri

sudden geyser
#

No

fiery stream
#

ohh alright ig ill figure it out

elder jewel
#

all slash commands on my bot are just gone now

#

changed nothing

#

just disappeared

#

help

wheat mesa
#

Thanks for providing context

green kestrel
#

yay got my http client working, and sending multipart multiple attachment πŸ˜„
https://cdn.discordapp.com/attachments/825411104208977952/941142977022156880/unknown.png

    dpp::multipart_response multipart = dpp::https_client::build_multipart(
        "{\"content\":\"test\"}", {"test.txt", "rick.jpg"}, {"ABCDEFGHI", dpp::utility::read_file("rick.jpg")}
    );
    dpp::https_client c("discord.com", 443, "/api/channels/907951970017480707/messages", "POST", multipart.body,
        {
            {"Content-Type", multipart.mimetype},
            {"Authorization", "Bot " + token}
        }
    );
#

decided to replace the http library im using in my lib with something simpler i can maintain, e.g. my own code.... cant maintain a third party header only lib or debug it 😦

slim heart
#

How can i ge that --config option into a docker compose?
$ docker run --name some-mongo -v /my/custom:/etc/mongo -d mongo --config /etc/mongo/mongod.conf
i'm not sure what option if any compose exposes for it

green kestrel
#

that syntax def needs a factory tho

#

@slim heart no way to pass it into the container via env?

slim heart
#

no clue

#

the docs on it are terrible

green kestrel
#

either that or have a shell script in your container that launches mongo, and the shell script as the init of the container

#

that shell script can have the --config parameter

slim heart
#

well yea

#

i can just make a Dockerfile if i wanted to

#

but im hoping to just keep it in the docker-compose if i can

fiery stream
#

How can you find the mem usage on python project?

craggy pine
#

Is there a way to remove all buttons from a message?
components: = row

I assumed I could just do row.components = [] then just edit the msg with it being an empty array but it does say components[0] is a requirement.

#
"components[0].components: This field is required",
earnest phoenix
sudden geyser
craggy pine
craggy pine
hybrid cargo
#

Isnt that the same what klay asked okeh

craggy pine
#

I mean. Also true.

#

But I was doing something like..

#
curPage.edit({embeds: [pages[page]], components: [row]})

But it just makes sense doing components: []

#

smooth brain moment

hybrid cargo
craggy pine
#

Ya was just a simple "press button -> remove all buttons, keep message" thing

#

wasn't thinking too smart with that question

hybrid cargo
#

ahh alr

fiery stream
#

Is there a python package for something like canvas for node?

lyric mountain
#

Probably, all langs have some kind of graphical lib

fiery stream
#

Python got tkiner something like that but its for gui

#

Not like for image

lyric mountain
#

By graphical I mean rendering images, not GUI

fiery stream
#

Yeah ik but i cant seem to find any :/

lyric mountain
#

Idk what do u mean "couldn't find any"

#

Just type "python drawing lib"

fiery stream
#

Well i didnt know what to search for something like that lol

vivid fulcrum
#

πŸ˜’

#

keywords from your actual message

pale vessel
#

use πŸ’Š

fiery stream
pale vessel
#
fiery stream
#

Pill as in Pillow lol

#

N is that the best one out there ?

#

Im guessing it is the best one looking at the number of downloads

pale vessel
#

yes it is

crimson vapor
#

pillow as in body pillow?

fiery stream
#

Cant tell if that’s a genuine question or you just messing with me

quartz kindle
#

pill as in medicine

vivid fulcrum
#

...yeah... medicine

earnest phoenix
#

drugs

lament rock
#

based and red pilled

#

or is it blue pilled all the zoomers say

#

idk

dry imp
#

tf is bluepilled

lament rock
#

someone on reddit says:

Redpilled: Describes someone who is seen to be, or who thinks themselves to be awakened to the truth of reality and the way of the world.

Bluepilled: Describes someone who is seen to be ignorant of the way of the world, or who chooses an insular perspective of life.

#

zoomers are weird

dry imp
#

bro im boomer even though im zoomer

slender thistle
#

@quartz kindle Figured you might be the go-to guy for this

JS
I'm currently using array.reduce to get values of specific keys in an array of objects and combine them. Is this by far the most optimized way, or is there something else I can do?

split hazel
#

don't think you'll get any better performance not using it

slender thistle
#

What about a for loop?

split hazel
#

that's probably how reduce works under the hood, a simple for loop which calls the function you provided with two elements and a sum

split hazel
#

but yeah Tim will know more about this

cinder patio
#

AFAIK reduce uses a special algorithm that I forgot the name of

#

so it's should be faster than a for loop

split hazel
#

it all depends on how you implement the reduce method you pass to it + size of data

cinder patio
#

hence "should". for loops are part of the control flow and it may get optimized by the JIT compiler, while reduce probably doesn't

split hazel
#

js is really confusing with benchmarks

cinder patio
#

mainly because of JIT optimizations. That's why benchmarking doesn't really matter that much unless the numbers are drastic

#

As long as the time / memory complexity is the same you shouldn't be worried

split hazel
#

on bigger data those numbers can definitely become noticeable

cinder patio
#

if the time complexity is the same I doubt there would be too big of a difference

woeful pike
#

if you're worrying about micro-optimizing loops in js you've already gone down a dark path

split hazel
#

I find criticising performance and finding improvements even if it is tiny to be a good habit

#

though im not one to speak i optimise things in terms of clock cycles not milliseconds πŸ’€

cinder patio
woeful pike
#

uhh what

#

source: dude just trust me

#

a js engine has the ability to optimize expressions too. These optimizations don't take place on the source code level

#

there's nothing that makes an if statement inherently faster than ternaries. The implementation might be different but statement vs expression has nothing to do with it

#

they're also not only ahead of time either. V8 will optimize and de-optimize certain parts of your code during execution depending on different factors

woeful pike
split hazel
#

yeah it depends on the environment

#

besides optimising an interpreted language too much won't usually lead to expected results

woeful pike
#

mfw im asking about branchless programming in a language with 300 levels of compiler abstractions

earnest phoenix
#

i don't even know how reduce works

slender thistle
#

starting value
start loop
starting value += value
return starting value

pale vessel
#

real and valid python code

quartz kindle
#

meanwhile im spending days microbenchmarking my serializer

#

with multiple ways of doing the same thing depending on the size of the data

#

nothing beats for loops for small data, except a gazillion ifs

#

and bigjnts are stupidly slow

#

also math.pow and the ** operator are both stupid slow

split hazel
#

I've never needed to use powers in code

#

the closest to that I needed to use is bit shifting which is very fast

#

did I forget to mention bit shifting is a native instruction in the CPU architecture that takes less than a single clock cycle to complete

quartz kindle
#

yes bitshifts are fast, but they are terribly slow on bigints

#

and in js shifting is limited to 32 bit on non-bigints

earnest phoenix
#

everything in js is slow ain't it

quartz kindle
#

just bigints

#

and powers

#

and TextEncoder

earnest phoenix
#

how much of mdn have you memorized

quartz kindle
#

idk

#

lmao

#

its not on purpose

cinder patio
quartz kindle
#

same way as messagepack

#

different format specs

#

more efficient

cinder patio
#

is it open source?

quartz kindle
#

not yet

#

gonna release soon

#

example:

{
  int: 40510349,
  float: 26107.14072,
  boolean: false,
  null: null,
  string: 'kjcjtegkfptayfvxhpoh',
  string2: 'uqmtfxykba',
  emptystring: '',
  zero: 0
}
``` this object takes 145 bytes in json, 108 bytes in messagepack, 103 bytes in mine
#

and its twice as fast as JSON.stringify() on average

cinder patio
#

Interesting. I'm not really familiar with messagepack, does it keep the keys?

quartz kindle
#

no messagepack doesnt

#

it supports extensions tho

#

so the user can create a messagepack extension to store keys

slender thistle
#

Tim gonna rewrite JS into JF because the S stands for slow

cinder patio
#

yours doesn't too I assume?

quartz kindle
#

mine has built in support, disabled by default

#

also supports sharing context

#

so it keeps keys remembered across packs and unpacks

cinder patio
#

I see, that's cool

quartz kindle
#

also supports object references

cinder patio
#

So like, you have the same object in 2 places, one place is the original and the other just points to the original?

quartz kindle
#

yup

#

only works with actual references tho, doesnt work if its two different objects with the same content

#

ie js { a: {}, b: {} } vs ```js
o = {};
{
a: o,
b: o
}

#

second one will store the reference, first one will not

hallow oriole
#

my bot got denied how to appeal

modest maple
#

You dont

hallow oriole
#

does it have to have stuff on english

#

or it can be whole on other language

modest maple
#

well what did you get denied for

slender thistle
#

Curiousity time

modest maple
jovial nexus
#

How can i do that when i want to create a new document using a schema in mongoose, if i dont fill something it auto-fills it with, for example ""?
Im trying to do this something: { type: String, required: true, default: "" }, but keeps telling me ValidationError: Text validation failed: something: Path 'something' is required.

quartz kindle
#
{} === {} // false, two different objects

let x = {}
x === x // true, same object
#

it would be very expensive to transverse an object and compare every single property

#

but checking if its the same reference is fast

slender thistle
#

I see

quartz kindle
#

if its required, it cannot have defaults

#

defaults are only for optional things

sudden geyser
jovial nexus
#

Alright, thanks to both!

flat copper
#

is it possible to change .setFooter("//") to .setFooter({text : "//"})

without changing in every file

#

djs

cinder patio
#

You could overwrite the prototype for MessageEmbed

#

But it's better to just replace it in every file come on now

simple stump
#

How do you collect a response from a select menu?

          const row = new MessageActionRow()
              .addComponents(
                new MessageSelectMenu()
                  .setCustomId('select-' + otherDID)
                  .setPlaceholder('Select the winner')
                  .addOptions([
                    {
                      label: rows[0].name + ' won',
                      description: 'Select this if ' + rows[0].name + ' won.',
                      value: message.author.id,
                    },
                    {
                      label: rowse[0].name + ' won',
                      description: 'Select this if ' + rowse[0].name + ' won.',
                      value: otherDID,
                    },
                  ]),
              );
quartz kindle
simple stump
#

Ah just saw the djs guide ty

woeful pike
#

is there anything resembling keyword arguments in slash commands by any chance?

simple stump
#

For collectors, how would I collect a select menu without waiting?

  const filter = i => {
      i.deferUpdate();
  };

  message.awaitMessageComponent({ filter, componentType: 'SELECT_MENU', time: 60000 })
      .then(interaction => interaction.editReply(`You selected ${interaction.values.join(', ')}!`))
      .catch(err => console.log(`No interactions were collected.`));

I don't want to use a filter, but rather just wait for a response infinitely.

rigid maple
#

how can i wait for the result of event listener inside a function ?

quartz kindle
#

with a promise

rigid maple
#

i did but it doesn't work

#

1 second please

quartz kindle
simple stump
quartz kindle
#

then just use () => true

#

as the filter

simple stump
#

Okay. Thank you!

rigid maple
simple stump
rigid maple
#

this function, but without waiting for the output, it continues the codes in the folder where I use the function

earnest phoenix
#

how do I stop logging errors like this

quartz kindle
earnest phoenix
#

🧠 thank you

rigid maple
# rigid maple

here it doesn't expect the result even though I use promise

quartz kindle
rigid maple
#

74-75

quartz kindle
#

what does console.log(gender) log?

rigid maple
#

undefined

quartz kindle
#

what is chunks?

earnest phoenix
earnest phoenix
boreal iron
#

Unfortunately it is in 2022

simple stump
#
const filter = () => true;

  message.awaitMessageComponent({ filter, componentType: 'SELECT_MENU' }).then(interaction => interaction.editReply(`You selected ${interaction.values.join(', ')}!`)).catch(err => console.log(`No interactions were collected.`));

Also, upon selecting something from the menu it logs "No interactions were collected".

rigid maple
earnest phoenix
#

well that's fine
for polls, giveaways or other stuff you can have infinite listeners

earnest phoenix
simple stump
#

πŸ‘

simple stump
rigid maple
#

where I use the function comes before and the output is undefined

#

but the console.log() value inside the function comes later and the output is correct

quartz kindle
#

which one of them

#

you have many console.logs

#

i dont know which ones youre talking about

#

show your console output

simple stump
#

Ah.

Error [INTERACTION_NOT_REPLIED]: The reply to this interaction has not been sent or deferred.
    at SelectMenuInteraction.editReply (/home/container/node_modules/discord.js/src/structures/interfaces/InteractionResponses.js:138:48)
    at /home/container/index.js:256:107
    at processTicksAndRejections (node:internal/process/task_queues:96:5) {
  [Symbol(code)]: 'INTERACTION_NOT_REPLIED'
}
rigid maple
rigid maple
earnest phoenix
quartz kindle
earnest phoenix
quartz kindle
#

is this in your logs?

quartz kindle
#

without {} should work

rigid maple
quartz kindle
#

but is that in you logs?

rigid maple
quartz kindle
#

thats the problem

#

your promise only kicks in when chunks is empty

#

what about when chunks is not empty?

#

your function starts a bunch of things and returns undefined

rigid maple
#

yes after merging all files already console.log("Finished" )

#

I don't think there is anything wrong with that part.

quartz kindle
#

there is

rigid maple
#

because the function output is correct but when I use the function it jumps to other parts without waiting for the result

quartz kindle
#

because your promise only works if !chunks.length

simple stump
#

Well it looks like it defers, but nothing gets sent.

  const filter = (i) => i.deferReply();

  message.awaitMessageComponent({ filter, componentType: 'SELECT_MENU' }).then(interaction => interaction.editReply(`You selected ${interaction.values.join(', ')}!`)).catch(err => console.error(err));

No errors are logged either.

EDIT: When I delete the channel, the console gets spammed with:

Error [INTERACTION_COLLECTOR_ERROR]: Collector received no interactions before ending with reason: channelDelete
    at InteractionCollector.<anonymous> (/home/container/node_modules/discord.js/src/structures/Message.js:533:21)
    at Object.onceWrapper (node:events:514:26)
    at InteractionCollector.emit (node:events:406:35)
    at InteractionCollector.stop (/home/container/node_modules/discord.js/src/structures/interfaces/Collector.js:197:10)
    at InteractionCollector._handleChannelDeletion (/home/container/node_modules/discord.js/src/structures/InteractionCollector.js:206:12)
    at Client.emit (node:events:406:35)
    at ChannelDeleteAction.handle (/home/container/node_modules/discord.js/src/client/actions/ChannelDelete.js:30:14)
    at Object.module.exports [as CHANNEL_DELETE] (/home/container/node_modules/discord.js/src/client/websocket/handlers/CHANNEL_DELETE.js:4:32)
    at WebSocketManager.handlePacket (/home/container/node_modules/discord.js/src/client/websocket/WebSocketManager.js:345:31)
    at WebSocketShard.onPacket (/home/container/node_modules/discord.js/src/client/websocket/WebSocketShard.js:443:22) {
  [Symbol(code)]: 'INTERACTION_COLLECTOR_ERROR'
}
rigid maple
quartz kindle
#

no

#

the function terminates before it even starts

#

the rest of the function is executed asynchronously

rigid maple
#

when the function runs, the value of chunks is not empty

quartz kindle
#

exactly

#

if chunk.length exists and is bigger than 0, your function runs this:

#

and then returns undefined

#

there is nothing there to make the function wait

#

you create an "end" event listener, then return undefined because there is nothing else to do

rigid maple
#

it's not my intention to make the function wait here

rigid maple
quartz kindle
rigid maple
#

but the output of console.log(gender) value inside the function is correct

quartz kindle
#

yes its correct

#

the function is already terminated when you get there

#

because you dont make it wait

rigid maple
#

so what should i do

quartz kindle
#

if you want to make the function return the value

#

you have to make the function wait for the entire process

#

starting with the .on("end")

rigid maple
#

let me try

quartz kindle
#

also, why do you need chunks to exist outside the function?

rigid maple
#

can i use it like this 😳

quartz kindle
#

yes but not like that

#

you need to resolve a value, or it will wait forever

rigid maple
#

aaah this google translate is so bad

#

can I return anything ?

#

i changed it like this

quartz kindle
#

no

#

res(client.appendFiles())

#

otherwise the function returns "Finished."

#

not the result

rigid maple
#

okey I understood it

simple stump
#

I'm trying to collect the response to select menus, but the interaction gets deferred with no response.

  const filter = (i) => i.deferReply();

  message.awaitMessageComponent({ filter, componentType: 'SELECT_MENU' }).then(interaction => interaction.editReply(`You selected ${interaction.values.join(', ')}!`)).catch(err => console.error(err));

No errors are logged either.

quartz kindle
#

try const filter = (i) => i.deferReply() && true;

hexed garnet
#

Error handling request
Traceback (most recent call last):
File "/home/container/.local/lib/python3.8/site-packages/aiohttp/web_protocol.py", line 422, in _handle_request
resp = await self._request_handler(request)
File "/home/container/.local/lib/python3.8/site-packages/aiohttp/web_app.py", line 499, in _handle
resp = await handler(request)
File "/home/container/.local/lib/python3.8/site-packages/topgg/webhook.py", line 132, in _bot_vote_handler
self.bot.dispatch("dbl_vote", BotVoteData(**data))
File "/home/container/.local/lib/python3.8/site-packages/topgg/types.py", line 279, in init
super().init(**parse_vote_dict(kwargs))
File "/home/container/.local/lib/python3.8/site-packages/topgg/types.py", line 19, in parse_vote_dict
query_dict = {k: v for k, v in [pair.split("=") for pair in query.split("&")]}
File "/home/container/.local/lib/python3.8/site-packages/topgg/types.py", line 19, in <dictcomp>
query_dict = {k: v for k, v in [pair.split("=") for pair in query.split("&")]}
ValueError: not enough values to unpack (expected 2, got 1)

#

why does this happen?

#

i was expreimenting with /vote?info

whole glen
hexed garnet
#

@commands.Cog.listener()
async def on_dbl_vote(self, data):
member_id = data["user"]
#tquery = data['query']
#currency = qurey['currency']
channel = self.bot.get_channel(939966852157820999)
# if currency == {"TPET"}:
reward = random.randint(800, 1000)
embed = discord.Embed(title = "Thank you for voting!", description = f"<@{member_id}>, your reward for voting is: ||{reward}$TPET||")
embed.set_footer(text = f"Member ID: {member_id}")
await ecomoney.update_one({"id": int(member_id)}, {"$inc": {"bank": + int(reward)}})
await channel.send(embed=embed)
await channel.send(f"<@{member_id}>")
# elif currency == {""}:
# reward = random.randint(800, 1000)
# embed = discord.Embed(title = "Thank you for voting!", description = f"<@{member_id}>, your reward for voting is: ||{reward}$TPET||")
# embed.set_footer(text = f"Member ID: {member_id}")
# await ecomoney.update_one({"id": int(member_id)}, {"$inc": {"bank": + int(reward)}})
# await channel.send(embed=embed)
# await channel.send(f"<@{member_id}>")
print(f"Received a vote:\n{data}")

quartz kindle
whole glen
#

oh

simple stump
#

``

#
Error [INTERACTION_NOT_REPLIED]: The reply to this interaction has not been sent or deferred.
    at SelectMenuInteraction.editReply (/home/container/node_modules/discord.js/src/structures/interfaces/InteractionResponses.js:138:48)
    at /home/container/index.js:256:107
    at processTicksAndRejections (node:internal/process/task_queues:96:5) {
  [Symbol(code)]: 'INTERACTION_NOT_REPLIED'
}
#

Even though it defers

quartz kindle
simple stump
#

πŸ‘

simple stump
#

That works! Ty

candid bloom
#

Okay so I have been working with discord bot maker and I was wondering if it is possible to make a feature where people can create a voice chat then manage how many then after this they have full control via commands from the bot but they will be able to add people remove people set a limit change the name of the voice chat mute and deafen people and move people to their voice chat.

Is this possible also wanted to know if I am able to make like the bot automatically do things after a command. Like auto support for certain things.

earnest phoenix
#

don't use a maker then.Diy,Learn how to code and it will be much eaiser.The Platforms are really shady

sudden geyser
#

discord bot maker is fine

#

and bot makers in general since they make the process easier

lyric mountain
#

they tend to bite you back later on

sudden geyser
#

hence they're easy

#

for many people, what it can do outweighs what it can't do with the bonus of not having to learn an actual programming language

vivid fulcrum
#

my little idea of automating a chromium instance to totally not have a selfbot streaming

#

is not working out well

#

discord wipes the localStorage object from the Window

#

so you can't insert a token field to be logged in

#

trying to find a workaround

#

sure, i can input the login creds

#

but then you encounter a captcha

#

i'm going to get an aneurysm by the time i'm done with this

slender thistle
#

I'll set up an appointment with your therapist for you

modest maple
#

pithink Cant you just like, use the web app?

#

and then just manually log in first?

#

or do you want to automate that as well

vivid fulcrum
#

want it automated as well

modest maple
#

ah fairs

vivid fulcrum
#

i had a dumb idea to totally not have a movie streaming selfbot

#

so that's my motive right now

#

just run it and it worksℒ️

#

i think i'm going to skip over the login part and come back to it later

#

just want to see if it's possible to stream a movie

modest maple
#

probably

#

hypothetically its perfectly possible

split hazel
#

if the discord client can do it a bot definitely can freerealestate

#

self bots are the discord equivalent of the dark market

#

i love it

vivid fulcrum
#

they're more fun as well

#

nothing is documented so it's more challenging

dry imp
#

self bot is not the actual bot right?

split hazel
#

meh i just use an old version of djs which still supports user clients whenever i want to play around

split hazel
dry imp
#

....

vivid fulcrum
#

also another fun fact

#

users cannot send rich embeds anymore

split hazel
#

they're not doing too much to stop them

split hazel
eternal osprey
#

`` js

#
for (const key in de){
    console.log(de[key])
  }``` how do i only log this 20 times only?
split hazel
#

you mean run the loop 20 times?

eternal osprey
#

Like done in a for in, with a let variable

eternal osprey
vivid fulcrum
#

oh

split hazel
#

instead of using for in i would use a for i = 0 loop since you dont need to worry about implementing the i variable and increments yourself

#

plus its faster

eternal osprey
#

owh wait what

eternal osprey
quartz kindle
#
const keys = Object.keys(de);
for(let i = 0; i < 20; i++) {
  console.log(de[keys[i]])
}
#

or

split hazel
#

took the words right out of my mouth tim

#

or in this case code

#

and fingers

quartz kindle
#
let count = 0;
for(const key in de) {
  if(++count === 20) break;
  console.log(de[key])
}
eternal osprey
sudden geyser
#

Going crazy

for (const key of Object.keys(de).slice(0, 20)) {
  // stuff
}
quartz kindle
#

πŸ‘

#

funny how every time js releases a new feature, its slower than the old way of doing that feature

cosmic forum
#

Hey, if I had an object like so:

let lb = {"user1":355,"user2":45,"user3":124,"user4":567,"user5":12}

How could I "sort" it so that it would turn into:

{"user4":567,"user1":355,"user3":124,"user2":45,"user5":12}

(javascript)

quartz kindle
#

objects are unsorted, you cannot sort them

#

unless you convert them to array or Map

cosmic forum
#

hm, okay

quartz kindle
#

if you want to display it somewhere in a sorted way, you can sort the object entries

pearl trail
#
Object.fromEntries(Object.entries(lb).sort(([,a],[,b]) => a-b));
``` ![mmLol](https://cdn.discordapp.com/emojis/356831697385422848.webp?size=128 "mmLol")
quartz kindle
#

that basically does nothing lul

#

Numbers are ordered first, and they are ordered within themselves from smallest to largest as long as they are >=0 (see below for more details)
Strings come second, and they are ordered within themselves by insertion order
Symbols come last, and they are ordered within themselves by insertion order (note that we didn't use symbols in this example)

novel jetty
#

Can someone help me with this please?

quartz kindle
#

interactions dont have MessageComponentCollector

novel jetty
quartz kindle
lyric mountain
#

I mean, pure maps not maps backed by arrays

novel jetty
pearl trail
fiery stream
#

New js lib is so complicated πŸ₯²

vivid fulcrum
#

which new lib

round cove
vivid fulcrum
#

oh are they talking about djs

#

it really isn't lol

#

working with djs is like playing with legos

fiery stream
#

Yuh i find interactions so complicated

vivid fulcrum
#

everything that's intermediate and beyond in difficulty is done for you

#

i.e. collectors

fiery stream
#

Yuh i haven’t coded js for like 2 years n now I’m back at it is pretty much like whole new book to read

sudden geyser
#

then invest in finishing the book

#

can teach you a lot of good and bad

fiery stream
#

As of now im working on my py bot

#

With cool web page n shii

quartz kindle
quartz kindle
#

but the order is based on the resulting hash

#

or just keep two indexes, which is basically what Map does

#

one hash index for access, and one key index for order keeping

earnest phoenix
#

Hello my bot has 5,200 servers and 5 clusters, I create a MongoDB connection for each cluster (like first cluster connects to db then second cluster connects) is this wrong or should i just create one connection?

quartz kindle
#

how would you even create a single connection for all of them?

earnest phoenix
lyric mountain
quartz kindle
boreal iron
quartz kindle
#

well, techinically its still multiple connections over the same socket lmao

wheat mesa
#

Then make a driver for the socket smirk

#

It goes on and on

split hazel
#

hear me out

#

make a dedicated cluster that has the connection to the db

#

and the other clusters can send data to that cluster to contact the db

boreal iron
#

Which does require multiple connections to the database request handler

#

Not really much of a difference to multiple database connections

split hazel
#

i regret to inform you that you are wrong

lyric mountain
boreal iron
#

(β•―Β°β–‘Β°οΌ‰β•―οΈ΅ ┻━┻

whole glen
#

this command works in my server but crashes the bot in others and in dms, why?

lyric mountain
#

tsk tsk, deleting question is not cool

whole glen
#

i found answer

#

my self

lyric mountain
#

still, someone might have a similar question but too shy to ask

#

that's why stackoverflow works, imagine if people deleted solved questions

lyric mountain
#

that's an expected behavior, you should catch everywhere where things might fail

#

in this case, I imagine it's because the bot can't speak in the channel

whole glen
#

it can

#

and also dms

lyric mountain
#

then well, show the error

#

there's not much I can say when supplied with only 3 lines of code

whole glen
#

in dms, in server, and in my server

lyric mountain
#

channel is undefined

#

actually, it's null

#

why? bot cant see the channel

whole glen
#

if so it does not explain the dms but yes i think so

lyric mountain
#

well, that's what the error says

whole glen
#

the dm one should work then

lyric mountain
#

"should" is a bold assumption

#

user might have closed dms or blocked the bot

#

in which case it'd fail

#

add a check before you send the message

#

add a check before you send the message

whole glen
#

no it's my own dm

lyric mountain
#

add a check

whole glen
#

this is probably why it does not work in dms interaction.channel.send('Pong').then (async (resultinteraction) =>{

#

it says Cannot read properties of null (reading 'send')

lyric mountain
ember gust
#

hey so when my bot errors on something i want it to respond with an ephermal message with the error

#

how would i do this

#

pls ping with response cuz i go sleep thanks <3

boreal iron
#

That will let the interaction fail

#

Respond by using reply() on your interaction object

earnest phoenix
#

Anyone know best uptimer site ?

bright thorn
#

how can i convert [object Promise] in result

pale vessel
#

resolve the promise by awaiting it

bright thorn
#

how

#
app.post('/dblwebhook', wh.listener(vote => {

  let response = fetch(`https://discord.com/api/v9/users/${vote.user}`, {
    method: 'GET',
    headers: { Authorization: `OTM4Masdasto`}
})

  fetch(URL, {
    "method":"POST",
    "headers": {"Content-Type": "application/json"},
    "body": JSON.stringify({
       "content":`${response}`
     })

   })
   .catch(err => console.error(err));
  console.log(vote.user)
}))```
#

in this method how can i

lament rock
#

Look up async/await in js

earnest phoenix
bright thorn
#

Got it

feral aspen
#
if (interaction.isButton()) {
    switch (interaction.customId) {
        case "cookie":
            if (interaction.guild.id !== "GUILD_ID") return;
            break;
        default:
            return;
            break;
    };
};
#

How can I not return but break out of the if statement and continue the code?

cinder patio
feral aspen
#

I want to break out of the interaction.isButton() statement.

cinder patio
#

yes... remove the return in the default, actually you can completely omit the default

#

and put your code outside of the interaction.isButton() if statement

#

You can completely remove the switch if that's the entire code:
if (interaction.isButton() && (interaction.customId === "cookie" && interaction.guild.id !== "...")) return

earnest phoenix
#

How can I fix this?

dark pewter
feral aspen
#

I've never seen labels before.

earnest phoenix
#

because they're useless in js

#

emphasis on in js so kuuhaku doesn't give me a five hour lecture on their importance in java

feral aspen
earnest phoenix
#

break an if statement without returning the entire function

feral aspen
feral aspen
lyric mountain
#
label1:
if (condition) {
  if (guard_condition) break label1;

  //code
  //code
  //code
  //code
}
//if guard_condition evals true, code will skip the rest of the block and continue here
//code
//code
//code
#

not only ifs, u can break any scope

woeful pike
#

pls for the love of god don't ever use this

cinder patio
#
if (condition && !guard_condition) {
    // code...
}

Like a sane person pls

earnest phoenix
lyric mountain
#

topggLikeThis unnecessary indentation level

#

also how would you solve this case:```js
label1:
if (condition) {
//MUST RUN
//MUST RUN
//MUST RUN

if (guard_condition) break label1;

//code
//code
//code
//code
}
//if guard_condition evals true, code will skip the rest of the block and continue here
//MUST RUN
//MUST RUN

brittle abyss
#

I am self hosting my bot, but it gets disconnected/ reconnected for no reason.
Is it common? Any recommendations on how to tackle this problem?

lyric mountain
#

depends

#

discord does fart sometimes

#

but if ur getting disconnected very frequently there might be an issue

brittle abyss
#

The problem only occurs with a private counting bot, even though I have a recursive function to run the bot client in case it crashes.

lyric mountain
#

bot client in case it crashes
WHAT crashes?

#

the bot, as in the code still run

#

or the code itself?

civic scroll
lyric mountain
#

also u cant return a label

civic scroll
#

you can return evil corp

lyric mountain
brittle abyss
# lyric mountain or the code itself?

This might sound vague but basically If any exception got raised when running the bot launcher.
The script will sleep for a minute then try to restart the whole process. [The errors are logged though.]

quartz kindle
#

^

civic scroll
brittle abyss
civic scroll
lyric mountain
#

ye, that's no log at all

#

like, where's the stacktrace?

split hazel
quartz kindle
#

show the code that prints that

lyric mountain
feral aspen
#

Holy.. you guys still arguing. πŸ˜‚

civic scroll
#

@lyric mountain you know what

lyric mountain
#

i don't know

civic scroll
#

you go help me doing codewars

split hazel
#
loop1:
for (let i = 0; i < 5; i++) {
    loop2:
    for (let j = 0; j < 10; j++) {
        break loop1;
   } 
} 

:)

lyric mountain
#

codewars?

woeful pike
#

just use functions you evil villains

quartz kindle
#

cod wars

woeful pike
#

heheHyun I will make this code as difficult as possible to understand

civic scroll
#

i will just use js

civic scroll
#

paste in ts

#

and apply nocheck

brittle abyss
lyric mountain
#

does it happen frequently?

civic scroll
#

it's python so idk

brittle abyss
#

No, 3 times a day mostly.
Worthy to mention that on_ready does not get called though and the bot do not go offline.

split hazel
lyric mountain
#

on_ready probably shouldn't get called on reconnect anyway

#

there's an on_reconnect

brittle abyss
lyric mountain
split hazel
#

true

#

but it adds clarity

lyric mountain
#

but ye, for escaping nested loops it's very useful

quartz kindle
#

if you get an on_resumed everytime you get an on_disconnect, then its normal

lyric mountain
#

@solemn latch

civic scroll
#

@solemn latch

lyric mountain
brittle abyss
split hazel
lyric mountain
#

banning nitro scammers

split hazel
#

@quartz kindle by the way make sure to participate in the next code wars next time

quartz kindle
#

what code wars, i suck at them

#

they keep asking to solve weird shit like ciphers and cryptography

lyric mountain
#

The Cod Wars (Icelandic: ÞorskastrΓ­Γ°in; also known as LandhelgisstrΓ­Γ°in, lit. 'The Wars for the Territorial Waters'; German: Kabeljaukriege) were a series of 20th-century confrontations between the United Kingdom (with aid from West Germany) and Iceland about fishing rights in the North Atlantic. Each of the disputes ended with an Icelandic vict...

quartz kindle
#

nice

lyric mountain
#

iceland and uk fighting for fish

split hazel
#

bios is better than uefi

quartz kindle
#

agreed

feral aspen
#

What do you call this function?

(() => {
    console.log("Hi")
})();
modest maple
#

bad code

sudden geyser
#

An IIFEβ€”immediately invoked function expression

earnest phoenix
sudden geyser
#

It's just useless in this context

pearl trail
#

but we can use it to run await VeryCool

vivid fulcrum
#

i hate doing desktop apps

#

the worst part of it is deciding which framework to go with

sage bobcat
#

One message removed from a suspended account.

vivid fulcrum
#

cross-platform, performant, easy to work with - pick 2 😭

sage bobcat
#

One message removed from a suspended account.

vivid fulcrum
#

HEY

sage bobcat
#

One message removed from a suspended account.

vivid fulcrum
#

i left discord for a few months but i'm back now cause i'm in quarantine

#

i'll talk to you in general

sage bobcat
#

One message removed from a suspended account.

sudden geyser
split hazel
#

fun fact: hello world in powershell is Write-Host 'Hello world'

vivid fulcrum
#

or just 'Hello World' KEKW

modest maple
#

powershell can be very powerful tbh

#

way more powerful than shell script

split hazel
noble spruce
#

You can't add javascript in your topgg page?

spark flint
#

No

noble spruce
woeful pike
#

would be a huge security risk

noble spruce
#

Thank you

modest maple
#

dw

#

you can still track user IPs if you really want to

#

cuz lets face it, thats all we really use JS for now days verycool

round cove
#

No but I could steal your session Id and make request on your behalf if I wanted to.

#

Assuming Top.gg hasn't dealt with CSRF issues.

modest maple
#

topgg doesn't deal with anything

#

other than the peepeepoopoo kid stuff

round cove
#

TBF I could make my site have a button that makes a put request to top.gg and assuming everything's stored in cookies it should work. iara_think_thonk

#

"Click to join support server" -> Nukes your bot page

split hazel
#

rumours from previous devs say topgg sells your data to google ads

round cove
#

I don't even know what data, it's all already there lol

woeful pike
#

wouldn't we at least need to show google ads for that lol

round cove
#

Right lmao

split hazel
#

maybe

#

what were those google ad trackers on the website before tho

woeful pike
#

we had banner ads before, we don't now because they suck

woeful pike
#

the tracking is just the ad provider's way of counting impressions, google doesn't give you control of that when you want to show ads on your site

split hazel
#

understandable

#

react amplitude do be initialized tho

woeful pike
#

it do be

round cove
#

Xet blog when taptaptap

woeful pike
#

soon

#

this is my last week before a 9 day vacation

#

I'll have time to write

split hazel
#

that dont look too good

round cove
#

Make sure to rest up king.

woeful pike
#

LMFAO

#

that's probably ken

round cove
#

Blame everything on Ken

split hazel
#

object Object will always have a special place in my heart from the counless times i tried to send an object in chat

#

what is chakra it looks cool

#

dont mean to make you panic but uh

split hazel
#

yeah its just a once in a time thing

spark flint
#

ah

#

nope mine just died

split hazel
#

lmao

spark flint
split hazel
#

also i think there should be an option to remove the gradient from the pages

#

dont know its just not doing it for me

#

maybe because of my screen size

woeful pike
spark flint
#

ahh alr

woeful pike
#

looks like I might have set it too low

modest maple
#

testing in prod moment

wheat mesa
#

I’m in need of people asking simple questions so I can continue procrastinating thanks

idle sail
#

Website is slow

wheat mesa
#

Good question

solemn latch
#

(I may be trolling)

wheat mesa
#

The noun is request, and the adjective describing it is http, therefore it’s an http request

solemn latch
#

oh perfect

#

thank you

wheat mesa
#

Np

solemn latch
#

I dont think a better answer exists tbh

wheat mesa
#

Exactly

#

Can’t get that kind of quality on stackoverflow

solemn latch
wheat mesa
#

Lmao

#

Ironically I’m sitting in a β€œweb design” class that has taught me nothing a 5 minute google search couldn’t teach me in the last 6 months

solemn latch
#

πŸ‘€

#

very exciting stuff

wheat mesa
#

Yup

#

Haven’t even started with js

#

Literally just html, small amount of css, and some graphic design stuff

solemn latch
#

πŸ‘€

wheat mesa
#

πŸ‘€

#

I took this class thinking I might actually learn something

#

I suppose I was wrong

solemn latch
#

sadly thats how it goes

wheat mesa
#

Yeah

#

My computer science class isn’t really useful either

#

It would be useful if I didn’t know anything beforehand but unfortunately it’s just things I’ve already learned

#

Hopefully my data structures course next year will be different

modest maple
#

unfortunately probably not

#

at least compared to what you run into in the real world

earnest phoenix
#

The only thing I learnt from my computer class is not to open Excel on a windows 7

round cove
#

People go into CS expecting to get a SE degree.

modest maple
#

yeah they tend to go "oh well I want to work in software"

#

and then they come out with a CS degree thinking they know everything about how SE works and what it involves

earnest phoenix
#

unpopular opinion
coding is the easiest job because there is an undo button

modest maple
#

when in reality they know nothing and their code quality and team work is awful

wheat mesa
#

Not an undo button for when you set the pacemaker to beat at 900bpm and not 90bpm

modest maple
#

Uni doesn't really encourage working as a team at all. It encourages a competing with your coworkers which is a really bad way to do SE

round cove
#

At least mine did that.

modest maple
#

I've had a bit of downtime at work recently after coming off a project so I've been cleaning up some software the interns wrote

#

and their code is just

#

bad

#

in so many levels

round cove
#

Right. Some places don't teach good practices.

modest maple
#

Code Quality? What's that?

#

oh but I created this linked list!

round cove
#

I'm so very much thankful I met amazing programmers at my uni. They helped me learn and guided a lot of us.

earnest phoenix
#

I'm so very much thankful tim exists

earnest phoenix
#

armful br??

#

armful br!?!?

modest maple
#

armful simp?

round cove
#

who

earnest phoenix
#

😠

round cove
#

unironically who

earnest phoenix
#

the 😠 was for chillfish

#

i am a new br

round cove
#

Congrats on trial. Good luck

earnest phoenix
#

tyty

round cove
#

You're obviously going to beat the record, right?

earnest phoenix
#

obviously

round cove
#

pat Good BR.

earnest phoenix
#

what else would i be doing

round cove
#

Not doing queue I guess.

earnest phoenix
#

my strat is to keep queue at sub quota so no other brs can reach quota trolla

round cove
#

Good luck 😏

earnest phoenix
#

ty

split hazel
#

jobs that require software engineers to have a computer science degree be like oooooaaa

#

i dont think you'll come out with the greatest quality of code

#

i dare say universities are largely a pointless money grab nowadays

#

all resources you need to get started on a topic are on the internet

#

there are also some great online tutors and classes for a small price compared to a degree cost

#

the only incentive to go to university is to get a "globally recognised degree"

woeful pike
#

computer science isn't programming. It's kind of ridiculous that one is seen as a pre-requisite to the other

split hazel
#

you actually have a point

woeful pike
#

if you wanna learn more about how computers work, the science behind it, math theory and stuff yeah that's cool. Go do a cs degree

split hazel
#

cs courses have an element of code to them

woeful pike
#

but for a company to ask you to know cs theory to make websites and stuff just seems a bit crazy

split hazel
#

a large chunk of credit is due to code

#

kind of can be compared to "knowing how every component of how a car works" and "knowing how to make a car from scratch"

woeful pike
#

should a racecar driver know how cars work? It would go a long way to showing how dedicated you are I guess but do is it required to be a competent driver? idk probably not

lyric mountain
#

how computers work
only for softwares

sudden geyser
#

It's because you're dispensable

lyric mountain
#

for hardware it's CE

woeful pike
quartz kindle
#

imagine needing a cs degree to work with photoshop

woeful pike
#

there's value in a lot of what you learn in a cs degree (I imagine lol) but the fact that it's an industry standard for hiring is stupid

split hazel
#

people are very quick to get a degree and know they 100% want to go to university but me not so much

woeful pike
#

trust me, majority of people don't know wtf they want to do or why they're going to university

#

it's just "what you're supposed to do"

split hazel
#

my school also heavily encourages and only talks about university probably so they can make claims like "90% of students got into their first choice university"

sudden geyser
#

Yeah 90% of schools are like that

split hazel
#

its a huge debt gamble

woeful pike
#

me running a school with the headline of "50% of our students decide to drop out to pursue the thing they're really passionate about"

split hazel
#

what if you also drop out half way through

#

you're still stuck with a debt, less significant but still large

woeful pike
#

I spent thousands on college and dropped out 3 years in. Thankfully it was community college so I didn't go into any debt at all

#

huge W

split hazel
#

nice

#

im in a kind of community college equivalent in the uk

#

sixth form

#

will never turn down a free qualification

woeful pike
#

yeah I have an associate's degree now too, dropping out was one of the best decisions I've made

#

I learned so much more than imaginable compared to what I would've if I stayed in school

split hazel
#

im more inclined to get an apprenticeship, you get paid, learn, get a degree (maybe) and work free of charge

modest maple
#

I would recommend

#

Been a vibe for me

woeful pike
#

internships are good if you can find a decent one

modest maple
#

Apprenticeships are even better WICKED

woeful pike
#

not sure what the difference is

split hazel
#

i live close to a GCHQ headquarters and my teacher has contacts there so some guy apparently wants to come down to talk to me from there

#

probably the best option

modest maple
#

Generally Internship implies either temporary with no real progression and / or it's not paid

woeful pike
#

I lived 5 mins away from blizzard headquarters KEKW

modest maple
#

also Apprenticeships generally give a degree with it

#

so you get paid + get a degree anyway

woeful pike
#

oh? interesting

modest maple
split hazel
#

yeah it all depends where you get one tho

split hazel
#

but is it still worth it

modest maple
#

i mean no

#

if your treated like shit and dont like what you're doing then dont do it lol

#

there are tons of other opportunities out there

modest maple
#

There is a general saying that working for private cyber security firms are great, but government cyber sec sucks ass

modest maple
lyric mountain
round cove
#

Government Security is literally filled with braindead programmers that haven't had to code in 35 years lol

sudden geyser
#

Sounds painful

round cove
#

Yeah it is.

modest maple
#

basically what the vibe is from anyone i've talked to who's done it lol

sudden geyser
#

No, working for intelligence agencies in general

split hazel
#

interesting i'll keep that in mind

#

but yeah im not really into cyber security anyways

#

or programming so im stuck on what to move onto

modest maple
#

like the next couple years are going to be really quite full of companies trying to employee tech people so it shouldn't be too hard to find somewhere to start

woeful pike
#

security is so fun

split hazel
#

a different type of security

modest maple
#

The amount of messages and emails I get from recruiters a day is mad

#

and quite annoying :(

sudden geyser
#

Nah, it'll still be very difficult

sudden geyser
#

CS is very competitive in most places and we know that

split hazel
#

pretty sure its things like going through binary files and analysing how malware works

sudden geyser
#

Unless you went to MIT

split hazel
#

probably some pen testing too which can be fun

modest maple
#

mmm in the UK right now it's kinda mad

sudden geyser
#

At least in the US that's how it is

modest maple
#

seems to be definite gap / more jobs than people rn

#

even on the junior jobs side

#

which is unusual because normally its too many juniors not enough seniors

split hazel
#

i also see a lot of people using computer science as a kind of "lifeline" for a career

modest maple
#

I mean its quite an easy industry to get into

round cove
modest maple
#

If you're motivated enough and driven enough you can get into it earning a solid living without any past experience in the field or education in it

quartz kindle
#

fake it till you make it actually works wonders, if you can pull it off

split hazel
#

mfs getting a 6 figure job from watching indian youtube tutorials

quartz kindle
#

i cant do it, my consciousness wont let me

#

there was a story about some dude who spent his entire savings to rent a porche and go to job inteviews with it, and he landed the best management jobs

sudden geyser
quartz kindle
#

just because of the car

round cove
#

I enjoyed my CS degree. I think all the classes I took helped me form a way to think critically in more than just programming.

split hazel
#

the best part is the debt

#

it teaches you how to hustle and save money

quartz kindle
#

and to work out of desperation

round cove
#

The debt isn't that bad, especially with a programming job lol

quartz kindle
#

i wonder sometimes, am i poor because since i dont have debt, i dont have motivation to work?

#

lmao

lyric mountain
#

no, you're poor because you're brazillian

quartz kindle
#

xD

round cove
#

unironically this

quartz kindle
#

no way in hell im gonna work in brazil and get paid in reais

#

i wanna get paid in euros

split hazel
#

i want to get paid in robux

#

no income tax to be paid

quartz kindle
#

or crypto

split hazel
#

you're onto something

quartz kindle
#

work for bitcoin

lyric mountain
quartz kindle
#

ah yes

#

the sex

split hazel
#

sus

#

also guys is HR a good career to get into

quartz kindle
#

he probably gets it so rarely he has to make a public statement about it

sudden geyser
quartz kindle
#

hr literally eats your soul

split hazel
sudden geyser
#

*soulless

split hazel
#

"what do you mean you cant be in 2 places at the same time while earning minimum wage??!!! YOURE FIRED"

quartz kindle
#

be ready to be forced to follow gender and race quotas and be forced to hire based on heritage over skill level

#

:^)

split hazel
#

this actually true

#

if you hire too many men the company is gonna get cancelled

quartz kindle
#

also, if the boss asks you to hire his nephew, you better do it or you're fired

lyric mountain
#

there's a HR simulator game

#

papers please

quartz kindle
#

isnt that a border control simulator?

lyric mountain
#

same thing

quartz kindle
#

lmao

#

do you also have people go through full body scanners before hiring them?

split hazel
#

might work for innersloth idk

#

so that i can get leaks on among us 2

#

with mediocre unity code

modest maple
#

my slightly shitty Figma ability :(

pale vessel
#

dude that logo still looks the same as last time and it sucks

modest maple
#

it does yes

#

i am aware it sucks