#development

1 messages · Page 16 of 1

civic scroll
#

man forgor to check types

lyric mountain
#

no, seriously, it makes no sense but it does work talking to a rubber duck

civic scroll
#

i have a rubber duck

#

but it's there as what's left of a broken love

#

reminds me of my ex and how good she was

#

where's the await

#

it's an asynchronous opration

#

you didn't even await for it

#

there's nothing to do on promises

#

@elfin tulip

elfin tulip
#

Still doesnt work slonk

lyric mountain
#

still returning undefined?

civic scroll
#

hmmmmm

#

@lyric mountain can you check what <CommandInteraction>.reply() returns

lyric mountain
#

lemme see

#

considering it's a CommandInteraction

civic scroll
#

promise

#

then it should work

vivid fulcrum
#

it's an ephemeral message

#

it doesn't actually exist

civic scroll
#

my brain's being dumb rn

#

i don't even know what ephemeral means

lyric mountain
#

ah didn't notice the ephemeral

elfin tulip
#

What do I do? or its not possible?

civic scroll
#

change the true to false

lyric mountain
#

I believe ephes have a hook for them

civic scroll
#

follow up reply right?

lyric mountain
#

I guess

#

else buttons wouldn't work on them

elfin tulip
civic scroll
#

thought of that, but again i no longer remember discord.js api

#

the last version i remember was 12

elfin tulip
#

12 was good

civic scroll
#

yes

elfin tulip
#

And still better than 13

lyric mountain
#

djs lost the focus after 12

#

now they're chasing (or trying) the perfect api structure instead of focusing on what's important

ancient nova
#

you can't embed links in footers?

lament rock
#

Djs removed the disable everyone feature and I had to PR it back in because nobody knows how to regex I guess

#

They just only had an option to remove all mentions

boreal iron
earnest phoenix
#

Anyone have any DB suggestions that I use for a Discord bot?

I've tried MongoDB and am not a fan.. Same with MySQL (however if that is a good option I will pursue it more)

lament rock
#

Postgres

boreal iron
#

Depends on your needs tbh and complexity

#

Yeah Postgres or MariaDB but definitely not MySQL

lament rock
#

The SQL language is good, but some DBs are too slow. I think postgres manages itself good, but if you need a temporary cache, go with Redis. If you hate relational, then idk. Out of my scope

earnest phoenix
#

I don't need to have a relational database but I don't mind them at all

#

I'll take a look into Postgres

lament rock
#

How large of a dataset are you working with

earnest phoenix
#

Not large at all

lament rock
#

So what don't you like about the options you tried?

boreal iron
#

Well on a small scope you can also go with SQLite tbh

earnest phoenix
#

Don't like Mongo because of the fact I don't really like the "Document" style of storing data
And MySQL is chunky imo

boreal iron
#

The performance is absolutely okay and you won’t reach its limits probably

earnest phoenix
#

I'll take a look around with the options just given

#

See what fits best

lament rock
#

sqlite is file based and can be locked by a process so multi process/machine interaction is impractical

boreal iron
#

If that is even going to happen

lament rock
#

would be the same if you used a json as a DB

boreal iron
#

Just with the exception you don’t ruin your entire DB when placing a , too much freerealestate

#

But yeah I know what you mean

#

Anyway if somebody don’t wanna setup an own database but still wanna use SQL I think SQLite on his mentioned scope is fine

#

I like any client update

#

Now the notification is misplaced

#

Not to mention the overlapping buttons in the mobile client I always see

#

👍

#

For discord

lyric mountain
#

I mean, they are devs

#

(who break things)

boreal iron
#

I really wonder how the mobile client is being built

lyric mountain
#

with their ass

boreal iron
#

Nah I feel like those aren’t client updates ruining things but more like the mobile client somehow also just renders html, css they use in the browser but literally adjusted for mobile clients of course

lyric mountain
#

they should literally just make the browser discord responsive and use it to compile to android/ios

#

goddamn, it's react native after all

boreal iron
#

While the app itself might be build on whatever language the OS supports, but the chat here itself just seems to download and render the code when starting the app

#

I noticed so many small adjustments over time like an embed padding that has changed or this one above going wrong

#

But there has been no client update been pushed to the App Store

lyric mountain
#

ye, discord is entirely ssr

#

I mean, almost

#

like 99%

boreal iron
#

So the entire chat at least must use a style it seems to download and render when starting the app

#

_chat is just an iframe _

ancient nova
#

why isn't everyone being filtered?

lyric mountain
#

I don't think u should list all channels

#

Ah wait

#

Just noticed the "and more"

#

But well, @everyone is technically a role too

celest shard
#

why did you tag me

#

sike you don't have perms

lyric mountain
#

mmulu you don't say

ancient nova
lyric mountain
#

Excluded u mean?

#

Because everyone is a role with the same id as the guild

ancient nova
#

also.. hastebin is dead again 😭

lyric mountain
#

Use hate

rustic nova
#

have I already mentioned how bad slash commands are at registering

#

starts bot

command gets registered

try using it

"failed"

lyric mountain
#

Works as expected

#

Expected: not supposed to work

rustic nova
#

exactly

#

especially when discord wants to force us on slash commands

#

we should have a proper was of developing with these, expecting multiple restarts of the application

ancient nova
#

😭

rustic nova
#

and like

#

its not even my shitty code

#

its literally the command not registering, even when it is several times

boreal iron
rustic nova
#

yes-ish, dunno how my library actually handles it

#

I may need a reload feature instead of stopping and starting the bot lmao

boreal iron
#

If so that will never stop to happen

rustic nova
#

fair fair

boreal iron
#

When registering something that is already registered it cause the commands to appear multiple times and you don’t know which one is the newest

#

Same command names but different application IDs shouldn’t be possible in theory but still happens quite a lot

#

If you really wanna push the commands on any startup then use the patch method

#

The recommended way should actually be to fetch the application commands on the startup, compare them to your locally loaded ones and either register, update or remove ‘em

#

Based on a simple comparison of the names, descriptions and command options

#

Once your bot is in a lot of guilds and you fuck up the app commands on any startup with this double registration issue people will most likely be annoyed quickly

wheat mesa
boreal iron
#

But like I said multiple times already, the API should really return an error when trying to register an app command with the same name a second time

#

Since registrations are an one-time processs

#

But yeah…

rustic nova
#

am I stupid

#

I wish to believe I am

#

but my mind tells me otherwise

lyric mountain
#

f"?

rustic nova
#

am I stupid rn

#

python btw

lyric mountain
#

a

hidden gorge
#

/home/runner/moonbotlist/node_modules/klasa/src/lib/extensions/KlasaUser.js:26
this.settings = this.client.gateways.users.get(this.id, true);
^

