#development

1 messages · Page 256 of 1

quartz kindle
#

make it the first thing right after requiring

eternal osprey
#

I see, apparently dijkstra has manyyy implementations

#

A stopping criterion is stopping when heap is empty. It can still update the distances of dequeued elements = can work with negative edges.
However, the stopping criterion of going on until all vertices are visited will lead to provlems when negative edfes are introduced

warm surge
#

may i see it?

quartz kindle
warm surge
#

alr

frosty gale
#

theyre already paying the consequences for it lol

#

they released something called "guilds" now

#

so they cant call them guilds on the api because they call servers guilds

#

maybe theyll just call them servers?

warm surge
frosty gale
#

they name attributes related to servers as "guilds"

#

libs can call it something else of course

#

but im talking from the discord api perspective

warm surge
#

tim said same thing but different way

frosty gale
#

yes he has indeed

quartz kindle
#

now they are a corporate DEI company for woke gaymers and kids

#

:^)

sage bobcat
earnest phoenix
#

what are some free ways to host my bot 24/7

quartz kindle
#

amazon's ec2 has a free trial for 12 months

#

but i think they also require a credit card

#

oracle also has a free vps, but they require credit card, id verification and may terminate your account for no reason

earnest phoenix
#

anything else that’s completely free?

quartz kindle
#

i've seen some people on discord offer free hosting

#

i dont recall their names tho

earnest phoenix
#

ah

quartz kindle
#

otherwise you can always host on your own pc

#

and leave it running 24/7

earnest phoenix
#

thats a lot though

quartz kindle
#

yeah, thats why hosting costs money

#

leaving computers on costs electricity

earnest phoenix
wheat mesa
#

Otherwise it’d be trivial to build a botnet with them

earnest phoenix
#

dang

small tangle
#

You could also host on a raspberry pi, but that also means purchasing it derpcat

bold agate
#

Hi?

#

Is there any way to put your website in topgg's desc?

deft wolf
#

You can use <iframe> tag

#

iirc

untold ocean
# earnest phoenix what are some free ways to host my bot 24/7

You should try render.com, create a web service and then attach the bot to the web service. This is just one of the many ways to achieve that, just remember they often spin down projects inactive for more than 15 mins, and spin up when requested, a way out is to run a cron job or so to keep it alive or something. It supports docker so anything is possible, the sky is the limit. Good luck.

pearl trail
frosty gale
#

i just havent used it though

#

ive used oracle services at work and i know theyre the furthest thing from reliable and trustworthy

#

it kills me every time i see a company supporting oracle because out of all companies doing bad in the world, oracle needs to go the most

lyric mountain
#

as a java dev, I also vouch for oracle going away

eternal osprey
#

hey guys, is a heap like this even possible?

#

this would not even be a heap right

#

because all children must be filled from left to right? So there's no way that 4 has no child while 7 does

lyric mountain
#

?

eternal osprey
#

??

quartz kindle
#

a heap is a tree-based data structure that satisfies the heap property: In a max heap, for any given node C, if P is a parent node of C, then the key (the value) of P is greater than or equal to the key of C. In a min heap, the key of P is less than or equal to the key of C.

#

Insertion: Add the new element at the end of the heap, in the first available free space. If this will violate the heap property, sift up the new element (swim operation) until the heap property has been reestablished.

eternal osprey
#

this is a max hreap

wheat mesa
quartz kindle
quartz kindle
quartz kindle
#

but also, the children of 4 could have existed before and have been deleted

eternal osprey
#

Cuz a heap is usually represented as an array you know

wheat mesa
#

Well yeah but I’m pretty sure there are a lot of heap algorithms and therefore it’s implementation defined iirc

bold crypt
#

who here is a expert in node canvas, and can tell me what i do wrong?

deft wolf
bold crypt
quartz kindle
bold crypt
#

i gave up

quartz kindle
#

also try using a different font family name, without dashes or special characters

bold crypt
#

everything was supposed to work, etc

#

cuz i did the same for my old bot and works fine

#

probably newer canvas version

lyric mountain
#

if someone claims to be all 3 then you're about to be scammed

quartz kindle
#

doesnt even need to be fast

#

just free+reliable=scam

lyric mountain
#

I mean, google & oracle are reliable enough

eternal osprey
#

free hosting platforms are generally all fucking bad

#

look at heroku for example, that shit kicks your bot offline after 20 days exactly each month, and it does not give you any root access to install required packages

lyric mountain
#

well, heroku is for apis technically people just used for bots cuz they could

earnest phoenix
#

and not made for bots yeah

lyric mountain
#

was free, for up to 23 days per month if 24/7

#

could shave some hours from uptime to have full month uptime mostly

earnest phoenix
#

also had the ability to verify with credit card and get like the double or something

green kestrel
#

anyone here trying to get this new DAVE stuff to work? I've been trying for a week now, it's a total nightmare

radiant kraken
#

@quartz kindle @pearl trail gotta love that they give the answer in plain sight mmLol

radiant kraken
#

assignment for my node.js course

#

just speedrunning it today

#

why read the instructions when you can just read what validate.js does mmulu

pearl trail
#

whoa

radiant kraken
sharp geyser
#

I am not sure how much i trust a school that does this

#

How you going to teach me programming if you can't even hide your answers properly

radiant kraken
#

they don't even try to obfuscate it 😭

#

@pearl trail @sharp geyser LMFAO even the base64-encoded answer validation code is bugged

#

☠️

#

because of this it's impossible to pass the validation test without modifying validation.js itself

#