TypeError: Cannot read property 'users' of undefined
at new KlasaUser (/home/runner/moonbotlist/node_modules/klasa/src/lib/extensions/KlasaUser.js:26:41)
at new ClientUser (/home/runner/moonbotlist/node_modules/discord.js/src/structures/ClientUser.js:12:5)
at Object.module.exports [as READY] (/home/runner/moonbotlist/node_modules/discord.js/src/client/websocket/handlers/READY.js:10:24)
at WebSocketManager.handlePacket (/home/runner/moonbotlist/node_modules/discord.js/src/client/websocket/WebSocketManager.js:384:31)
at WebSocketShard.onPacket (/home/runner/moonbotlist/node_modules/discord.js/src/client/websocket/WebSocketShard.js:444:22)
at WebSocketShard.onMessage (/home/runner/moonbotlist/node_modules/discord.js/src/client/websocket/WebSocketShard.js:301:10)
at WebSocket.onMessage (/home/runner/moonbotlist/node_modules/ws/lib/event-target.js:132:16)
at WebSocket.emit (node:events:394:28)
at Receiver.receiverOnMessage (/home/runner/moonbotlist/node_modules/ws/lib/websocket.js:825:20)
at Receiver.emit (node:events:394:28)
at Receiver.dataMessage (/home/runner/moonbotlist/node_modules/ws/lib/receiver.js:437:14)
at Receiver.getData (/home/runner/moonbotlist/node_modules/ws/lib/receiver.js:367:17)
at Receiver.startLoop (/home/runner/moonbotlist/node_modules/ws/lib/receiver.js:143:22)
at Receiver._write (/home/runner/moonbotlist/node_modules/ws/lib/receiver.js:78:10)
at writeOrBuffer (node:internal/streams/writable:389:12)
at _write (node:internal/streams/writable:330:10)
exit status 1

#

i’m getting the code

rustic nova
#

oh wait nvm

#

I saw

#

am dum

rustic nova
hidden gorge
spark flint
#

fairs

quartz kindle
#

isnt klasa dead?

spark flint
#

i thought it was ngl

rustic nova
#

and yes

hidden gorge
#

yep

#

i’m using another system

celest shard
#

Lol they deleted my post asking for feedback on the library i sent here too on DiscordVote, regarded it as advertisment

#

Literally a free open source project related to discord bots, i get nothing off of it and matches the theme of the server 💀

rustic nova
#

I mean, it technically is promoting/advertising

quartz kindle
#

make an alt, post here with your alt asking your main for the link to your lib, main posts link, no longer advertisement because it was asked for

#

:^)

wheat mesa
#

true

hidden gorge
#

lol

wheat mesa
#

time to join with WaffleAlt

#

totally not suspicious

#

"Does anyone here have a recursive descent parser written only for math expressions in rust? Asking for a friend"

boreal iron
storm steppe
#

How can I route commands to every server? right now it only works in my "testing server".

#

and it doesnt work in the support server I added it to

#

how can I fix this?

boreal iron
#

You need to register them globally means without passing a guild ID as argument

storm steppe
#

so I can just remove that arg then!?

boreal iron
#

Not 100% about those rest methods but yeah that should be it

storm steppe
#

ok ty

boreal iron
#

The method might have a different name tho

#

As yours is called applicationGuildCommands(…)

storm steppe
#

hmm

#

1 sec ill check

boreal iron
#

Instead of importing the rest class and calling its modules you can also use the inbuilt methods of djs

#

client.application.commands.create(…) edit(…) delete(…)

#

To register em, update and delete commands

storm steppe
#

would I have to remake all cmnds with the djs way for this?

#

my handler is set up a bit diffrently

boreal iron
#

Not really as the property data actually is the command structure the API expects

#

You can log data to see the structure

#

You simple register them by putting all loaded commands into an array

#

As use the methods in mentioned above

#

So… wherever you load all your commands on a startup, push the module property data (which is your app command structure) to an array, then after all commands are loaded register it to the API

storm steppe
#

you helped me out a LOT

#

:) this seems to work fine

rustic nova
#

haha only if discord would provide proper audit log things haha right? Cant be discord

#

anyways, been breaking my brain for the past 2 hours, getting the user who deleted the message. If the message was deleted by the user itself, do nothing

wheat mesa
#

I finished my parser for my language

#

Now I have to learn cranelift

rustic nova
#

lift crane

#

ez

wheat mesa
#

I’m scared of cranelift though

#

I wanna finish my lang before the summer ends but I have a week left of summer

earnest phoenix
#

OK, i finished the bot - Determining your age and likely-hood you are real with 2 selfies and captcha on paper. to get you verified on nsfw servers that require people to see your IDs, my bot is automated and doesn't require a human. It's super cheap to have, too.

We chatted about this the other day - but now NO id is required to get your age. Thoughts?

wheat mesa
#

I don’t know how people are going to feel about sending in real pictures of themselves on the internet to a bot they don’t necessarily know

#

I understand the purpose of your bot but from my perspective it just seems way too invasive

earnest phoenix
lyric mountain
#

People post ID in servers?

wheat mesa
#

sounds like identity theft waiting to happen

lyric mountain
#

Or doxx

#

Tbh I wish to never get even close to handling personal documents, the laws are way too harsh about that

wheat mesa
#

I never want to get into the business of verifying identity for nsfw/dating servers on discord in general

#

Sounds like a scandal waiting to happen for when a child manages to get on because your bot somehow lets them through

rustic nova
#

yo, is there some sort of way to prioritize on_message before commands on discordpy/pycord?

Currently what am trying to work on is having tags through the -tags prefix. Though said prefix also triggers the tags

#

figured doesnt work

crystal wigeon
#

Hey um im receiving the channelCreated event when a new channel is created but looks like the client isnt able to find it afterwards in the guild. @quartz kindle sorry for the ping.

sharp geyser
#

And the pic on the license

#

Still risky though

sharp geyser
#

Also Tim is asleep I think so

crystal wigeon
#

yeah he'll see the ping when he wakes up hopefully haha

sharp geyser
#

what lang/lib are you using?

crystal wigeon
#

discordjs

sharp geyser
#

where is .context coming from huh

crystal wigeon
#

its the message object

sharp geyser
#

What

crystal wigeon
#

im calling it context my bad

sharp geyser
#

🤔

crystal wigeon
#

wait wait

sharp geyser
#

Show more code than that cause I don't understand what you're trying to do here

crystal wigeon
#

message.guild.channels

#
    context: BaseProps["context"],
    id: string
) => {
    const channel = context.guild?.channels.cache.get(id);
    if (!channel) {
        return context.guild?.channels.fetch(id);
    }
    return channel;
};```
context is the mssage object from the on "message" event
sharp geyser
#

You're being redundant

crystal wigeon
#

both of these return 404 for an existing channel thats newly created

#

just tried both

#

to test

sharp geyser
#

.fetch gets from cache first then if it can't find it will fetch the API and cache

crystal wigeon
#

ohw i see

sharp geyser
#

So you are being redundant by checking cache and then fetching

crystal wigeon
#

that didnt work as well tho

#

gotcha

sharp geyser
#

That was just a tip

#

As for why it isn't being found are you sure the ID is correct?

crystal wigeon
#

yep

#

i even hard coded the id

#

to check

sharp geyser
#

Any errors?

crystal wigeon
#

nothing else just 404 lemme send the error

earnest phoenix
#

You're probably fetching the said channel from the wrong guild, I think it's a better idea to check that first

crystal wigeon
#

i checked the guild as well

#

the guild id is correct

#
name:'DiscordAPIError'
method:'get'
message:'Unknown Channel'
httpStatus:404
code:10003
path:'/channels/100461573143187460'
sharp geyser
#

It's trying to fetch a channel but you are using a guild id no?

#

You just said you were using a guild id

crystal wigeon
#

no no

#

thats the channel id

#

i think incorrect id is being passed lemme do some more debugging and get back

#

gotcha, found the issue, its doing weird things cause of the bitint thing,

#

the id im getting is 1004615731431874600 but the actual id is 100461573143187460

sharp geyser
#

Huh

#

What are you doing to get the wrong Id

crystal wigeon
#

idk probably something to do with js handling 18 digit stuff

sharp geyser
#

But the ids returned are stringed bigints it shouldt have a problem no?

#

Strings don't have issues with length

pale vessel
#

What db/wrapper are you using?

sharp geyser
#

They using djs

pale vessel
#

Dingus

crystal wigeon
#

yeah i might know what the problem is, im kinda sanitizing the args read for some reason i cant remember at the moment lol, im using bigint there. looks like thats messing things up

sharp geyser
#

Idk if they are storing it or someone is supplying it through a command dingus

sharp geyser
#

If your convert it to a number it is going to try and correct itself

#

I don't remember what it's called but js can't handle large numbers

crystal wigeon
#

yeah thats whefre the confusion is

#

ye

sharp geyser
#

Am I wrong?

crystal wigeon
#

yeah js adds 00

#

you're right

#

js cant handle large numbers

#

gotta convert them to bitint

#

parse

sharp geyser
#

I swear js can't handle large numbers they try and round it or whatever

wheat mesa
#

js numbers are 64 bit floats

sharp geyser
#

Okay well shut up Mr lang dev

wheat mesa
#

discord snowflakes are usually bigints

crystal wigeon
#

ayy dont be rude

sharp geyser
#

Anyway I'm going to sleep

#

Waffle is my friend

#

It's fine if I bully him

crystal wigeon
#

ayy

#

no one:
js when it sees big numbers: EMJ_SagiriOhNo

#

weird

#

im not even converting it to number

#

its a plain string

#

okay nvm forget everything i said

#

the id is correctly being passed

earnest phoenix
#

As long as the machine has enough memory for it

wheat mesa
#

I thought js handled everything as 64 bit :C

#

Or is that messy because of v8 object overhead and such

earnest phoenix
#

A little bit really, IIRC the numbers were held back from being converted to 64-bit floating point numbers because of not only heavy memory usage, but also some backwards compatibility shenanigans, I don't exactly remember what it was

wheat mesa
#

wtf my lexer broke with 5 + 5

#

lmfao

#

I'm stupid 🤦‍♂️

#

forgot to emit null terminating byte

celest shard
celest shard
sharp geyser
#

gj

wheat mesa
#

it's because I forgor to check if I was at the end already

sharp geyser
#

Damn

barren fox
radiant kraken
#

so he's wrong, it's actually 64 bit floating numbers

radiant kraken
cinder patio
#

Isn't it actually 2^53 for JS

radiant kraken
earnest phoenix
# radiant kraken so he's wrong, it's actually 64 bit floating numbers

Invalid, JavaScript normal numbers (not bigints) cannot exceed 32-bits precision, and they're only 32-bits in general, only bigints can go beyond that precision, not only that but the JavaScript API bindings provided for Rust using something like napi-rs actually provides them as f64 for bigint usage and conversion when needed

#

Don't pull out random things from napi-rs, it's not really as complaint as N-API C++ bindings which are native and recommended

cinder patio
radiant kraken
#

Look at the v8 documentation - it clearly says double

earnest phoenix
#

Double != 64-bits

cinder patio
#

you're both wrong

sick agate
#

it was indeed old

radiant kraken
#

you haven't seen documentation for older C/C++ projects from the 90s

sick agate
#

¯_(ツ)_/¯

#

i meant the versions

#

v8 3.11.10 (node 0.8.28)

radiant kraken
#

oh right

#

i thought you meant the look of the documentation

sick agate
#

i mean it also feels like that but meh

earnest phoenix
# cinder patio https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects...

There is a reason behind this actually, the JavaScript numbers are technically considered 32-bits, both internally and in the specification, but the value exceeds beyond the actual max value of 32-bits that it can ever represent is because JavaScript numbers are not integers, since they're double-precision floating-point numbers specified in IEEE 754, the largest integral number is chosen for this case specified in the ECMAScript specification
https://tc39.es/ecma262/multipage/numbers-and-dates.html#sec-number.max_safe_integer

earnest phoenix
#

I never said they weren't a double, they indeed are

radiant kraken
#

so they're 64 bit floating point numbers

earnest phoenix
#

It does not count as a 64-bit floating-point number if the max value of the aforementioned numbers are far from reaching the actual max value of 64-bits

radiant kraken
#

??? but their size are 64 bits

#

there's a reason why double is f64 in other languages

earnest phoenix
#

The maximum safe integer in JavaScript is 9,007,199,254,740,991, but the max value of 64-bits is 9,223,372,036,854,775,807, now think about that for a little bit

radiant kraken
#

I'm NOT talking about 64-bit integers

earnest phoenix
#

It does not matter whether you're not talking about integers or floats, JavaScript numbers are NOT 64-bit floating-point numbers, even the 64-bit floating-point numbers' max value is way bigger than the ones on JavaScript

radiant kraken
#

then how are they represented as double in v8

#

which is a 64-bit floating point number

#

the documentation in MDN clearly stated that they are double-precision floating point numbers - which is a trait of double

earnest phoenix
#

You're completely misunderstanding all of this, the ones shown in V8's documentation has nothing to do with the JavaScript side, these are just the types you have to use in the C++ side to work with V8's APIs, but the values you provide does not get piped to the JavaScript side, there are a shit ton of conversion that happens behind the scenes

#

And as such in this case, a double type in the C++ side passed to V8's API does not necessary make the numbers in the JavaScript side a double entirely, there are once again conversion you're not even aware of

radiant kraken
earnest phoenix
#

I don't think you get it, JavaScript numbers are partially a double, not entirely

#

What MDN is trying say is that they're a type of double, but partially; since only the largest integral number is used as the max value

#

But I understand your confusion, a lot of people get confused by this and there isn't an exact way to explain this

#

Are you even reading what I'm saying?

earnest phoenix
#

By my statement, THEY are a double, but PARTIALLY, not ENTIRELY

#

I do not know how to put it simpler than this

winged temple
#

sorry @radiant kraken but voltrex is right

earnest phoenix
#

how to make something like this

#

showing server count

dry imp
quartz kindle
earnest phoenix
quartz kindle
#

it isnt tho?

earnest phoenix
#

Wait oh I think I'm also misunderstanding this, the way they worded it was pretty confusing

quartz kindle
#

there is a big difference between floating point and integer

#

53 bits is the maximum size of an integer that can fit inside a double

#

after that it loses precision

#

but floats are designed to work like that, with unexact precision

earnest phoenix
#

Yeah I know, I thought they were talking about something else

#

God all this got so confusing pretty quickly ngl

#

More confusing than when Bae asks for help

quartz kindle
#

lmao

radiant kraken
#

thanks tim

#

i knew it

autumn haven
sharp geyser
sharp geyser
#

Never doubt tim

quartz kindle
#

nah ive been wrong many times before and will be many times in the future

radiant kraken
#

:^)

boreal iron
#

true

surreal sage
#

Working on dual support for slash commands and regular messages (Irrelevant)

Getting this error, I log the data (interaction.options.data) and it logs normally but the error still pops up

#

I think I know the issue

#

I don't have a check if the message comes from a bot (Relevant to the Irrelevant)

sharp geyser
radiant kraken
solemn latch
#

wth is a record? notlikenoot

pale vessel
#

An object!!!

solemn latch
#

oh, it literally is just an object

pale vessel
#

I thought you were being sarcastic

solemn latch
#

no, I've never actually noticed records.

I'm sure I've interacted with them, just treating them like any other object

pale vessel
#

My code abuses Record<string, any> so much

neon leaf
#

Does someone know if you can access interaction.user.id before this? (discord.js v14)

pale vessel
#

You can't

neon leaf
#

thanks!

pale vessel
#

That's the option description?

neon leaf
#

I just wanted to know if I could translate that part, isnt possible then, right?

pale vessel
#

Translate, sure

neon leaf
#

On User Preference

pale vessel
#

Like supporting multiple languages?

neon leaf
pale vessel
#

I'm not sure if it's supported in discord.js, but iirc interaction locales are released already

neon leaf
#

Thanks, Ill look into it!

pale vessel
#

No problem

neon leaf
#

Looks like it isnt in discord.js yet, Best Option is to probably wait, Localization can always wait 😄

pale vessel
vivid fulcrum
#

damn already

#

i remember discussing how content localisation to the end user isn't ever going to be possible like in 2018

#

i am proven wrong

sharp geyser
#

And do lookups normally

boreal iron
#

Aka don’t use builders freerealestate

sharp geyser
#

Just gotta account for the localized names in your handler

#

Does discord have an option to set the language of the discord server or is it based on user's preferable language

#

I haven't looked much into localization on discord

tacit cradle
#

Hm is anyone having a problem with message collectors in the new discord.js release?

#

I've had a script that checked for certain messages in a text channel but now it's not working

#

It doesn't seem like the collector.on("collect") event is triggering

#

The "end" event seems to be working fine

#

I can't see anything about it in the documentation

#

So I'm confused

dull quest
#

I will see next time I Update my discord.js version.

pale vessel
#

Check your filter function

tacit cradle
#

I set it to just return true and it still didn't trigger the event

#

So I doubt it's anything with the filter

#

Okay I found the fix

#

Apparently when I was updating the code I forgot to include the "GuildMessages" intent

#

and that was the reason why it couldn't read them..

dull quest
#

MessagesIntent Permission will not be so ubiquitous in the future.

tacit cradle
#

Yup that was it

#

Took me a bit longer to notice that

eternal osprey
#
let member1 = message.mentions.members.first()
let member2 = message.mentions.members.second()```look i might be the dumbest person around, but how would i get a second mention lol
#