the bug was something like this ```diff

  • const stderr = stderr.toString();
  • const stderr = stderr?.toString() ?? '';
    assert(stderr, '', '<message>');
pearl trail
#

damn

radiant kraken
#

i love this course sm

#

work smarter, not harder 🗣️🔥

#

imagine if the guy who made this course hash user passwords in their website with base64 mmulu

quartz kindle
#

lmao

sharp geyser
#

Either they intentionally did this and are trying to catch cheaters with seemingly correct answers, or they are this dumb

radiant kraken
#

it's just a text file, it can't do anything

#

besides the answer would be process.memoryUsage().heapTotal no matter if you cheat or not

#

since there's no other way in achieving it

lament rock
#

Was nerd emoji-ing to the fact that you can prepend global and still be correct

#

More of just a roundabout way which is stupid

#

BUT it is another way to reach the same thing

#

I feel like with coding answers, you'd have to evaluate the answers and compare with an expected simulated value because there are so many ways to achieve the same thing in quite a few cases such as with var assignment for short-handing or perhaps optional chaining if applicable

#

also dumb that they dont just call an api to check the answer

wheat mesa
#

I’m surprised they’re not using an online platform for this like HackerRank or something similar

radiant kraken
#

but ig this one is a special case because you have to edit multiple categories of assigments

#

though you can implement it on the website as well tbh

#

requiring devs to use node validate.js to see if their code is correct or not is just 🤡

wheat mesa
#

Or better yet don’t use javascript and have a language that can write actual unit tests 😉

radiant kraken
#

or better yet

#

use an executable

lament rock
#

Or rather, node does

radiant kraken
#

they would have to read assembly to read the answers

wheat mesa
#

I really do hate javascript now after working with it at my job

lament rock
#

Recent versions of node have actually included a test suite

radiant kraken
#

yup

wheat mesa
#

Especially when our codebase is easily 30k lines of messy javascript in which 45% of it is probably redundant

radiant kraken
#

i no longer need jest because of node:test

wheat mesa
#

Jquery, etc

#

So incredibly tangled and messy

lament rock
#

JS is an entry level language so you do get people who dont bother to optimize their code to reduce redundancy

#

Ew

radiant kraken
#

your company still use jquery???

#

in 2024?

wheat mesa
#

Our codebase is 35% javascript and like 45% C#

#

That should tell you what’s wrong with it right there

radiant kraken
#

that doesn't sound bad at all

#

i mean top.gg itself has a C# backend

wheat mesa
#

The C# isn’t bad

#

It’s the fact that there is so much js relative to the C#

radiant kraken
#

but didn't you say that it's 35% js

wheat mesa
#

Not to mention, the code quality is horrific

radiant kraken
#

then why not... refactor it

lament rock
#

I got hired by someone and they asked me if I can do front end development and I flat out refused. I'm a back end dev through and through. If I do any front end work, it's for my own projects because I can experiment with what I like… Like pug!

wheat mesa
#

I have a ticket to debug a few issues with a page right now, and the files I’m looking through are 3k+ lines of js each, and half of them have duplicate event listeners and it’s a mess to find out where the problem is

radiant kraken
#

haven't heard the name pug in years

#

what ever happened to them

wheat mesa
#

I have tickets and deadlines to make

lament rock
#

The only front end templating lib I'd use tbh

radiant kraken
#

what about react?

wheat mesa
#

It would take me several hundred hours of dev time to refactor even one page of our codebase

#

And the main problem lies in the fact that most of this code was written by incompetent interns at some point

lament rock
lament rock
wheat mesa
#

They don’t use classes, they don’t use functions very often, etc

radiant kraken
#

what's wrong with react

#

i feel like react is the python of web dev

wheat mesa
#

We still use var for everything

#

Which leads to complications in a codebase this large

radiant kraken
#

maybe they want to prioritize backwards compatibility?

wheat mesa
#

No, it’s just a mess of a project

#

It’s been ongoing since 2020 and it’s still not fully ready for production

radiant kraken
#

jeez

wheat mesa
#

Company that contracted us keeps feeding us money so there’s always more work to be done

orchid fern
#

Hi

lament rock
# radiant kraken what's wrong with react

I very strongly dislike anything that takes away from a low level experience and is less dev friendly since you have to deal with stuff like automatic re-rendering and shit like that when the developer knows when you should actually re-render

#

Just so much wasted CPU cycles

radiant kraken
#

but... its popular KEKW

lament rock
#

That doesn't make it any better!

radiant kraken
#

its like python

wheat mesa
#

I’d prefer react over razor pages any day

lament rock
#

Null you're making me shed tears

radiant kraken
#

why

orchid fern
#

No

#

Its not popular much

lament rock
#

I want something functional and powerful, not beginner friendly

#

I'm anything but a beginner

#

I also have horrible experience with libs that have too many layers of abstraction like discord.js. The cached imported module strings alone blew past my memory budget

wheat mesa
#

I feel like you reach a point where there’s too much abstraction

#

I want to know what my code is doing, not just run it and hope it works

#

I feel like at a certain point of wanting to do things with js you start to have to understand the internals of js, which defeats the whole purpose of it

lament rock
#

Mmm not really. That's when you really start to nitpick the performance of things like Tim, which dont get me wrong, I am grateful for it, but I'm not at that point yet

#

Im still a freak with overarching performance though

wheat mesa
#

I just want to get to a job where I’m working with C/C++/Rust

#

And a job where I don’t have to touch disgusting frontend dogshit

lament rock
#

Front end devs are sadly in very high demand

wheat mesa
#

I can tell with the quality of the frontend code I read

#

Looks like they taught a chimpanzee to write code

lament rock
#

It’s not just that. It's moreso that companies want an online presence and need maintenance and stuff like that

#

But when you outsource your work to contractors, you do get mixes of code base styles and have fun spaghetti

wheat mesa
#

I just want to do backend so bad

#

95% of my time at my new job has been spent fixing frontend bugs and it’s genuinely boring

radiant kraken
radiant kraken
#

i cant believe im basically forced to get into web nowadays

#

its either web or mobile dev

lament rock
#

Im so thankful that my passive contributions landed me a contracting position for someone

radiant kraken
#

lucky you

#

i'm still in a state of limbo

lament rock
#

It doesn’t make me the most money but it makes me happy

wheat mesa
#

I have interviews lined up with some fintech and quant finance firms rn so I’m hoping to land something there

radiant kraken
#

idk if i fit as a mobile dev, frontend dev, backend dev, desktop app dev, etc

lament rock
#

Make your own stuff I guess

wheat mesa
#

Lowkey scared for the quant finance interview because I feel like it’s gonna be really difficult

lament rock
#

the next app is a big social media replacement

#

Short form content and what is "advertiser friendly" is destroying the internet

earnest phoenix
radiant kraken
#

how can you tell

#

i'm not familiar with 95% of web dev

radiant kraken
earnest phoenix
#

unnecessary smiley at the end but kinda true

lament rock
radiant kraken
#

full-stack devs are just devs that are in there just for the money /s

radiant kraken
lament rock
#

Which I only interacted with once and cheesed it and never again

#

for nitro, I mean yes but emojis

radiant kraken
#

oh and also profile avatar decorations

lament rock
#

vrcShh 🧏

#

Thats more than likely an L since they have per guild customization

#

File storage at Discord's scale cannot be cheap

wheat mesa
#

I’d imagine it’s not cheap, but at the same time not expensive for a company of their size. With a multi billion dollar valuation, I’m sure they can afford some hefty hardware to handle it

sharp geyser
lament rock
#

I'm half glad half burdened by the fact that I forgot how to do a lot of manual arithmetic especially with floating points. For some expressions I can work out in my head, but once it starts to have like 3-4 layers of operations, I just usually leave it to my calc. Why that all matters is because I'm working on a js library that does arithmetic on strings which would theoretically allow for infinite precision of the exponent and the mantissa

#

Progress going smooth. So much to do, but sadly you cannot override how operators are applied to classes like + or - so I have to make methods :(

#

im really not excited for sqrt or mod

wheat mesa
#

Some numbers just physically are not representable in base 2

radiant kraken
#

the question was literally about the total heap memory

#

process.memoryUsage().heapTotal is the answer

proven lantern
#

computers can only calculate 203 trillion digits of pi

#

i need more than that

lyric mountain
#

java bigdecimal could give u up to 9.2 quintillion digits mmLol

#

all that's required is to extend bigdecimal to allow long precision, and a helluva ram

surreal sage
#

i hate winscp so much it makes me want to kms

deft wolf
#

Still better than filezilla in my opinion weirdsip

surreal sage
#

its

#

so much

#

slower

#

for single files

radiant kraken
lyric mountain
#

I think js uses the same concept as java's

#

python int is constrained to long tho

radiant kraken
#

doesn't look like it

lyric mountain
#

ah, right, it's py2 that has limited int

#

py3 uses the same concept as java too

pearl trail
#

me when func name

quartz kindle
pearl trail
frosty gale
#

(he was inserting params with ${} in js)

pearl trail
#

💀 💀 💀

eternal osprey
#

hey guys i am absolutely brainfucked atm

wheat mesa
#

Cool stuff

eternal osprey
#

yall now stacks right?

#

Look suppose we call f(a,b,c,d,e,f,g,h), then it puts the first 6 onto registers and the other variables on the stack right?
However, in this case its a fucking stack so it pushes first g and then h and because of that it appears as
h
g
however, the stack pointer is where we will pop elements from (it's at the local variables now) and when we pop, doesn't it mean that it goes against fucking LIFO?
we first pop g while it should have popped h first.
Or am i tweaking

wheat mesa
#

Yeah what about them

#

It’s going to be system dependent iirc

eternal osprey
#

i know you have either little or big endian but still, i assume a down growing stack atm

#

it doesn't make any sense

#

so this would mark the stack as:
[h,g,return address, frame pointer, local variables]

wheat mesa
#

Something about this doesn’t add up

#

H and G are in the wrong spot on that picture, it should be g and then h I believe

eternal osprey
#

why so? cuz we add elements on the top of the stack right?

wheat mesa
#

Actually idek

#

I’d have to go back and look at my asm assignments

eternal osprey
#

ahhh hollup

#

the local variables and arguemnts are pushed in reverse order

#

lol

wheat mesa
#

I was gonna say

eternal osprey
#

So if we have:
char test = 'a'
char f = 'b'
it first pushes b and then a but why the fuck does it do that

#

honestly i don't need to know allat tho

#

now i can do some cheecky buffer overflow attacks guys 🗣️

wheat mesa
#

Yeah you mostly care about overwriting the ra anyways, if your stack is growing down and your heap is growing up then you shouldn’t have an issue with the saved locals in that visualization at least

#

(I’m not super good at this tho so that’s just my pov)

eternal osprey
#

yeah thats true tho

#

thats correct

earnest phoenix
eternal osprey
#

i see

#

but wait in this case

#

isnt the bottom of a downgrowing stack at the side of the lower addresses?

#

Because in a stack we pop and push at the top of the stack right

frosty gale
frosty gale
#

if you mean higher to lower stacks which is the norm then yes

eternal osprey
#

i see

#

yo chloe you are good at c right

#

look at this program, when i input 100 characters into the program (so the buffer gets filled up)

#

now, suppose i enter one more character, shouldn't it already overflow the command array?

#

cuz as of now that shit aint happening it takes me 2 chars, is that like a general padding rule or..?

#

cuz at 101 characters it was still oki and printed /bin/ls but after i wrote another letter boom it immediatelly became ""

#

and then another character, boom it showed the new char/

wheat mesa
#

Keep in mind that C strings are terminated with 1 char, so a char array of 100 length can actually only hold 99 characters. The last character is reserved for the null terminator

eternal osprey
#

huh wait so when i write data to the buffer i can only use 99 of its capacity?

wheat mesa
#

Yes

#

In memory, a 5 length character array would look like so:

CHAR CHAR CHAR CHAR NULL

#

There’s many videos out there on how buffer overflow attacks work, highly recommend watching one since my visualization is pretty bad lol

eternal osprey
#

oowh shit, i continosuly asked chatgpt if the last character of the char is a null character and that bitch told me no

#

but that still does not explain why it took me 102 character inputs to fully erase the original string?

wheat mesa
#

Idk fully, you might want to compile to assembly and look at the output

earnest phoenix
#

how can i make a qotd command with python using bible verses

proven lantern
earnest phoenix
deft wolf
#

Do you have a database?

proven lantern
#

oh, that would be even easier. you dont even need an interaction endpoint for that

earnest phoenix
deft wolf
#

Then it will be more difficult/impossible because you need to store this information somewhere

earnest phoenix
sharp geyser
#

What language

proven lantern
#

python

sharp geyser
proven lantern
#

you shouldn't just send message without user input though. at least let them enable/disable the notifications

earnest phoenix
#

some type of /set-qotd command that allows them to set a channel and enable or disable it

proven lantern
#

i'd go with serverless hosting for this. you dont need a vps running 24/7

earnest phoenix
#

also do you have any tips to improve my embeds?

#

it looks pretty plain

proven lantern
#

create an interaction handler using a free tier AWS Lambda with a free API Gateway. That handler will listen to the /set-qotd command. when it gets that command it saves the channel id to a free DynamoDB table. Then create a separate free AWS Lambda that is invoked by Amazon EventBridge every day. That other Lambda should iterate through the channels in the DynamoDB table. Send a message to each channel with a second delay between each one.

#

the hosting cost for this is $0/month

proven lantern
# earnest phoenix

you dont need to use a bible API. Just store all the bible versus in a DynamoDB table and give each verse an index starting at 0. Then use a random number generator to pick a number between 0 and the last verse then retreive that from the DB

proven lantern
earnest phoenix
#

how do i improve my embeds

sharp geyser
#

Trial and error

#

play around with different layouts. At the end of the day there is only so much you can do

earnest phoenix
shell tundra
quartz kindle
#

heres an idea

#

get a vps and run templeOS on it

#

then run the bot on it

#

:^)

lament rock
#

Really a holy bot

quartz kindle
#

the holiest bot

radiant kraken
#

is it written in HolyC

quartz kindle
#

the best C

earnest phoenix
#

...

#

i js need a better format for it

radiant kraken
#

insane

#

yeah right i would put "i'm a dev" in my linkedin

earnest phoenix
#

so how do i make my embed look better

lament rock
earnest phoenix
lament rock
earnest phoenix
#

i need more cmds to add too

#

theres like nothing

lament rock
#

dont add commands just to pad the list. Focus on quality then if you have an idea for something that genuinely makes sense, then sure

earnest phoenix
lament rock
#

Idk. If you can't think of anything then don't force anything

#

Too many general purpose bots that just add features for the hell of it

#

They lose their sense of purpose

earnest phoenix
#

i have lik 3 commands

#

...

queen needle
#

think of things that relate to the Bible/church that you would use/have in real life and then try and incorporate that into your bot

proven lantern
# earnest phoenix

Add a button to the embed that lets the user fetch a new verse when they want

#

then you dont need a database or a scheduler

proven lantern
earnest phoenix
proven lantern
earnest phoenix
#

so idk if i should do that

earnest phoenix
eternal osprey
#

hey guys i have a very simple buffer overflow attack but this shit continously writes to the wrong address and it makes me crazy

#

the launch shell is at 0x5555555551e9 right, so that's the program i am trying to open

#

i have successfully found that the padding should be 120, after that it basically starts overwriting the return address.

#

for some fucking reason \xe9\x51\x55\x55\x55\x55\x00\x00 does not want to work

#

like putting:
\xe9\x51\x55\x55\x55\x55 makes my program simply crash (i assume it needs 2 more bytes to overwrite)
\xe9\x51\x55\x55\x55\x55\x00\x00 does not output anything, simply goes out of gdb

earnest phoenix
#

Can you overwrite $rip?

eternal osprey
#

yeah

#

my padding is 100% correct, exactly 120 elements

#

cuz if i write 121 b's, the last element of the return address becomes 62 = b

#

somehow the address i am concatenating in the end is just wrong

subtle hearth
#

Idk what I'd want from a bible bot other than
find a random verse
find a specific verse
and find a verse containing a word

#

maybe finding verses that are quotes from certain people?

#

e.g "findverse Jesus" and that makes it show one verse where Jesus talks

#

maybe if you're trying to make a minigame you could make the bot show a verse with certains words blanked and then if the person who used the command can remember the words used in the verse they get good boy points

lyric mountain
#

the books have diff names

deft wolf
#

The name can always be changed

lyric mountain
#

until the bot gets verified

deft wolf
#

Well, it's better to open it to other possibilities now than later when it will be more difficult

lyric mountain
#

ofc

earnest phoenix
lyric mountain
#

why dont you try some other kind of bot? one with broader scope so you can comeup with new modules from time to time

sage bobcat
#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

digital swan
#

well actually my multipurpose bot is revolutionary with hundreds of never before seen features 🤓

pearl trail
#

that's what every multipurpose bot developers said

lyric mountain
#

I mean, mp bots aren't inherently bad, it's just that you'll have little to advertise it upon

feral aspen
#

Quite difficult to be unique with a multipurpose bot

lyric mountain
#

idk

charred orbit
#

Isn't holybot kind of even worse lol

proven lantern
#

RIP Terry. 🪦

lyric mountain
proven lantern
#

I got my 3rd subscriber to my bot this week!

lyric mountain
#

nice

proven lantern
#

what would be a good way to give users API access to my bot commands? My bot is setup like this

Discord API Gateway (Interaction URL) -> Lambda (Signature Verify) -> Lambda (Command Logic)

#

i'm thinking about making another API Gateway + Lambda for the user API or modifying the Discord API

#

Discord API Gateway (Interaction URL) -> Lambda (Signature Verify) -> Lambda (Command Logic)

User API Gateway -> Lambda (Verify token) -> Lambda (Command Logic)

lyric mountain
#

token + ratelimit is pmuch enough

proven lantern
#

yep, and i'll need to do some more verification stuff. like i'll need to check which guild's token it is and make sure they aren't messing with another guild's stuff

#

should i mess with the API or make the user use the same format the Discord expects?

#

discord sends in data like this

{
  "data": {
    "options": [
      {
        "name": "1st_place",
        "value": "@tribal ether"
      }
    ]
  },
  "member": "...",
  "application_id": "..."
}```
#