wouldn't it just be message.mentions.members[1] or something?

lament rock
#

that could possibly work as Collections are iterable, but if it doesn't you need to get the second key from the key array and pass that to Collection.get

eternal osprey
#

i see, thanks papi

pale vessel
#

Could also do message.mentions.members.first(2)[1]

#

Get the first two and pick the 2nd one

quartz kindle
#

afaik it should be .first(2).last()

#

actually collections now implement .at()

#

so you can just do .at(1) to get the second item

pale vessel
#

I c

#

It was array last time too

#

But I haven't used collections in a while

quartz kindle
# pale vessel

hmm maybe they changed it at some point to return arrays, but i remember it used to return a collection

#

havent used collections in ages either

ancient nova
#

what's yall opinion on this:
the urban dictionary commands should only be executed in a NSFW channel

sudden geyser
#

I'd argue it depends on you—whether or not you accept "better safe than sorry" or "most definitions are fine" as an answer.

#

I personally like urban dictionary commands to be available outside NSFW channels for the latter reason, along with the service not being explicit in general.

#

It seems like they've been purging a lot of explicit definitions as well.

#

although I liked some of the old ones

ancient nova
#

yeah, though discord forced me to enable them in NSFW channels only even though I've explained that I had a feature that the admins had to explicidly toggle the command before use

#

do you think they misunderstood and it would be safe for me to remove that?

sudden geyser
#

Discord typically rejects toggles provided by the bot as an answer.

#

For example, I wanted an /anime command I was developing in DMs to have a toggle for unfiltering NSFW entries but that was discouraged since DMs aren't technically NSFW channels.

#

So you're better off not using the toggle as a form of consent.

ancient nova
#

so I mean should I keep the nsfw channel check or remove it?

sudden geyser
#

Probably keep it.

ancient nova
#

I see

solemn latch
#

If discord staff told you to lock it to nsfw you should

ancient nova
#

yeah I didn't actually plan to remove it. Was just curious about what yall think

solemn latch
#

It feels weird, but maybe discord is being more strict about it.

ancient nova
#

btw does this look ok or should I try formatting it differently?

lyric mountain
#

2 years have passed, much has changed

lyric mountain
ancient nova
ancient nova
lyric mountain
#

probably

#

not the full emoji, but the unicode version

#

as in, not ❌ but \❌

ancient nova
#

hmm I don't think that would look as good

#

do you guys think having a switch case is better rather than multiple else if statements?

earnest phoenix
#

Generally yes, but if it's just a few comparisons, it gets optimized to be the same as the switch statement, so not much difference if you don't have a lot of comparisons

ancient nova
#

wait @earnest phoenix I do agree with you but

#

YOU CAN'T have variables in a switch statement? why is this the first time I've ever heard of this?

earnest phoenix
#

You can have variables in switch statements, but in the case blocks, not outside of them

ancient nova
earnest phoenix
#

Can you show more of the code?

ancient nova
#

perhaps I structured it wrong? I've got no idea

earnest phoenix
#

Does ESLint still complain about it?

ancient nova
earnest phoenix
#

Then that's because your case block does not have a scope ({}) wrapping it, which causes the variables to extend beyond that case block

ancient nova
#
    switch (action.toLowerCase()) {
        case "edit": {
// CODE
        }
    }
``` like this, really?
#

first time I've ever heard of something like this lol

earnest phoenix
#

It's not needed, but it's recommended when declaring variables, so they don't conflict with the variables on other case blocks

ancient nova
#

I'll keep that in mind, never actually heard of this before

#

can you put anything after the break; statement?

#

I was hoping I can use it like a return; statement

earnest phoenix
#

For example

switch (foo) {
  case bar:
    const baz = 1;
  case biz:
    const baz = 5; // SyntaxError: Identifier 'foo' has already been declared
}
#

This is where not using scopes in case blocks can be problematic

ancient nova
lyric mountain
#

u can use {} anywhere u want if u must create a new scope

earnest phoenix
lyric mountain
#
{
  let abc = 1
}

{
  let abc = "abc" // doesn't care about the former declaration
}
#

useful if u couple with labels

#
scope: {
  let abc = 1
  if (abc < 2) break scope;

  // other code, wont run
}
ancient nova
#

how do I get defaults in JS again?

#

like if you have a switch statement and none of the options were the one you predefined I want to have a default option

#

case default: {}
gives an error

lyric mountain
#

where are u putting it?

#

it must be at the end of the switch

ancient nova
earnest phoenix
#

It just needs to be default: ... without the case

ancient nova
celest shard
#

hey @lyric mountain i was wondering, how do you go about caching the "books" on your pagination project? do you use (e.g) guava for caching or you do some shenanigans to make the book persist over reboots?

#

sorry for the ping, i'm making some changes to my project and i'm always sure i'm missing some important thing.

lyric mountain
#

like, I use a copy of the collection of Page (or InteractPage for buttons) passed to the function

#

so as soon as the pagination ends it becomes available for GC

ancient nova
#

wondering how to attempt doing a command cooldown?

celest shard
#

with book i mean the messages that have pages and such

#

so as soon as the bot restarts you can't pick from the list or go through the pages right?

lyric mountain
lyric mountain
#

although I might do something regarding that later on by serializing event metadata into the custom id

#

the major issue is that my lib isn't just for pagination, but for categorization and buttonization

#

(and lazy pagination)

celest shard
#

id of the buttons, you mean?

lyric mountain
#

yep

celest shard
#

cause those are restricted to 100 chars each

ancient nova
celest shard
#

afaik

lyric mountain
celest shard
#

fr?

#

damn

lyric mountain
#

lemme check

celest shard
#

well it's a race then though i'm pretty sure it's 100

lyric mountain
#

ah no, it's 100

#

then I just cant

celest shard
#

yeah i thought of that and discord.js said 100 chars

lyric mountain
#

I could use an sqlite file, but idk if it's any worth

celest shard
#

but could've been outdated

lyric mountain
#

I will tho add some handling for lost events so people don't get "Unknown interaction" error

celest shard
#

yeah i fire an event if the book cannot be found, though i do "workaround" the issue by making the library's firsthand purpose to create static precreated books with IDs

#

if buttons had 1000 char limit on ids though

#

i guess a link that takes you to a json file with the info to display would also work, add that to the ID and query every page

#

then hosting that locally and such, hm

lyric mountain
#

don't think it's viable

celest shard
#

i mean you'd still need to purge the cache so yeah

lyric mountain
#

you could use an sqlite database as a cache layer

#

since your case is purely text stuff

ancient nova
#
    // Lets write some code for our cooldowns.
    // I know some people gonna hate me for that, but as the code is going to be quite short, 
    // let's not put it in the functions module.
    if (cmd && container.cooldownCache.has(message.author.id)) {
        return message.reply({
            content: `${message.member} you're still on cooldown from the previous command!\nYou still have ${timeAgo(container.cooldownCache.get(message.author.id) - Date.now())} left.`
        }); 
    } else {
        container.cooldownCache.set(message.author.id, Date.now() + 3000);
        setTimeout(() => container.cooldownCache.delete(message.author.id), 3000);
    }