then i'll have to explain the discord Interaction Event format to everyone

#

i'm also using the resolved data too.

lyric mountain
#

that's a recipe for disaster

proven lantern
#

yeah

#

i think it would be too dangerous

#

i'd have to check everything for trickery

lyric mountain
#

let's say I create 10 accounts, run 10 instances of a script that triggers ping command on your bot in a certain guild, or even 10 different private guilds

#

I can easily ddos your bot by filling the message bucket

#

and you cant prevent this, cuz they're different accounts

proven lantern
#

User API Gateway -> Lambda (Verify token) -> Lambda (Command Logic)
the verify token would prevent it from getting to the lambda command logic

proven lantern
#

and it's all lambdas so it would just spin up a bunch and cost me money

lyric mountain
#

different accounts, different tokens

#

for you it'd be no different than 10 unrelated users using the api

proven lantern
#

it would never get to Lambda (Command Logic)

lyric mountain
#

how do you pretend to check at verify token lambda?

proven lantern
#

there is a command to create a token and it's saved to the database

#

then i look it up

#

i'll make the command a premium command too

lyric mountain
proven lantern
#

if they want to subscribe then i'll allow them to attempt to ddos me

lyric mountain
#

but then your other legit subscribers would be prevented from using both the api and the bot

proven lantern
#

discord has a different endpoint than the user

#

if they cause AWS to crash then theyll have a bigger problem than me

lyric mountain
#

bots have a global message bucket

#

they can lock your bot by spamming way too many commands

proven lantern
#

oh, the commands just insert records into DynamoDB

#

they only do followup responses and there wont be anything to followup

#

i'll just make a separate API that doesn't use Discord's Interaction Event format.

#

i'll have to add each command manually, but i dont think users need API access to most of my commands

lyric mountain
#

do you really need a discord output?

proven lantern
#

no, i dont think so

lyric mountain
#

you could make a dashboard of some sort to manipulate those data

#

especially when the end user wouldn't even know what an api is

proven lantern
#

this is my current plan
A guild can only make an API token if they have an active Discord subscription to my bot. they generate that token via a Discord command and I save the associated guild id. Then they use that token against an endpoint that is different than the Discord Interaction URL endpoint. That endpoint transforms the data into the Discord Interaction Event format and calls the Command Logic Lambda

solemn latch
#

Not sure what this is for, but its important to remember discord messages are not end to end encrypted and is not a secure form of sharing tokens.

#

even ephemeral messages are not secure.

proven lantern
#

dang

#

what about DM?

solemn latch
#

Not end to end encrypted afaik

proven lantern
#

gotcha, so someone on airport wifi can read all our messages