``` my first attempt at a cooldown? I mean it appears to work?
lyric mountain
#

serialize the entire thing and compress the bytes before storing in a blob column

celest shard
#

it's never quite perfect isn't it

lyric mountain
#

guava is...big

#

it adds a lot of bloatware to those who import ur lib

ancient nova
#

guys?

celest shard
ancient nova
#

there is a bunch of npms like this

#

besides I would prefer not to use a NPM package

celest shard
#

maybe it's better to just leave caching to the user

lyric mountain
#

setTimeout is a pretty bad option

#

considering your cache would have thousands of concurrent entries

#

I'd go for an optimized lib instead

ancient nova
#

can you give me a good library for it then? googling expiring-map npm gave me 100 different results

lyric mountain
#

grab the one with most downloads

ancient nova
#

which one do you use?

lyric mountain
#

I use java my boy

lyric mountain
#

there's also redis, but idk if it wouldn't be too overkill for that

quaint rampart
#

anyone know this next.js error?

next build

> Build error occurred
Error: spawn ENOMEM

quartz kindle
#

error no memory

quaint rampart
#

ik

#

but

#

i’m running it on a cpanel

#

my memory looks fine?

quartz kindle
#

usually cpanels and webhosts give you like 100mb of ram lol

#

because they expect you to run php most of the time

quaint rampart
#

nah it shows i’m using 179 mb out of 2

#

i have ran it up to 1.5 gb before so ik there’s for sure ram

#

there’s just some issue with it

quartz kindle
#

do you have any way of monitoring it live? like second-by-second changes

solemn latch
ancient nova
hidden gorge
#

keep getting this error

wheat mesa
#

You're not catching an http request that throws when it gets a non-successful status code

hidden gorge
#

oh

wheat mesa
#

403 means missing permissions btw

hidden gorge
#

well the code is provided by my hosting

#

it’s a server type

wheat mesa
#

¯_(ツ)_/¯

#

The stacktrace isn't from your code, it's from a package

hidden gorge
#

ok

wheat mesa
#

So either you haven't set something up correctly (the more likely option), or the package is broken

hidden gorge
#

i didn’t set it up

#

it’s from a hosting egg

wheat mesa
#

I don't know what that is

#

if you believe it's the hosting provider's fault, contact them

lyric mountain
#

had many issues with sedmelluq's, dropped the music thing entirely

#

it's just not worth doing music at all nowadays

hidden gorge
#

is there a way to get a list of servers my bot is in using py?

lyric mountain
#

weren't u using java?

hidden gorge
#

it’s another bot

lyric mountain
#

but oh well, just get the size of guilds collection

hidden gorge
#

My friend needs help

#

TokenError
at Strategy.OAuth2Strategy.parseErrorResponse (/home/runner/moonbotlist/node_modules/passport-oauth2/lib/strategy.js:373:12)
at Strategy.OAuth2Strategy._createOAuthError (/home/runner/moonbotlist/node_modules/passport-oauth2/lib/strategy.js:420:16)
at /home/runner/moonbotlist/node_modules/passport-oauth2/lib/strategy.js:177:45
at /home/runner/moonbotlist/node_modules/oauth/lib/oauth2.js:191:18
at passBackControl (/home/runner/moonbotlist/node_modules/oauth/lib/oauth2.js:132:9)
at IncomingMessage.<anonymous> (/home/runner/moonbotlist/node_modules/oauth/lib/oauth2.js:157:7)
at IncomingMessage.emit (node:events:402:35)
at endReadableNT (node:internal/streams/readable:1343:12)
at processTicksAndRejections (node:internal/process/task_queues:83:21)

#

// Login endpoint.
  app.get("/login", (req, res, next) => {
    // We determine the returning url.
    if (req.session.backURL) {
      req.session.backURL = req.session.backURL; // eslint-disable-line no-self-assign
    } else if (req.headers.referer) {
      const parsed = url.parse(req.headers.referer);
      if (parsed.hostname === app.locals.domain) {
        req.session.backURL = parsed.path;
      }
    } else {
      req.session.backURL = "/";
    }
    // Forward the request to the passport middleware.
    next();
  },
  passport.authenticate("discord"));

  // Callback endpoint.
  app.get("/callback", passport.authenticate("discord", { failureRedirect: "/" }), /* We authenticate the user, if user canceled we redirect him to index. */ (req, res) => {
    // If user had set a returning url, we redirect him there, otherwise we redirect him to index.
    if (req.session.backURL) {
      const url = req.session.backURL;
      req.session.backURL = null;
      res.redirect(url);
    } else {
      res.redirect("/");
    }
  });```
ancient nova
#

how can I get users discord badges?

solemn latch
solemn latch
#

passport-discord I assume, not just passport

quaint rampart
ancient nova
#

lol my ban comamnd is going to be 250+ lines long after the rewrite 🤣

solemn latch
#

👀 how?

ancient nova
#

I'm kinda adding everything I've recently added together into that one command. Meaning it checks for every permission, level and roles
then DMs the person
Logs the details
and sends the confirmation

#

the logic is about 150 lines long 🤣

#

and the embeds are the rest so 100~

solemn latch
#

🤔 most of that could all be done in a single handler once then reused between commands as much as you want

ancient nova
#

I can send you the code in DMs once I finish so you can see for yourself if you want

solemn latch
#

I dont think permission checks(even if it includes levels and roles) need to be unique for the ban command.

ancient nova
solemn latch
#

had to be unique to the ban command?

#

or unique to the bot

#

I guess my point is it would have taken you pretty much the same amount of time to write it in a way all your commands could use it if you felt it was needed.
that way if you ever want to use it for any other command it would be easily added to that command in a couple minutes.

boreal iron
#

Well the optimal OOP solution is a class related to your application to define functions like this you’re going to use in your entire project

#

(over and over again)

sharp geyser
solemn latch
#

I bet its pretty common to tbh.

sharp geyser
#

That's just dumb ngl

#

Just define the permission it requires in the command and check it in your handler

solemn latch
#

I dont think the djs guide covers it KEKW

sharp geyser
#

That simple

boreal iron
#

Not really, you don’t need to throw an error if just one permission is missing

sharp geyser
sharp geyser
#

You don't alert users when they/the bot is missing permissions?

boreal iron
#

For example my config command covers several options to adjust the bot for example just listening to specific roles, channels etc.
And it comes with the possibility to change its nickname which does require the ChangeNickname permission
Of course I only check for the permission when running the command

#

Why would I throw an error for the entire config command where only the nickname adjustment (sub command) requires a permission

#

While the command handler itself of course checks for user permissions when executing a command

#

But app permissions itself are still check whenever you execute stuff to ensure to have a proper error which permission might be missing

#

Instead of. hey, I need administrator permission please

boreal iron
sharp geyser
#

We were talking about handling permissions

#

People do it in the commands when they could just do it in a handler so they don't repeat code

boreal iron
#

Yeah that is just what I mentioned above

sharp geyser
#

I wasn't part of the conversation at that point and didn't notice

#

I always join conversations midway through

boreal iron
#

Not only in the handler but also inside a command it’s sometimes required to check permissions for parts

sharp geyser
#

Why would you need to ever check permissions in the command itself?

#

Your handler could easily do that for you

boreal iron
#

For the reason I mentioned above

#

For app permissions not user permissions

sharp geyser
#

You can have your handler manage both

#

That's what I did

#

When I made my own framework

boreal iron
#

That wouldn’t make sense in my specific example I mentioned

sharp geyser
#

I don't understand the example you mentioned

#

So

boreal iron
#

Confusing is happening again

sharp geyser
#

It's always confusing talking to you

sharp geyser
#

I'm not

boreal iron
#

I’m sure you write any of my words down as they are wise

sharp geyser
#

Your words are the opposite of wise

#

So yea

boreal iron
#

Shhh move on white name

#

These young people

#

smh

sharp geyser
#

You think that's an insult?

#

Why would I wanna be lumped with a bunch of bot devs

#

You guys are nerds

boreal iron
#

Sounds like green names doing bot development exclusively 24/7

#

I remember you had a green name in the past, too makes you one of us, one of us, ONE OF US

hidden gorge
#

i’m one of you guys

ancient nova
#

member.bannable doesn't work on people that aren't in the server?

#

how do then bots ban people that aren't in the server?

#

what???

rustic nova
#

hackbanning

#

using their id to ban

#

ignoring if the user is banned or not

ancient nova
rustic nova
solemn latch
wheat mesa
#

TRUE!

sharp geyser
#

The bot I submitted I sent 2-3h max and never touched it again

sharp geyser
near ether
#

how would i make a slash command that is inaccessible to all users but me?

#

i have a few administrative bot commands that i want to convert to slash commands, but i dont want regular users to be able to use them or even see them in the list of possible suggestions

pale vessel
#

Make it guild only then

#

Only post it to your private server

quaint rampart
#

anyone know alot about next.js? i get this error running next dev (only on my cpanel not locally):

ready - started server on 0.0.0.0:3000, url: http://localhost:3000
info  - Using experimental wasm build of next-swc
warn  - Attempted to load @next/swc-linux-x64-gnu, but an error occurred: /lib64/libc.so.6: version `GLIBC_2.14' not found (required by /home/<redacted>/nodevenv/<redacted>/14/lib/node_modules/next/node_modules/@next/swc-linux-x64-gnu/next-swc.linux-x64-gnu.node)
warn  - Attempted to load @next/swc-linux-x64-gnux32, but it was not installed
warn  - Attempted to load @next/swc-linux-x64-musl, but an error occurred: libc.musl-x86_64.so.1: cannot open shared object file: No such file or directory
event - compiled client and server successfully in 25.8s (601 modules)
earnest phoenix
# quaint rampart anyone know alot about next.js? i get this error running next dev (only on my cp...

Your machine has an older version of GLIBC instead of the required version which is 2.14
https://superuser.com/questions/537683/how-to-fix-lib-x86-64-linux-gnu-libc-so-6-version-glibc-2-14-not-found

quaint rampart
earnest phoenix
quaint rampart
earnest phoenix
#

GLIBC is a global library you have to install, not in the project directory, just follow the installation instructions, you can look them up with the specified version

quaint rampart
earnest phoenix
#

Before that, try running this and see what it says

$ sudo apt-get update > /dev/null && apt-cache show libc6 | grep Version
quaint rampart
#

alright hold up give me a minute

#

@earnest phoenix namecheap support is a joke man, i dont have root access so they have to fix my issues and she said "Regretfully, it is not possible at this moment, but we will upgrade it in the near future."

#

i pulled out the "ive been with u guys for 3 years and ive never seen such horrible support" and now she is trying to resolve it

#

LOL

earnest phoenix
eternal osprey
#

Hey guys, how do i migrate my slash command to an app cmd?

mint mulch
eternal osprey
#

is it not possible to add an option to a context menu? Just like a slash command

mint mulch
#

ah right, question was a bit vague

#

Not sure, I think the context menu just shows your app - not explicit options

earnest phoenix
quaint rampart
#

and that i’d have to upgrade my plan again even tho i did that yesterday just to try to solve this as well

mint mulch
#

shared hosting is pretty trash, cPanel more-so

#

is it server-side rendered next.js? or static

#

considered something like Vercel?

quartz kindle
#

just get a full vps and make your own webserver

mint mulch
#

VPS is overkill for a single website IMO, it just becomes another thing to maintain and security can be easily neglected

quartz kindle
#

then you have to live with those limitations

mint mulch
#

Shared hosting, or VPS? 😂 come on now, there's so many practical options these days

#

even Github pages is pretty good free static site hosting

#
  • Cloudflare workers (free tier) for any server-side logic
quartz kindle
#

once you go vps you never go back

#

:^)

mint mulch
#

😂 I went VPS and then back to running containers

#

VPS is just simple though, in a good way

#

I like the pain of doing things with complexity

#

(I used to work for a domains & web hosting company, can't stand cPanel at all now)

real crater
#

:D this is only meme please don't kill me

smoky mica
#

does anyone have a clue on how Dyno has the same command with a prefix and as a slash command?

quaint rampart
#

along side with a couple sub domains running node.js applications

smoky mica
quaint rampart
#

yeah slash commands arent enforced yet

#

end of this month is when u HAVE to use slash commands

smoky mica
quaint rampart
#

he could have 2 seperate folders

#

idk that makes sense to me

#

one with slash and one with prefix

#

or his interaction handler can just transform into the handler we are all used to like converting options to args and just using it that way

#

who knows but it doesnt really matter anymore

#

less than 30 days until we all have to use sash commands

smoky mica
quaint rampart
#

that doesnt make sense

#

something must be wrong on your end

smoky mica
#

probably, sometimes talking it out with someone helps. coming back to bot dev after like 2 years

#

and also im really disliking discord.js since the v12 update, eris seems to be a much better option

quaint rampart
#

yeah discord.js really fucked up from v12 to v13 tbh

#

so many changes

#

im not even don with my rewrite yet

#

and v14 dropped

#

lol

smoky mica
#

yeah, i had completely stopped developing my bot around the time discord.js v12 dropped and i came back to it after a few months just to maintain the code and realized so many things had to be written

#

and since then ive just been on and off with the bot dev

quaint rampart
#

yep it sucks

smoky mica
#

its horrible

quaint rampart
#

idk why discord.js insists on making it so hard for everyone

smoky mica
smoky mica
quaint rampart
#

well message content is an intent now and even if u have access to it its not made for commands so you need to convert to slash commands by the end of the month and if your bot has some soort of feature that uses messages then you need to apply for the intent

smoky mica
#

is there an FAQ link for this?

quaint rampart
#

yep

smoky mica
#

thank you

quaint rampart
#

i kinda like slash commands tho i just wish i didnt have to rewrite my whole entire bot for it but it is what it is

smoky mica
#

I wonder what the big bot devs are thinking about this

#

I think they gave like 2 years time to transition to this if im not wrong right?

quaint rampart
#

yeah but

#

see people like me procrastinate..

#

LOL

smoky mica
pale vessel
quaint rampart
#

yeah ive been using discord since 2016 so i agree

smoky mica
quaint rampart
smoky mica
pale vessel
smoky mica
#

i forgot i dont have nitro anymore pandasad

pale vessel
#

It's good to support both though, or try supporting only slash commands and make your users switch

quaint rampart
#

yeah im gonna support both then

floral mist
#

how do you guys go about logging errors for ur bot? Do you just have file that you write to during each error?

pine nova
#

use winston or create ur own logger weirdsip

floral mist
#

alpha, I've never heard of either. Time for some research ty

quartz kindle
#

i just console.log it

#

lol

dull quest
#

Hehe, like everyone else

dry imp
#

actually i use print()

hybrid cargo
#
console.log(err)
client.executeWebhook(blah, blah, blah blah)
solemn latch
#

I use a combination of console.log and logflare

carmine summit
#

is eval still dangerous if I only allow numbers and operators?

lyric mountain
#

yes

#

for that, use a math parser

lyric mountain
carmine summit
ancient nova
#

would anyone be up for stress testing my bot? I have a couple errors that I wanna fix but not sure where exactly they come from

#

my guess would most likely be permissions

civic scroll
#

when you no debug

boreal iron
#

Well when awaiting your promises and have some sort of error handling where’s the issue to debug things?

#

Might also be a good idea to log your errors to an error log file

#

Instead of seeing them fly-by in your console

ancient nova
#

yeah I am doing that

#

the console just doesn't go far enough back

#

I can see max 2 errors out of 100

#

blame pterodactyl

wheat mesa
#

use a logger or webhook for errors if your console doesn’t go back far enough for some reason

#

If you’re using pm2, you can type pm2 logs —lines 100 or something along those lines to view your logs for a specific amount of lines

ancient nova
#

I actually think I fixed all of them

#

all the errors

ancient nova
#

I'd still prefer if someone could stress test

#

just so I know everything works correctly

ancient nova
#

not even to embed or attach images permission

#

hence the errors and not even a single command could be executed

lyric mountain
#

people can do weird stuff with barely any operators

boreal iron
#

"nature finds a way"

#

somebody has watched Jurassic Park, I guess

lyric mountain
#

JS park

boreal iron
#

lmao

pale vessel
#

JuraSsic Park

ancient nova
#

anyone know CSS?

sharp geyser
#

Ask your question

#

Someone who knows the answer will answer

ancient nova
#

was trying to decrease the size of my image but it was blocked by a flex div above it

#

anyone know how to center this as well?

#

nvm found a way

wheat mesa
#

With css there’s always a million solutions to a problem tbh

#

Which is part of the reason why I hate it because I don’t know which one is the “proper” way to do it

ancient nova
#
<img height="35" width="30" src="https://cdn.discordapp.com/attachments/700590466277572698/1005157792128192582/svgviewer-png-output.png">
Add To Discord
quartz kindle
#

you can add margin to the img element

#

margin-right: 10px

ancient nova
# quartz kindle you can add margin to the img element

the button broke after I did that

                    <a href="https://discord.com/oauth2/authorize?client_id=973306610501947423&permissions=1530354068598&scope=bot">
                      <button class="add_to_discord" style="margin-inline-end:28px">
                        <img height="35" width="30" style="margin-top: 5px;" src="https://cdn.discordapp.com/attachments/700590466277572698/1005157792128192582/svgviewer-png-output.png">
                        <a style="padding-left: 10px;">Add To Discord</a>
                      </button>
                    </a>
``` only the image seems clickable now
quartz kindle
#