#

DAVE is only audio and video

#

this is what AI says


End-to-end encryption, which is found in apps like Signal or WhatsApp for example, ensures that only the sender and the recipient can read the messages, with no intermediary (even the service provider) being able to access the content. Discord currently does not offer this level of privacy for messages.```
#

discord already has access to the endpoint so i'm not too worried if they have access to those tokens

#

kinda creepy that Discord wants to read all our messages, but that's another issue

solemn latch
#

Wait until you learn texts and calls are not encrypted ^-^

#

There was that video a month ago ish that showed anyone with a few thousand dollar investment can track locations, texts, calls of a lot of people using just their phone number(no other info).

proven lantern
#

the telegram CEO was just arrested because the service supports end to end encryption

earnest phoenix
#

how can i make a command that translates words to hebrew

#

and describes them

#

n stuff

subtle hearth
#

well...

sharp geyser
#

google it

#

You will need some sort of translation api (google, yandex, deepl, etc etc) for starters

lyric mountain
#

Which is why so many bible translations exist

earnest phoenix
#

i kinda figured out how to do it

#

it sucks though

#

and my embed design is terrible

#

how do i improve this

lyric mountain
#

It's fine as-is

earnest phoenix
#

no

lyric mountain
#

Then improve it

earnest phoenix
#

i give up

#

its too hard

#

and i cant even fetch the definition of the hebrew word

cinder stratus
#

There are many dictionary APIs out there you will need to research it, I will suggest using Postman to make the HTTP requests and play with the results then you can integrate it.

civic scroll
earnest phoenix
#

i just want to translate the input to hebrew and then send the english definition of the hebrew word

charred orbit
#

Idk where to put this but anyone have any good ideas on growing my bot enough where it has constant usage, but also dosent blow up? lol

civic scroll
#

in one way, it's well done

#

if you want to improve it, make the embed title only literal hebrew word
then separate each field into its own embed field

earnest phoenix
#

how do i do stuff like this

#

in python

lyric mountain
#

using whatever is the equivalent of canvas for python

#

do note that's a bit overkill depending on what you plan to use for

solemn latch
earnest phoenix
#

huh

solemn latch
#

tkinter seems to be for doing stuff like the image you provided, or any basic image stuff.

earnest phoenix
#

i have no clue how to do that

solemn latch
#

Cant really help much with python, not a python developer.
but the docs seem to explain how to use it ^-^

#

Since the library seems really simple I'd suggest just playing with it.

lyric mountain
#

It's basically drawing but using code instead of mouse and keyboard

earnest phoenix
#

i need bot ideas too

#

i wanna make somethin original

#

butt i have no ideas

#

something that could get big

#

and be in a lot of servers

solemn latch
#

If someone has an original idea they're probably working on it or its a really large project that will take a long time and they dont want to work on it

earnest phoenix
#
  1. "EventHub" Bot
    A bot that helps server admins create and manage events. It supports various types of events like game nights, movie watch parties, or community discussions. Key features include:

Cross-server event sharing, allowing people from different servers to join public events.
RSVP and reminder system to notify users about upcoming events.
Custom event categories (e.g., gaming, educational, social).
Why it works in many servers: Communities often run events, and this bot would help organize them across different servers.

#

chat gpt

#

that a good idea?

solemn latch
#

Discord does already have an event system

earnest phoenix
#

i js have no ideas

solemn latch
#

Not cross server, but I dont see that as helpful. But maybe I'm not thinking of situations it would be.

earnest phoenix
#

any of those good ideas

solemn latch
#

The bot market is so developed its really hard to find interesting and new ways to get into it.

earnest phoenix
#

any ideas?

lyric mountain
#

In my case I do have an unique idea and implemented it, but I'm still pending to finish the tutorial I was making KEKW

#

100k lines of code no prob, 5 minutes of tutorial designing is pain

earnest phoenix
#

any ideas for one i could make

lyric mountain
#

Good ideas don't come easy, nor people simply give them away

earnest phoenix
#

bro.

lyric mountain
#

Just make a bot and put whatever comes to your mind on it

#

Eventually you'll find something worth making a bot around

#

I wanted a real tcg on discord, i made a real tcg on discord

#

Even if it took me 4 years to make it the way I envisioned

earnest phoenix
lyric mountain
#

Make a multipurpose bot, add content as you see fit

#

No better way to come up with an idea than doing that

radiant kraken
#

guys do you know the answer to this question

#

given the trollish nature of my lecturer, i'm not sure which is correct

lyric mountain
#

A is clearly correct

#

Is that abt what lang?

radiant kraken
quartz kindle
#

although it specifies than only A B C can be false

#

weird way to design a question lmao

lyric mountain
#

A and C cannot be false

#

and B has no little error I could use to justify it being wrong

#

D is a stupid option

#

I'd say go D, since as tim said the question only says the first 3 can be false, not the fourth

radiant kraken
crystal wigeon
#

does discordjs version 13 support multi select menu?

#

i dont want to update to 14. there are simply too many breaking changes.

#

is there a way to see documentation for previous versions?

deft wolf
#
crystal wigeon
#

this still sohwing me the new one

crystal wigeon
deft wolf
#

You asked about documentation, not a guide. Guide is updated to the latest version because v13 is no longer supported afaik

crystal wigeon
deft wolf
crystal wigeon
#

o nice lemme check

#

thanks prayge

radiant kraken
#

@lyric mountain @pearl trail @wheat mesa this statement is true, right?

"Each recursive call causes another copy of the function's statements and variables to be created; this can consume a lot of memory."

from what i've known, recursion can overload the stack memory because each function call occupies a certain amount in the stack memory

wheat mesa
#

Not statements but local variables yes

pearl trail
#

my brain said yes, idk

radiant kraken
#

so... it's false?

wheat mesa
#

Statements themselves don’t take up memory

#

Since all of the code for a function call is stored in the .text section, it just calls the procedure again, it doesn’t duplicate the statements inside of it

#

But this question is worded poorly so I’d say that this is true

radiant kraken
#

well yeah because i google translated it

#

dw in my native language it's also worded terribly

wheat mesa
#

(It’s technically not true but it doesn’t seem like it’s trying to trick you intentionally)

radiant kraken
#

he loves trolling his students in his questions

wheat mesa
#

That’s a lot of classes because they don’t expect you to know more advanced topics

#

A lot of what you get taught is “technically” wrong

#

On some level

radiant kraken
#

"oh you answered that? well actually you're wrong because..."

lyric mountain
wheat mesa
#

Stack is memory

radiant kraken
lyric mountain
#

oh, right, meant more for the overflow thing

radiant kraken
#

i mean in our first homeworks, i literally had to explain what an undefined behavior is

crystal wigeon
#

i dont see any attr tho

wheat mesa
#

Each time a function is called there is something called a “frame” that gets allocated on the stack. It stores info about the function call, such as local variables, return address, parameters, etc. Excessive recursion is bad because it causes a LOT of stack frames to be created, and it doesn’t pop those frames until after you reach the base case, which means you sometimes run out of stack to use leading to a StackOverflowError

radiant kraken
#

i'm not sure if i wanna risk a "well, actually" answer here

quartz kindle
#

from the wording itself i would argue the statement is false

#

because it technically isnt a copy (most things in C are references unless explicitly copied) and technically the memory usage isnt the problem (infers a misleading question)

wheat mesa
#

I would say that TECHNICALLY it’s false, but the way the question is worded makes me say that it’s true

quartz kindle
#

but if the teacher wants a basic superficial overview of what recursion is (aka repeat until finished but each scope is its own) then then answer would be true

radiant kraken
#

hm, alright! thanks guys 🫶

quartz kindle
#

flip a coin and pray

#

:^)

radiant kraken
#

sounds like a fancy term of what waffle has explained KEKW

quartz kindle
#

in that case yeah, each recursion creates a new "activation record"

#

aka stack frame

#

never heard the term "activation record" before tho lmao

radiant kraken
quartz kindle
#

:^)))))

radiant kraken
#

that's what my lecturer wrote lmao

lyric mountain
#

That's correct

#

But nowadays you'll burst the stack before you even notice the higher memory usage

#

Unless you have a fat function recursing itself

wheat mesa
#

The stack is tiny compared to the heap so yeah

#

But if you had the ability to have an infinite stack then it would use much more memory

radiant kraken
#

ah, noted

pearl trail
#

me when

for (;;) {
    int *hehe = (int)malloc(10000000);
  }
radiant kraken
pearl trail
pearl trail
#

anyone have ever used react d3 tree? is there a "fix" so the next children's lines are on the other side of it's parent's node?

#

it's just connecting the next lines to the point the previous line came

#

akshually, nvm, i got it

proven lantern
proven lantern
#

is C doing TCO too?

#

set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O2 -foptimize-sibling-calls")

green kestrel
proven lantern
#

or is discord still holding the keys?

green kestrel
#

you can opt in to uploading your pubkey to an API endpoint,.but it isn't needed. also seems that bots can't do that atm

proven lantern
#

when they have the public key they can snoop, but not spoof right?

green kestrel
#

iirc they store the signature

proven lantern
#

so just verify?

green kestrel
#

which is derived from your key+snowflake

earnest phoenix
#

man i have no bot ideas

green kestrel
#

but considering uploading is optional and opt in I don't think it's an issue

green kestrel
#

signatures are made using scrypt

proven lantern
#

not bad

green kestrel
#

it's one way

#

it's the same protocol signal and matrix use

earnest phoenix
#

gimme bot ideas

#

somewhat unique

proven lantern
green kestrel
#

lmao

earnest phoenix
green kestrel
#

we still can't use video as bots

#

even though DAVE supports it

proven lantern
#

probably worried about copyright

#

idk

earnest phoenix
#

i need ideas

#

bad

green kestrel
#

you need bad ideas?

earnest phoenix
#

i need ideas

#

badly

proven lantern
#

i only have good ideas

earnest phoenix
#

im getting trolled

green kestrel
#

but really don't make: anything AI, any general purpose mod bots, music bot, or Pokémon style collector bots

earnest phoenix
#

wow

proven lantern
#

like omegle remake using DAVE

green kestrel
#

if you avoid those you're already more unique than 95%

earnest phoenix
green kestrel
#

that's unique

proven lantern
#

add the sequals

green kestrel
#

expand it to other religions

earnest phoenix
#

its unique but not many servers would use it

#

and

#

only like 2 commands u can use

#

that are actually good

green kestrel
#

or make forks that do different religious works

earnest phoenix
#

thats the purpose

green kestrel
#

if you only cover Christianity you only cover 31% of the possible discord user base

#

you could at least double your user base,.perhaps make a new bot for each

proven lantern
#

this idea is great BTW.
you should support the biggest 5 or so religions and then accept donations in your bot for each religion. Then make a leaderboard for the religions that donate the most.
#development message

green kestrel
#

well, can your bot convert atheists like me? make it do that (seriously) and you got something beyond just a discord bot

proven lantern
#

commit a percent to charity

proven lantern
earnest phoenix
#

not much else to add

green kestrel
#

can it do bible quote of the day on a schedule

#

or let users pick a favourite bible quote or passage to attach to a profile?

earnest phoenix
green kestrel
#

sure but worth adding

earnest phoenix
#

yeah

#

do you know how?

green kestrel
#

do things you don't know yet,.step out of comfort zone

earnest phoenix
#

itts a good idea

green kestrel
#

in whatever language you use? unlikely as it's probably js or py

earnest phoenix
#

just send a certain command to every server

#

python

#

id need a command to enable and set the channel as well

green kestrel
#

I don't really know python and I suck at js

#

all my bots are C++ with PHP dashboards

earnest phoenix
#

i have no clue what that even is

earnest phoenix
#

this is hard

green kestrel
#

PHP is life, PHP is love

neon leaf
#

nu uh

#

still need a project to continue learning c++

earnest phoenix
#

what is php

green kestrel
#

only the one of the most popular programming languages in the world for web stuff

solemn latch
#

is php coming back? I heard they had a good upgrade

green kestrel
neon leaf
#

idk if I want to make another discord bot

green kestrel
neon leaf
#

I want to do more fancy stuff with uws

proven lantern
#

facebook did a lot of work on php

neon leaf
#

because I love annoying segfaults

solemn latch
green kestrel
#

wherever you look they all say PHP is still used on like 70% of sites on the web

#

that isn't a dead language that needs to come back

#

in fact PHP is my day job

#

js is still the underdog

#

apart from on front end

solemn latch
#

I mean, its mostly wordpress isnt it?

green kestrel
#

nah

#

wordpress, Laravel, WooCommerce, oscommerce, most of Facebook

#

magento

#

tons of cakephp sites

proven lantern
#

do people use hack besides facebook?

green kestrel
#

at work we mostly do laravel

#

no

#

Facebook don't any more

#

it was too divergent from php 5

#

a lot of what they did got merged into php 7 jit

#

which is now obsolete and replaced by php 8

#

there wasn't much gain between hack and php 7 except in specially configured setups specific to Facebook infra

#

and a complete impossible ball ache for anyone but Facebook to set up and use

earnest phoenix
#

how do i send a message to every server the bot is in

green kestrel
#

and there were many things it couldn't do like reflection, eval, etc

green kestrel
earnest phoenix
proven lantern
#

that's good they stuck with php for the most part.

earnest phoenix
#

i cant figure it out

#

i give up

green kestrel
#

take a step back and learn a bit at a time

earnest phoenix
#

no

proven lantern
#

i'm sure facebooks experience with the php influenced the language a bit

green kestrel
#

break problems into small steps

#

each easier than the whole

proven lantern
green kestrel
#

god no

earnest phoenix
#

doesnt work

green kestrel
#

AI sucks nuts

#

lol

earnest phoenix
#

oo

#

my script dont work

proven lantern
#

AI is good with language stuff

#

LLM stuff

solemn latch
#

AI is a great tool once you already have enough experience with programming to not really need it anymore.

earnest phoenix
#

woo

#

how do i send messages to every server the bot is in

solemn latch
#

Loop through each server and send a request, but you'll likely hit ratelimits pretty quick.

green kestrel
earnest phoenix
#

idk how

green kestrel
#

first find out how to loop

#

then find out how to get server list

solemn latch
#

I'd just use channel following for that tbh

green kestrel
#

then find out how to access each element in they list in loop

earnest phoenix
#

should i just send a different one to each server

#

randomly generate it

solemn latch
#

so your bot just sends 1 message to 1 channel and the users can follow that channel if they want.

eternal osprey
#

does anyone know which companies still use haskell and what its main purpose is in the wild (i know its a functional language)?
I have managed to understand haskell pretty well a while back and i ABSOLUTELY love this language. Tryna do more with it, but first gotta know whether there's any demands for it lol

proven lantern
earnest phoenix
#

i cant figure this out

#

it wont send

proven lantern
#

AI knows all. it can answer all your questions

#

give AI your code and ask it a question

earnest phoenix
#

yeah it wont send

#

what the fuck

proven lantern
#

open your heart to AI. it will lead you to the answers you're looking for

proven lantern
#

look into Roko's Basilisk before making your decision on this

#

Roko's basilisk is a thought experiment which states that an otherwise benevolent artificial superintelligence (AI) in the future would be incentivized to create a virtual reality simulation to torture anyone who knew of its potential existence but did not directly contribute to its advancement or development, in order to incentivize said advancement

earnest phoenix
#

this wont fucking work

#

im pissed

solemn latch
#

I'd really suggest avoiding AI answers until you're confident in your programming language.

earnest phoenix
#

i give up

proven lantern
#

i will be doing everything AI tells me to do just in case

eternal osprey
#

currently doing data analysis at a company, its pretty fun but idk i miss using haskell in the real world

proven lantern
#

lots of companies dont care which language you use on internal tools teams

quartz kindle
# proven lantern

Roko went on to state that reading his post would cause the reader to be aware of the possibility of this intelligence. As such, unless they actively strove to create it the reader would be subjected to the torture if such a thing were to ever happen.

#

lmao

green kestrel
lyric mountain
lament rock
lyric mountain
#

also I'd dim the background color and use a sans-serif font, and use different colors for arrows and text or avoid having arrows cross text

warm surge
green kestrel
#

theres a websocket, an actual https websocket, which is used as the control channel for the UDP, the UDP is just used for the audio stream

lament rock
green kestrel
#

there are two websockets

#

and one udp socket

#

first websocket: the discord shard, where the server is
secondary websocket: control socket for the vc
udp socket: RTP stream target

#

but the first websocket we only use to request details and token to get to the secondary websocket

lament rock
#

Ah. I totally forgot about the hole punching step

frosty gale
#

i heard its only a theoretical way of connecting two clients behind a NAT

#

is it practical is probably a better question

lament rock
earnest phoenix
#

how could i make a bible api

quartz kindle
#

then make a server that receives http requests and retrieves information from this database

#

and returns it to the user

earnest phoenix
#

i dont know how to do all this

eternal osprey
#

on my tsc, when i compile my tsc file to js, it always adds .default behind the name of the import its fucking annyoing. Any way to stop it?

#

For example:
import moment from moment-timezone:
now adds:
moment.default

earnest phoenix
#

at all

chrome tree
#

finally managed to implement my template system in nodejs for my bot's webinterface

earnest phoenix
#

me when people reinvent the wheel

chrome tree
#

haha

earnest phoenix
wheat mesa
earnest phoenix
#

im just trying to do it through github

#

but i dont get how to do it

digital swan
#

well github isnt a database

earnest phoenix
#

im using that to script

#

or whatever

#

connecting to mongodb with it

digital swan
#

yeah github is for source control and making your code public

earnest phoenix
#

oh

#

well how do i make the api with mongodb

digital swan
#

well you have to store whatever data you want in mongo

#

and then you can fetch it

earnest phoenix
#

how

digital swan
#

sounds like you need to watch a mongodb tutorial

earnest phoenix
#

i just wanna know how to make the API

#

im so confused

wheat mesa
earnest phoenix
#

what would i make the API in

wheat mesa
#

That depends on your programming language

#

There are tons of API frameworks, it’s up to you to choose one based on your needs

earnest phoenix
wheat mesa
#

GitHub is for open sourcing your code

#

It doesn’t deploy your API (not counting CI/CD pipelines)

earnest phoenix
#

yeah i know

wheat mesa
#

So you want your code to be open source and visible to everyone?

earnest phoenix
#

yeah

wheat mesa
#

In that case, you can use GitHub for that

earnest phoenix
#

with added features

proven lantern
digital swan
wheat mesa
#

Get the data, store it in a database, set up a REST API that queries your database depending on the endpoint of HTTP methods used

#

That’s the general idea

proven lantern
eternal osprey
stuck dawn
#

Does anyone have a problem where the child expands its parent? When it reaches a certain amount of items on that container above the image the container expands

#

It's overflowing, but it still expands for some reason

earnest phoenix
#

i made an api in replit. how do i host it with the zip file

lyric mountain
lyric mountain
#

alas, you dont move projects using zip files btw, use git

#

this way you have a backup in case something goes wrong with the files

lyric mountain
#

then your api aint gonna be 24/7

#

simple as

earnest phoenix
#

lyric mountain
#

apis, bots, programs, games, they're all the same

#

the only difference is where they're being executed

#

it's only online as long as someone is running the code somewhere

#

for api tho you dont need 24/7, you just need it online when someone is actually using it

#

so replit will fit for it

stuck dawn
lyric mountain
#

nesse canal em especifico s

earnest phoenix
#

so it kinda does need to be 24/7

deft wolf
#

Well, you can rent a VPS where you can host your bot and your API

stuck dawn
#

o do overflow?

#
.citizen-list {
          position: relative;
          width: 100%;
          max-width: 100%;
          display: flex;
          gap: 1%;
          overflow-x: auto;
          overflow-y: hidden;

          &::-webkit-scrollbar {
            display: none;
          }

          .citizen-name {
            padding: .5% 1%;
            box-sizing: border-box;
            background-color: var(--mdt-focus-color);
            border-radius: 2vh;
            color: var(--mdt-primary-background);
            font-size: 1.4vh;
            display: flex;
            align-items: center;
            white-space: nowrap;

            .icon {
              flex-shrink: 0;
              width: 1.5vh;
              height: 1.5vh;
              background-color: var(--mdt-primary-background);
              display: flex;
              align-items: center;
              justify-content: center;
              border-radius: 50%;
              margin-right: 0.5vh;

              svg {
                font-size: 1vh;
                color: var(--mdt-focus-color);
              }
            }
          }
        }
earnest phoenix
#

broke

deft wolf
#

Then you have to choose either 24/7 (paid) hosting or free hosting

small tangle
#

Raspberry Pi :D

lyric mountain
#

na vdd qlqr unidade q n seja % vai

#

só q, se o pai não tiver tamanho fixo, os filhos tbm podem "esticar" ele pra fora do pai

lyric mountain
#

então ou vc usa a msm unidade pra todos, ou usa um constraint pra limitar o tamanho maximo

proven lantern
deft wolf
earnest phoenix
#

ok

proven lantern
#

AI can help you find these answers.

#

Us humans are flawed. We don't know the Answers.

earnest phoenix
#

ai is flawed too

#

!!

proven lantern
#

🙂

proven lantern
stuck dawn
#

a classe?

tough condor
#

anyone know how i can implement rate limits using FastAPI?

lyric mountain
#

mas não da pra saber mt a causa verdadeira sem ver o css inteiro, e o html

#

pelo inspect elements vc consegue ver a disposição do layout

#

pra saber oq empurrou o container pra fora do pai

stuck dawn
lyric mountain
#

vai usando a setinha, no site o elemento atual vai aparecer em azul

#

vai indo até vc achar qual q ta grande dms

stuck dawn
#

n tou percebendo se eu usar a setinha ele abre o elemento

#

mas supostamente é o icon

#

você sabe alguma maneira de fazer um quadrado com percentagem?

#

ou com outra medida sem ser vh ou vw

#

afinal nao é o icon

#

sinceramente nao consigo perceber..

lyric mountain
#

como ta o tamanho do container pai?

#

desse preto e do cinza no caso

stuck dawn
lyric mountain
#

ata, tem outras coisas dentro dele

#

então, tem um porém

#

o % n considera outros elementos

#

se o pai tem 500px de largura, então 100% seria 500px

#

pra vc fzer oq vc ta fzendo precisa usar unidade flex

#

flex: 1

stuck dawn
#

ou seja no citizen-list em vez de display: flex coloco flex: 1?

lyric mountain
#

por exemplo, se o pai for do tipo row (horizontal), e todos os filhos tiverem flex: 1 então eles vão dividir o espaço igualmente

#

flex é como se fosse uma "fatia" do tamanho

#

3 elementos com flex: 1 daria um total de 3, então cada elemento ocupa 33% do tamanho

#

se 2 tem flex: 2 e 1 tem flex: 1 (total 5), então esses 2 vão ocupar 2/5 do tamanho, e o outro vai ficar com 1/5

#

pensa como se fosse uma proporção

lyric mountain
#

no container q ta no lado esquerdo faz a msm coisa

#

dai vc ajusta o flex até ficar na proporção q vc quer, se aumentar o flex ele aumenta o tamanho da "fatia" desse elemento

stuck dawn
#

na classe current-report coloco flex: 1?

#

e retiro display: flex

lyric mountain
#

s

#

display flex pd deixar, ele afeta só oq ta dentro dele

stuck dawn
#

ele anula

lyric mountain
#

ata

#

então s, poe block

stuck dawn
#

depois como controlo? nunca usei o flex

lyric mountain
#

o flex só afeta o tamanho do elemento dentro do pai, a questão ai é q o display: block mexeu nos elementos internos

#

coloca uma <div> dentro do container cinza só pra ter o display: flex

#

sobre controlar o flex, vc precisa imaginar o container como se fosse um bolo

#

dai o numero flex simboliza qual o tamanho da fatia q o elemento vai pegar pra ele

#

o tamanho do bolo é a soma de tds os flex

#

flex/total flex

stuck dawn
#

ok mas ele ainda está mexendo no tamanho

lyric mountain
#

a div vc colocou dentro do container cinza né?

stuck dawn
#

sim

lyric mountain
#

e o container cinza ta display: block ainda

stuck dawn
#

ele por alguma razao anula tambem

lyric mountain
#

vc colocou flex nos dois?

#

ignora o html, to falando doq ta atras da janela

#

aqueles elementos à esquerda do container cinza tbm precisam estar dentro de uma div com flex

stuck dawn
#

ei mas assim vou ter que refazer tudo

#

e mesmo assim

#

ainda ultrapassa

lyric mountain
#

ta tem coisa errada então

#

volta ao q tava no começo

#

tenta por auto no width do container cinza

stuck dawn
#

ta, nao mudou nada

lyric mountain
#

hm, tenta no inspect elements ir deletando oq ta dentro dele até ele voltar ao tamanho certo