button inside a doesnt work

#

you can remove the button element and use css to make a look like a button

#

or you can use a button element with an onclick function

ancient nova
ancient nova
quartz kindle
ancient nova
#

Tim are you on mobile right now?

quartz kindle
quartz kindle
ancient nova
#

haven't actually tested yet

solemn latch
#

You can view sites as they look on mobile from your browser

civic scroll
#

are mobiles even real

solemn latch
#

f12 click the button that looks like a phone, its in the same spot on most browsers iirc

quartz kindle
#

pure hearted people dont know what mobiles are, they are not real for them

ancient nova
solemn latch
#

looks good

forest harbor
#

hey i cant figure out how to do something like this for my bot's readme

civic scroll
forest harbor
#

it appears like

#

even tho its the same readme as github

civic scroll
forest harbor
#
[<img src="https://github.com/laralove143/timezoner/raw/main/add_to_server_badge.png" width="113"/>][bot_invite] [<img src="https://github.com/laralove143/timezoner/raw/main/join_support_server_badge.png" width="146"/>][server_invite]```
#

how to inline

civic scroll
#

oh you just need to inline them

#

google

#

i don't work with markdown as much sadly

forest harbor
#

i dont get what you mean by inline

solemn latch
#

these two are inline

a b

these two are not inline
a
b

ancient nova
ancient nova
civic scroll
forest harbor
#

its just discord wrapping

ancient nova
civic scroll
#

tfw different markdown interpreters

ancient nova
#

maybe add some animations as well

forest harbor
#

if i make not even a space they appear on different lines but now stuck together

civic scroll
#

dashboard.bot.tld
docs.bot.tld

rose warren
ancient nova
civic scroll
#

why must you log in on an introduction page

#

💀

#

doesn't make sense to me

solemn latch
#

I have a weird scenario.

I'm using CF, Nginx, & next.js

When visiting the home page using the domain I get a 204, if I add a query string I get a 200 with a full response.
If I load a page other than the home page I get a 200.

If I load a page which returns a 200 the home page will also then return 200.

ie
example.com/ returns 204
example.com/?t=t returns 200
example.com/faq returns 200
IP:port/ returns 200
loading example.com/faq then clicking on a button that sends me to example.com/ will return a 200

Any ideas?
even of where to start to debug this issue.

I disabled the nginx default site and visited via the ip
IP:port/ returns 200

Wall of text time ^_^

civic scroll
#

me when idk network protocols

ancient nova
civic scroll
#

nah

#

i feel like

#

each application deserves its own domain

forest harbor
ancient nova
#

I need a better domain tho definitely 😭

civic scroll
#

because again there will be sub paths after the stuffs

ancient nova
#

I want to have something like butler.com but it costs 15k

civic scroll
#

so bot.tld/dashboard/guilds?params=args

#

💀ugly asf

ancient nova
#

people care about how a domain url looks?

forest harbor
#

tbh no

#

use whatever's more convenient

civic scroll
#

it's about how easy for it to memorise

#

and it's some reduced work for you

forest harbor
ancient nova
civic scroll
#

it's literally some cname adding

forest harbor
#

idk

#

cheaper than .com def

#

i got daybreak.wtf for free cos im student

civic scroll
#

.tk domain

forest harbor
#

is there docs on css support and all

ancient nova
#

gimme gimme rn

civic scroll
#

💀

#

perhaps sign up on cloudflare for a free domain

forest harbor
#

this is triggering me

civic scroll
#

it's fine

#

dw

forest harbor
#

but pain

#

i'll make it bigger at least

#

omg the hitbox is the whole line

#

what interpreter yall using

ancient nova
#

lemme see ur website 0_0

civic scroll
#

💀

ancient nova
civic scroll
#

my website

#

will kill your phone instantly

civic scroll
ancient nova
#

always either used a non secure connection or a premade provider

forest harbor
ancient nova
forest harbor
#

genshin website tbh

#

when ur phone can handle the game genshin at ultra but not the genshin website

civic scroll
civic scroll
#

my site ain't some static video playback

#

genshin website has minimal animations tbh

ancient nova
#

holy fucking shit

#

u made that by yourself?

lyric mountain
#

just stopped to think sayu, did u add bg music to the site?

forest harbor
#

this is the only way the gap looks acceptable

civic scroll
ancient nova
civic scroll
#

mmm

lyric mountain
#

background music

civic scroll
#

i don't know if i should

lyric mountain
#

to add to ambience

civic scroll
#

i'm not a music composer

#

but

#

i have the DAW

lyric mountain
#

aka svgs

ancient nova
#

why won't my iframe work?

civic scroll
#

the animation was pure math

ancient nova
#

god damn

#

that's so well made