#djs-in-dev-version

1 messages · Page 4 of 1

grim gate
#

Hey maksi any updates?

jovial cypress
grim gate
uncut kelp
knotty plover
#

Have they set their user cache to 0 or something

idle galleon
#

The client.users cache shouldn't affect data.recipients

knotty plover
#

But it can effect client.user right?

steel haven
#

No, as that is a real property on the client, not a getter from cache

knotty plover
#

Ahh

rain bramble
#

And probably that's the reason why the bot is in the array with index 0.

uncut kelp
#

Wasn't able to reproduce

#

In the case of a bot, API failed on the first call saying it couldn't send messages to the user
In the case of a user, it sent the message via an existing DM channel (API returns existing one) or a new one

uncut kelp
rain bramble
#

Only the first shard (ID 0) receive DM messages. Probably the message was sent in another shard and received in the first one where the channel isn't cached.

forest elm
#

yup, can repro

uncut kelp
#

Really

#

Honestly that sounds like a Discord bug

rain bramble
#

Why?

#

We just don't have channel object and can't recover recipients array fully

uncut kelp
#

Because of what you just said, we aren't sent the proper recipients

uncut kelp
uncut kelp
#

Ty for the help all <:

feral island
#

Whats new in DJS DEV

uncut kelp
jovial cypress
#

@grim gate @steel haven My bot has been online for 40 hours now. It's a bit short since I accidentally restarted it a few times while being too quick with my fingers in ssh and trying to just see the logs haha.
But it's not short for me as someone who spent the last few months always restarting the bot every few hours and always having to check whether its online. It's really nice not having to deal with that anymore.
I want to thank you two for your support on this matter because it really means a lot to me that this problem is finally fixed!

quasi dew
#

is v15 existed?

hoary fox
quasi dew
#

hm ok, just wondering

grim gate
scarlet tangle
#

Is it not yet possible to use .setNsfw on a slash command?

hoary fox
#

isn't it still in pr?

dull mulchBOT
cinder wraith
#

god knows what this means though

The pull request first appeared in @discordjs/core@0.2.0

jovial cypress
#

Hi I have a question, from the ddev server (screenshot below) it looks like sending a modal text input with .setValue() being an empty string is not allowed. but setValue doesn‘t allow undefined, so what do I do if there‘s one case where I do need a value and another where I don‘t? Why doesn‘t it work like embeds‘ setDescription()?

knotty plover
#

just dont set the value?

silent hedge
#

I assume they're conditionally removing it

#

in which case yeah its kinda scuffed we have no way to clear it

#

since you need to invert your entire control flow

jovial cypress
# knotty plover just dont set the value?

but.. how do i "just not set it" when as i just said there are cases where i want to set it. Like, if X is true, I want it set, and if X is false, then I don't want it set.

#

then the only way is to first make a variable, then (conditionally) edit the variable, and then put that variable into the modal. that is more lines of code, and less pretty, than being able to set it to undefined

uncut kelp
scarlet tangle
#

Will there ever be a utility function that allows you to check if member A can moderate/manage member B?

#

This is incredibly difficult for a beginner like me who doesn't know much about the role system etc. I bet I'm not the only one

scarlet tangle
#

So what exactly is included in dev? Is it just the PRs that are upcoming or what?

scarlet tangle
jaunty vault
dark minnow
#

*Updated on a daily basis iirc

jaunty vault
#

You can see the topic of this channel for the time of dev version releases (for your timezone)

copper sorrel
#

Hello @everyone

#

Can anyone let me know this?

#

when try to fetch data by time range in discord channel, how to set option by not iterating whole messages
channel.messages.fetch(options);

copper sorrel
#

where can I find interface of options.

plain roverBOT
#

Documentation suggestion for @copper sorrel:
interface FetchMessagesOptions
Options used to fetch multiple messages.

foggy fractal
#

Is there anyone available I can ask and see if what i want done with the discord bot could be done please
What i am trying to do is have a bot transfer tokens from discord to a google spreadsheet is that possible?

dawn phoenix
#

this channel is for questions about using the discord.js in-development version
we cannot help you with google sheets in this server, check out some of the general programming servers in #useful-servers or server discovery

limpid ice
#

how do i get my discord.js version?

knotty plover
#

Not a question for this channel, but you can check the version of a package in a project using npm ls

#

So npm ls discord.js

robust dew
#

is the new GUILD_AUDIT_LOG_ENTRY_CREATE Event planned or is it already a thing?

uncut kelp
#

It'll be added of course

#

(Why would it not be planned?)

robust dew
#

well the question is more if it was a thing yet

#

lmao

vital vale
#

i don't know why my userCount return Nan

#

could somebody help me?

jaunty vault
glass stirrup
#

How to use v-dev(15) ?

steel haven
novel oyster
#

npm ls discord.js

scarlet tangle
#

thanks

scarlet tangle
novel oyster
scarlet tangle
#

thanks

#

XD

knotty plover
#

Also kinda just doesnt work

scarlet tangle
#

The chalk

knotty plover
#

...uhhh yeah

#

I would not expect requiring chalk and calling it Discord to work

scarlet tangle
#

i dont can use console.log(chalk.red("hi")

knotty plover
#

That has literally nothing to do with discord.js, please stop

scarlet tangle
#

a okey okey, is only example

scarlet tangle
#

Just joined — this server looks so different than others (in a good way). As to be expected for a bot framework :D

#

Are there any examples of setting the default role shown with the RoleSelectMenuBuilder object?

snow crow
#

Not possible + not in correct channel

#

its a discord api limitation, discord.js has no control over that

scarlet tangle
#

Ah, unfortunate

#

I guess placeholder workaround works then

.setPlaceholder("Your role" + (role ? ` (@${role.name})` : ""))
snow crow
#

yeah

snow crow
grim gate
#

https://github.com/discordjs/discord.js/pull/9099
@steel haven
Hey, I was wondering why are we replacing the old codes. Also I am wondering how its going to be in a non breaking way if the codes are replaced. Maybe a client option to use @ws package?

knotty plover
#

Its exactly the same interface, meaning nothing user-facing changes

#

We're replacing it to be more efficient and reduce the number of issues from the old package, increase modularity

grim gate
#

oh, replacing is still breaking change I guess. But fine

knotty plover
#

No it isn't

tepid knot
#

Hi everyone! Not quite a djs@dev issue, but I think I've found a small issue with prism-media. TL;DR: prism specifies a peerDependency of "@discordjs/opus": "^0.8.0", but due to the way node-semver interprets the ^ caret, any 0.x version where x != 8 (ie, @djs/opus latest, 0.9.0).

This could be intentional- apparently a lot of authors treat 0.x versions as breaking, but given that every @djs/opus releases to date have been non-breaking, I would assume it's just an oversight.

Relevant gh issue: https://github.com/amishshah/prism-media/issues/109#issuecomment-1416383134

cinder wraith
#

Didn't npm 8 pull back on installing every single peer dep it found?

tepid knot
#

From the npm 9 docs:

In npm versions 3 through 6, peerDependencies were not automatically installed, and would raise a warning if an invalid version of the peer dependency was found in the tree. As of npm v7, peerDependencies are installed by default.

Trying to install another plugin with a conflicting requirement may cause an error if the tree cannot be resolved correctly. For this reason, make sure your plugin requirement is as broad as possible, and not to lock it down to specific patch versions.

Relevant doc: https://docs.npmjs.com/cli/v9/configuring-npm/package-json#peerdependencies

tepid knot
#

Also fwiw @djs/opus 0.9.0 wants prism-media ^1.3.4 in its package.json - but that's ||(technically, speaking strictly about package.json dependency versioning requirements - prism appears to work fine with opus 0.9.0)|| impossible as of the moment, because prism-media 1.3.4 does not accept @djs/opus 0.9.0

jade harness
#

doesn't seem like @discordjs/core is being published correctly on npm

#

It's not up to date with da new changes

steel haven
#

Because you view the stable version‘s code there, which is 0.3.0 which had that code… the dev version has the new code afaik

jade harness
#

Ahh, I gotta install @discordjs/core@dev then

fair marlin
idle galleon
fair marlin
jade harness
#

I have no idea where this error is coming from. I looked into ws and rest, and I can't find anything that points me in right direction

import { Client, GatewayDispatchEvents, GatewayIntentBits, InteractionType, MessageFlags } from '@discordjs/core'; // 0.3.1-dev.1675512288-8b70f49.0
import { REST } from '@discordjs/rest'; // 1.5.0
import { WebSocketManager } from '@discordjs/ws'; // 0.6.0

const token = '';

const rest = new REST({ version: '10' }).setToken(token);
const ws = new WebSocketManager({
    token,
    intents: GatewayIntentBits.GuildMessages | GatewayIntentBits.MessageContent,
    rest,
});

const client = new Client({ rest, ws });

client.on(GatewayDispatchEvents.InteractionCreate, async ({ data: interaction, api }) => {
    console.log(interaction);
    if (interaction.type !== InteractionType.ApplicationCommand || interaction.data.name !== 'ask') return;

    await api.interactions.reply(interaction.id, interaction.token, { content: 'Pong!', flags: MessageFlags.Ephemeral });
});

https://juan.evaded.tax/i/9qdgu.png

#

my guess is dependency clash

#

I updated the code to be reproducible

steel haven
jade harness
steel haven
steel haven
jade harness
#
$ npm ls @discordjs/core
deptest@1.0.0 C:\Users\Isidr\Documents\Programming\Node\deptest
└── @discordjs/core@0.3.1-dev.1675512288-8b70f49.0```
jade harness
#

yeah I figured lol

$ npm ls @discordjs/util
deptest@1.0.0 C:\Users\Isidr\Documents\Programming\Node\deptest
├─┬ @discordjs/core@0.3.1-dev.1675512288-8b70f49.0
│ └── @discordjs/util@0.1.0
├─┬ @discordjs/rest@1.5.0
│ └── @discordjs/util@0.1.0
├── @discordjs/util@0.1.1-dev.1675598630-405f940.0
└─┬ @discordjs/ws@0.6.0
  └── @discordjs/util@0.1.0```
#

I feel like if I install the dev version of /core, then it should come with the dev version of /util as well

steel haven
uncut kelp
#

Add it as an overrides

jade harness
#

ahh

#

alright cool thanks for the help guys!

hoary fox
#

Are we supporting endpoints that require oauth2?

tidal quest
hoary fox
#

and whole ApplicationCommandPermissionsManager

#

however the are rather exceptions
so i am asking if can we support more?

cinder wraith
#

what more do you want to support

hoary fox
#

there are many things
e.g. getting use info linked roles etc

cinder wraith
#

so oauth stuff that is in no way related to bot api?

hoary fox
#

adding members?

rigid haven
#

core has oauth iirc

steel haven
cinder wraith
#

adding members is part of bot api, which is why it's in d.js

#

it takes an oauth token as one of its params, but how you obtain that token isn't really a bot's concern

hoary fox
cinder wraith
#

what is

glad spoke
#

What does dev have that the regular package doesn't have

hoary fox
#

106 commits..., time for v14.8?

charred flicker
scarlet tangle
#

Have selection menus been added to the forms?

river onyx
#

whats the @discordjs/core

vague coyote
odd sail
#

has anyone used @discordjs/core with TypeScript?

I've created a function that handles a single options layer that is then passed down to the rest and websocket packages but it errors telling me I must define a return type, I've tried (options: ClientOptions): typeof createClient but as you can imagine it returns the function type which then errors on the return line.

Should I pass it as any or is there a more appropriate workaround? I've attached the current state of the function.

EDIT: Not sure what I've changed but removing the return type no longer throws off errors, I'm still curious what would be the fix for this issue regardless

rigid haven
#

doesn't /core have types?

hoary fox
#

core is written in typescript

forest elm
trail geyser
#
    const modal = new ModalBuilder()
      .setCustomId("ticket_modal")
      .setTitle("Ticket Request")
      .addComponents(
        new TextInputBuilder()
          .setCustomId("type")
          .setLabel("With kind of help you need? Please specify:")
          .setMinLength(10)
          .setStyle(TextInputStyle.Short),
        new TextInputBuilder()
          .setCustomId("issue")
          .setLabel("Explain your Issue/Question:")
          .setMinLength(10)

          .setStyle(TextInputStyle.Paragraph)
      );

    await interaction.showModal(modal);

ERROR:

DiscordAPIError[50035]: Invalid Form Body
data.components[0].components[BASE_TYPE_BAD_LENGTH]: Must be between 1 and 1521 in length.
data.components[1].components[BASE_TYPE_BAD_LENGTH]: Must be between 1 and 1521 in length.
trail geyser
#

Yeah I copied exact from there

#

just changed text and showing me this error

#

oh

#

actionrow builder

violet brook
#

Yes

trail geyser
#

ty

exotic rain
#

Why is ClientEvents not using the Events enum? 😔

uncut kelp
#

They don't contain each other fully. Like Events has raw, but we don't want to add typings for that because it's, well, raw

exotic rain
#

Hm okay

hoary fox
uncut kelp
#

Can still change the WebSocket/API version

hoary fox
#

dogeHaHa cool.... lol

steel haven
#

Also that PR links to a deleted ddevs announcement, so it probably had some reasoning that was later revoked

uncut kelp
#

Was probably the message after if I had to guess

steel haven
hoary fox
#

So i misread
However this intent is still useless

steel haven
#

It’s useless to provide when connecting to v9 gateway. It’s not useless to have in the enum

hoary fox
#

so we have it just to use it in api v10, which v13 doesnt use by default
makes a lot of sense

solemn robin
#

hello 🙂 Can I set range of roles here?

idle galleon
#

I doubt Discord has such thing

solemn robin
#

ahh

idle galleon
#

You should be able to select multiple tho

#

Give the min or max value is greater than 1

solemn robin
#

ahh unlucky, I wanted to give user option to choose only r1, r2, r3, thanks anyway

dark minnow
solemn robin
#

yee I know

dawn phoenix
#

often posted feedback in the discord devs server, that one (not being able to filter the selection at all)

solemn robin
#

it would be wonderful option tbh LIKE

dark minnow
#

Ngl, at least filtering by perms would be an awesome option

ornate solar
#

webhookeditmessage not in dev version?

uncut kelp
ornate solar
#

oh hello Jira :D thank you. will rectify & test

#

should i just... remove rate limiter for this test?

#

or can i import it directly from dev?

uncut kelp
#

That isn't by us

#

No idea what that is

ornate solar
#

it was looking for a higher ver of discordjs so i had to remove it but not sure how to proceed

uncut kelp
#

From a quick search, that package only seems to support version 12?

ornate solar
#

very useful. i'll implement that our next bot version.

had the same issue with dev - unresponsive to any server on shard 0. just shard 1. i'm going to reply on github

cerulean ledge
#

Is it possible to have a Select Menu in a discordjs Modal?

uncut kelp
#

No

cerulean ledge
#

Not 100% sure if this is the right channel

#

ok thanks

ornate maple
#

how do you make embed message if MessageEmbeded doesn't exist anymore?

cinder wraith
#

EmbedBuilder. v13 -> v14 update guide exists, it's in #djs-help-v14 channel topic, as that's also where you should ask this question afterall.

#

from deleted thread: updating to a newer major version should not come with a surprise when your code doesn't work. that's exactly why it's a major version change.

hoary fox
uncut kelp
#

I'm going to guess you have version 14 dependencies installed. So, when you moved to version 13, the versions of the linters are outdated and format differently on save

#

I nuked everything and ran npm ci on the version 13 branch and ran the format npm script and there were some changes, so it would seem that branch needs some formatting anyway

ornate solar
#

just wondering what shard related fixes happened in dev edition

clear harness
vague coyote
jolly condor
#

is localhost a valid redirect for oauth2 (for test/building)?

uncut kelp
#

You should ask that in Discord Developers

junior sage
#

Is there a limit to how many characters I can put in a slash command string option?

fluid bronze
junior sage
#

Oh, I didn't realise it was a different server. Sorry

feral island
#

Does this version have linked roles

knotty plover
#

Looks like those PRs are merged so yes

uncut kelp
#

I believe we have full feature parity in dev except for Text-in-Stage

half bone
#

is there any intention for djs 15 or future versions of djs to allow custom GuildManager/ChannelManager caches?

hoary fox
#

wdym?

half bone
#

well we aren't able to configure those caches in the same way that we can configure guildemojimanager, etc

#

unless I've misunderstood this

hoary fox
#

definitely you have
these objects are always cached ( with intents)
so you shouldn't change it

half bone
#

no, I know they're always cached—I'm asking if there's a plan to allow them to not be always cached

knotty plover
#

If you're at the point where you dont want to cache anything in discord.js there's very little reason to use the lib at all

#

Build something bespoke with @discordjs/ws and @discordjs/rest

half bone
#

that's fine—just asking if that was a goal on the roadmap, and it sounds like it isn't

knotty plover
#

Not a specific goal to my knowledge, no

half bone
#

alright, appreciate it

marble knoll
#

I want to know is there any api can do pop-up window in discord?

knotty plover
#

showModal, in response to interactions

marble knoll
#

got it, I will read the document

#

thx

brisk glen
#

can I install older commits for the specific mono-repo if the latest ones break a thing

uncut kelp
#

Why not

#

Also what breaks?

brisk glen
#

the whole ws breaks in the latest commits

#

just had the time to test it rn

#

on worker sharder strategy

uncut kelp
#

Are you talking about the ws package?

brisk glen
#

here are the things I encountered:

  1. setup worker on worker sharding completely fails due to buildStrategy option.
    (a patch solution is just don't pass buildStrategy to the worker)
    https://safe.saya.moe/j6lhb0hihuej.png

  2. random error on connect function
    https://safe.saya.moe/mztsxgkm1t7e.png
    further investigation shows
    https://safe.saya.moe/lgjojmyo6hmb.png
    this line is changed for some reason, you should not wait for ready here and should have just waited for hello instead.
    you didn't send any resume or identify messages yet, so ready will never fire

#

@uncut kelp yes ^ here is the issues I encountered so far

#

im not sure how it works on the latest pr if the ws shard itself dont listen to the right event, probably it was not tested enough(?)

silent hedge
#

this is great because I pinged both you and the person that opened the issue originally in the PR that made the timeout changes and i just got ghosted

#

either way, will fix both of those today

brisk glen
#

I was busy lately thats why I didnt respond there

#

I was not doing any code related things this past few weeks cause I'm busy attending things irl so sorry for that AsaTeeHee

silent hedge
#

is there any reason why you're using dev btw

#

dont remember what else is in the current milestone

#

prior to those 2 prs just now that broke it a little

brisk glen
#

if I remember correctly why I'm using dev, is because the error bubbling in stable is not fixed, so I just used dev and patched it there since technically I'm experimenting things just for my own amusement and just lately realized why I didn't patch stable instead

silent hedge
#

ic

#

yeah the pr that broke timeouts was trying to fix error bubbling lol

#

seems its just a bad last-minute copy paste though, thats meant to be a hello timeout still

#

i just happened to change that method like 5 times back and forth

brisk glen
#

sorry if I didn't respond on the github pr sooner, nor let you know I was busy, not really in the greatest moods this past few weeks to check the github emails

silent hedge
#

its alright

#

its why it was just merged anyway

#

its just dev

brisk glen
#

how to install your branch of that

silent hedge
#

its gonna be merged soon anyway, 2/3 reviews already

#

probs when space hops on

sturdy thorn
#

I was directed here to ask whether this was a bug or user error before submitting an issue, as I'm more likely to get a response, I'm using a stable build. discord.js@14.7.1

channel.permissionOverwrites.delete(sota_role, `Locking alliance server (${interaction.member.displayName} - ${interaction.member.id})`)

Is this the correct syntax for an audit log reason, according to the docs, it is, as far as I can see, I also tried making it an object, with the key reason like the 'create' function uses, to no avail, I'm not getting the audit log reason when using permissionOverwrites.delete()

I'm trying to find out if it's user error or a DJs issue, so I can submit an issue

uncut kelp
#

Have you actually tried fetching the audit log entry?

sturdy thorn
#

I haven't, I'll do that now to rule out DJS

uncut kelp
#

Yes, you should do that

#

It's a bug in the client. Everything is fine API-wise

sturdy thorn
# uncut kelp It's a bug in the client. Everything is fine API-wise
    '1079785475612614666' => GuildAuditLogsEntry {
      targetType: 'Channel',
      actionType: 'Delete',
      action: 15,
      reason: 'Locking alliance server (Exitium - 153102177429094400)',
      executor: [ClientUser],
      changes: [Array],
      id: '1079785475612614666',
      extra: [Role],
      target: [VoiceChannel]
    }

Yep, looks like it's an issue with Discord, thanks for getting back to me

uncut kelp
#

If I remember correctly, there's a bunch of events that support reason but the clients don't also. Just a fyi

sturdy thorn
#

gotcha, ty

green plume
#

I am using guildAuditLogEntryCreate event. So if I delete a channel it fires. Is it possible to get the parent id of that deleted channel?

steel haven
#

But no, you can’t because it will be purged from cache by then and the AuditLog entry doesn’t contain that information afaik

hoary fox
#

like you can use channelDelete
and then wait for entry create event

or you can cache deleted channel

green plume
scarlet tangle
#

Js is a complicated lang for beginners

#

even complicated than JS

steel haven
#

Keep off-topic out of support channels

scarlet tangle
#

oh sorry

#

thought I was in general

hollow sorrel
#

Just wondering where to find discord js dev branch in github ?

forest elm
#

its the main branch

hollow sorrel
#

ahh ty

jagged marsh
#

GuildMember.flags is undefined... per docs shouldn't that always be present?

uncut kelp
#

Looking at the code, it seems impossible

#

The more reasonable explanation is you're on an outdated version

jagged marsh
south dove
#

Is there any way to Pause / Unpause invites?

uncut kelp
#

Yes. You can already do this in version 14

south dove
#

How would you Do that?

plain roverBOT
south dove
#

Is it like a boolean for on / off?

hoary fox
#

yup like docs says

ornate solar
#

hi RE my github issue
its a v14 issue. i tested on v13

uncut kelp
#

What issue is that?

uncut kelp
#

Hello hello

ornate solar
#

ive also concluded the dev version does not address the issues sufficiently, as the problem did not go away on dev.
is there an ETA for the next minor version?

uncut kelp
#

I want to say soon but there's no real ETA

ornate solar
#

i understand. its just frustrating with 1000 users offline on a shard so trying to get a grip around a good solution. a lot of our new features rely on the core of v14, so its not really an option to temporarily downgrade

#

how long does it take normally? like a month? two months? longer?

knotty plover
#

I would hope not that long, we have a feature we want to release into v14.8 (Audit log events)

#

But we don't ever promise ETAs

ornate solar
#

yea just trying to get a ROUGH idea

#

i know what eta promises are like bahahah.
but even the shard fixes on dev rn dont suffice.

knotty plover
#

Well if the dev version doesn't fix it, neither will a new release

#

Unless theres an unmerged PR?

ornate solar
#

i haven't found a cause to be able to even file a PR

uncut kelp
copper flower
#

can i ask when will djs.15 come out?

cinder wraith
#

answer is the same as always: when it's ready

#

and in case of v15 for the moment, as far as i know it's not even really planned to be yet, so there's nothing to make ready

#

unless you're asking about v15 for some specific reason

copper flower
cinder wraith
#

i don't see it having "v15" in the name

#

it's just development version

#

made out of current status of the main branch

copper flower
cinder wraith
#

if there were some merged pull requests to the main branch that did not land in a v14 minor or patch release, they will be available to try out via the dev build

south dove
#

How can i read profile connections? / like connected twitch account

hoary fox
#
  1. not related to dev version #986520997006032896
  2. even not releted to djs as you need to use oauth2
rigid haven
#

/core does have oauth2

hoary fox
#

not sure if we can count it
but yeah it has

knotty plover
#

I mean you can do it with /rest too

scarlet tangle
#

when v15 dev

keen abyss
knotty plover
ornate solar
uncut kelp
#

Like?

rose heath
#

some new unusual things too

uncut kelp
#

I was able to run it without issues

ornate solar
uncut kelp
#

Probably not but what's more promising is Qjuh's pull request

ornate solar
#

jeez every time i interact with you you're around

#

is that pull request not part of 14.8?

uncut kelp
#

I'm sorry

#

No

ornate solar
# uncut kelp I'm sorry

hahahah don't apologise, get some more rest (idk where you live though)

we'll try the pull request and i will keep you posted - was a recent one also made on this?

uncut kelp
#

Uh-huh

#

Qjuh's branch replaces the current WebSocket implementation with our new one (in a non-breaking way)

ornate solar
#

and it seems to be functional on multiple-sharded bots?

uncut kelp
#

I would hope so, but the only way to know for sure is for people to try it out

#

I don't possess such a bot personally :c

#

My lowly bot for a single guild runs alright on it

ornate solar
#

😂 gotcha - I’ll keep you posted through tomorrow 👍🏻

uncut kelp
#

(:

steel haven
#

I also tested it on a sharded bot, but a sample size of one is not enough, so yes, please test it more

ornate solar
#

@uncut kelp hi sorry to disturb, 14.8 issue?

uncut kelp
#

Yeah TypeScript changes aren't breaking, but that is the correct type

ornate solar
uncut kelp
#

No I mean what it suggested is the correct type!

ornate solar
#

oh!!!

#

sorry i thought you meant it can be overriden. did it get renamed? because editmessageoptions existed

rigid haven
#

wait- how does fetchmessage have the same options as editmessage

uncut kelp
#

Yeah it got renamed into what you see

ornate solar
#

got it

uncut kelp
ornate solar
#

looks like a simple name change didn't suffice

rigid haven
uncut kelp
#

Oh

#

No it's WebhookMessageEditOptions lol oops

#

I didn't read it clearly enough T_T

ornate solar
#

o m g

uncut kelp
#

:D

#

I don't think you need to do let options: <type> there (also looks like it's not reassigned)?

ornate solar
#

well it did build

uncut kelp
#

What I mean is, you don't need to explicitly type it there, because it checks the type in the method instead

ornate solar
#

so that's something

ornate solar
uncut kelp
#

An ex you'll never forget

ornate solar
#

Ok, so the shard crashes exactly every 24 hours, so you two will know by tomorrow evening if it doesn't like 14.8

uncut kelp
#

Not sure I have high hopes

clear harness
uncut kelp
#

Yes

ornate solar
uncut kelp
#

(;

long wadi
#

Just wondering what is in development for djs rn like in the development version

lilac valley
#

Does each shard have it's own limit ? So 50/s requests per shard.

knotty plover
#

I dont think so, no

lilac valley
knotty plover
#

They dont have only 50

#

At 250k guilds you can apply for larger rate limits

#

Not sure how these questions are related to discord.js development though

scarlet tangle
rain bramble
#

Using @discordjs/core yes, but not discord.js

scarlet tangle
scarlet tangle
uncut kelp
#

Perhaps best to keep your thoughts at bay. They aren't particularly helpful

slate mango
scarlet tangle
steel haven
#

It can be used for it. The PR you mentioned just doesn’t provide any additional stuff to help you with doing that

pallid ice
crystal adder
#

I had a question, what led discord.js to use async_event_emitter? Is there something wrong with Node.js included events module ? I would like to know. Not sure where to ask this, sorry if not the right place

woven grove
#

web

scarlet tangle
#

Is v15 not coming?

turbid pier
idle holly
#

Nahh

trail geyser
#

Hey I have issue if someone can help me

steel haven
trail geyser
#

ok ty

clear swan
#

Can’t wait to fix breaking changes again 🥰

latent trout
#

Have select menus been added to modals yet? 🚶‍♂️

uncut kelp
#

Nu-uh. You can inquire about the state of feature requests in Discord Developers, though

solemn sparrow
#

Is there going to be any updates towards the redis-collection PR? It'd be nice to have this as an option for making caches cross-shard friendly.

dull mulchBOT
uncut kelp
#

Probably not

silent hedge
#

no this implementation is like, not good at all, lol

solemn sparrow
#

is anyone working on a super reactions PR?

uncut kelp
#

People always create upstream pull requests of work-in-progress features despite Discord explicitly stating to not do so. So dumb

hoary fox
solemn sparrow
jagged root
#

anyone work on the soundboardFeelsBadMan

dull mulchBOT
scarlet tangle
#

i need help with discord.js@12

rain bramble
unreal smelt
#

Hello when version 14.10.0 will be available please ?

hoary fox
#

when it's ready

unreal smelt
#

okay

#

Thanks

scarlet tangle
#

when is going to be released v15? this year?

steel haven
#

When there’s changes that are breaking to the point they need a major version increase.

scarlet tangle
#

okay! thanks!

digital root
#

it includes ts rewrite right?

#

exported typings are pain

steel haven
#

What’s a pain about them (other than for the devs that need to keep them up-to-date)? And ts rewrite has no version number. It’ll happen when it‘s ready and whatever the next major version is at that point will be it

cosmic cedar
#

Hello, a bot of mine that I keep active is running on version 1.0.0 Discord.are there any codes that work with version 1.0.0 from js's Github site? (The reason I chose this version is because most content producers use version 1.0.0 and I can't learn about other versions).

rain bramble
cosmic cedar
tame gazelle
cosmic cedar
#

A very strange moderator is deleting what we have written.

#

🤨

steel haven
#

This still has nothing to do with the development version of djs. Which this channel is about. So blobstop

remote otter
cosmic cedar
mystic lily
#

is discord opened gateway for soundboard

#

or is there is a way to use soundboard with bot

keen abyss
#

I believe there’s a pr about it

mystic lily
#

yes there is 2 pr in djs one for VoiceChannelEffectSend Event one for Sending VoiceChannelEffect

#

but i think we cant use them before discord opens gateway

#

(or can we??)

#

(also sorry for my trash english if you didnt understand)

steel haven
#

Bots can’t use them, no. The PRs are only for receiving data users sent that way

keen abyss
#

Ah, sorry ^

mystic lily
#

will they can use at future?

steel haven
#

Ask discord, we can only do what they release and they are the only ones that decide what to release

mystic lily
kind scarab
#

In the Managers (ChannelManager, UserManager, GuildManager and so on), shouldn't the return type for #fetch always be the non-null option? e.g. for ChannelManager it should be Promise<Channel> instead of Promise<Channel | null>

Or is there any case where it returns null? IIRC, if the channel doesn't exist, it will throw an error (which isn't a returned value)

uncut kelp
#

If the channel exists but discord.js does not have a structure for it

kind scarab
#

oh, like if discord adds a new type but my d.js version doesn't have it yet

#

interesting, ty

uncut kelp
#

The other two managers you mentioned do not have null as a return type

kind scarab
#

I was only on the channel manager and assumed it was a shared feature across managers, my bad there!

ornate solar
#

looks like breaking changes were released in a minor version?

uncut kelp
#

Adding something to a union isn't breaking

ornate solar
#

but the bot wouldnt start without it

#

that is breaking

boreal knot
#

Adding a new permission is not breaking shrug

ornate solar
#

again, the bot would not start without it

boreal knot
#

I dont know what you want me to tell you, breaking changes would be removing things, not adding things

ornate solar
#

i guess i just want to find out how to warn myself of this in future
but technically so. to each their own

rigid haven
#

just pin versions and use dependabot if you care that much

boreal knot
#

I mean it is annoying, I agree, but releasing a major version every time discord adds a permission isn't really..correct semver wise

#

plus technically its better to catch it, add the new permission, and carry on

ornate solar
#

yea no definitely dont do that bahahah
just need to make sure im keeping track however that process may be

boreal knot
#

I'm sorry for the annoyance haha, we had the same issue in Sapphire

ornate solar
#

lol no prob, comes with the job

boreal knot
#

took me a full minute to see the actually missing permissions KEKW

ornate solar
#

hahahahahah i had to parse it through trusty gpt. too many words

rain bramble
ornate solar
#

you have a point.

untold fulcrum
#

hello, do you know a host with db sql for bots? powerful but not too expensive either 🤔

haughty sorrel
untold fulcrum
#

oh i didn't see that thank you 😄

haughty sorrel
#

Of course

forest willow
#

is somewhere v15 docs getting updated i visited the website it says djs-next but the guide and docs still were for v14..

vague coyote
#

there is no v15 planned yet, so good luck finding it

forest willow
#

so release model is being switched to rolling release?

vague coyote
#

if there is no reason to release a new major version, then there wont be one for now

#

always has been like that

forest willow
#

got it, thanks!

scarlet tangle
#

when is automoderation coming?

knotty plover
#

What do you mean

plain roverBOT
knotty plover
#

It's already supported

scarlet tangle
#

is there anything about soundboards in making atm?

dull mulchBOT
tawdry needle
#

Does the "TSR" in some recent issues refer to a typescript rewrite?

#

Oh guess it is, only searched for messages here before asking

tepid mauve
#

Hey, think I've just discovered that InteractionColletor, which comes with InteractionResponse#createMessageComponentCollector()
does not take into account when the original interaction was a component interaction, thus collecting interaction that does not belong to the message.
on InteractionCollector.js:156

if (
      this.messageInteractionId &&
      interaction.message?.interaction?.id &&
      interaction.message.interaction.id !== this.messageInteractionId
    ) {
      return null;
    }

since the InteractionResponse was obtained by a MessageComponentInteraction, interaction.message.interaction would be null. (as I tested with ephemeral response for a button)
Since I don't fully understand how that check upper works, Im wondering if there's workaround, or a fix.

tepid mauve
#

well seems like I could just fetchReply to make it be a Message, for now.

formal kernel
#

you dont need discordjs/builders it comes with djs now
(also this shouldn't be in this channel)

sturdy breach
#

ow sorry it was a mistakee

vernal swallow
#

discord.js v15 ?

vague coyote
#

no

vernal swallow
#

oh ok

solemn sparrow
#

should there be a topic in the guide about the intents and what each intent does and the common methods that require the intent?

it feels like every time im in support, I answer at least 5 intents-related questions, some from the same users that come back a few minutes later asking about non-functional code due to an intent

plain roverBOT
steel haven
#

Already exists, especially the link to discord documentation under Enabling Intents. We don’t intend to duplicate existing documentation on discords docs, especially because they tend to add/change stuff and linking to that will always be up-to-date

south dove
#

How can i get a User with Id, would need a Tag or Username+Discriminator

hoary fox
#

it's not too easy to get id by a tag

cinder wraith
#

and isn't related to dev version anyway

still blaze
#

so in the next version we need to create the websocketmanager etc. seperatly ?

steel haven
#

No, the next version will use those subpackages (just like v14 already does internally)

still blaze
#

how to view the new docs for the main package

steel haven
#

Correct. Because mainlib isn’t TS yet, so their docs aren’t on the new site yet

still blaze
#

oh ok

#

is there example code for the next version

steel haven
#

No, because the next version doesn’t exist/isn’t even released yet

#

Only subpackages that will be used by it are

vast jasper
#

I've a question. From the side of performance, is it better to continue using discord.js v14 or is it better to use the @discordjs/core package and co.?

snow crow
#

they are different, but that isn't a question for this channel (this is about making d.js)

vast jasper
#

Oh, sorry, but thank you.

uncut kelp
ornate solar
uncut kelp
#

Okidoki <:

ornate solar
#

Im seeing all the shard issue responses to the GitHub and scared to update the version 😅

uncut kelp
#

;-;

steel haven
#

All those issues have one thing in common: using discord-hybrid-sharding third-party-lib. I got the feeling they relied on some internals that changed in 14.10.0.

uncut kelp
scarlet tangle
#

anything about uploading or using soundboards yet?

hoary fox
scarlet tangle
knotty plover
#

I don't think there's been any documentation from Discord on APIs to manage voice events

#

So it depends entirely on that

#

If there are APIs, we'll support them

snow crow
knotty plover
knotty plover
knotty plover
#

Ahh cool, thanks

#

TIL

solemn sparrow
snow crow
#

yeah, that where I remembered it from

snow crow
uncut kelp
snow crow
digital sequoia
slim wharf
#

linking an issue, which is orginally showing an issue with the djs sharding manager
If its working for sharding manager now, then it will work for hybrid sharding as well.

steel haven
slim wharf
#

But I would wait for the reproduction on v14.10 on the normal sharding manager

slim wharf
steel haven
slim wharf
slim wharf
silent hedge
#

so like, how many shards is this in a process

#

i have no idea how main lib sharding stuff works.

#

i just write /ws

slim wharf
# silent hedge so like, how many shards is this in a process

on djs sharding manager just 1? and internal sharding, it was like 30-50, then it got stuck on the destroy loop....

Tested with other libs and it worked with 224 in one single thread. So its an issue on djs side on how they process the events....

silent hedge
#

¯_(ツ)_/¯

#

this seems like a classic case of "not my problem"

#

/ws standalone works fine on the big bot token we have to test it

#

so i'll delegate this to @boreal knot

boreal knot
#

What's with me

#

What's wrong

#

Someone tldr me

slim wharf
silent hedge
#

lots of shards when using mainlib allegedly break it

#

but i have my fair share of doubt

#

either way, not my field, we both know /ws standalone behaved fine on either strategy with lots of shards

silent hedge
#

or alternatively keep snarky remarks to yourself

boreal knot
#

Well tbf we tested /ws with many shards, not mainlibs impl of it

silent hedge
#

yeah

#

all im saying is

#

that aint me no more

slim wharf
# silent hedge maybe write some better code and it'll be easier to make assumptions in your fav...

The lib is just a process manager, the only thing it depends on is client.on('ready'). It does not influence how djs handles stuff.
So my guesses are that upon a higher shard count on internal sharding there are some issues in djs as shown in the logs I posted above.
We have a lot of production users (<600k+ Guilds) and just one of them occurred an issue in form of an event emitter leak.
When you need me (for testing), just ping me, and if anyone else has that issue just tell them to use the djs sharding manager. Lets hope it works for them.

Anyways I am discussing probably in the wrong channel 👋

scarlet tangle
#

when djs v15 release?

uncut kelp
#

There is no ETA

steel haven
# slim wharf Used djs v14.11 and can reproduce a ws issue, it burned 86 sessions with destroy...

That code is an invalid usage of mainlib ShardingManager, because you pass shards property to the Client, so you use internal sharding and traditional sharding both at the same time, meaning you spawn all shards in all child workers. That’s supposed to cause issues because you now identify each shard several times. You shouldn’t pass shards: to Client options at all when using ShardingManager

silent hedge
#

lol

#

yeah that explains it

#

thanks qjuh

digital sequoia
#

so it only uses internal sharding

slim wharf
# steel haven That code is an invalid usage of mainlib ShardingManager, because you pass shard...

The reproduction above did not use hybrid sharding at all. It was tested with the sharding manager and internal sharding. Both had issues. Close code 1006 and Discord staff explained that it is a network issue. Which would explain that invoking internal sharding, causes an higher overload...

Btw, how is the code an invalid test? The shards: "auto" was commented out during the test with the sharding manager. (Sorry, I sent the code on a confusing way lol)

rigid haven
#

IMO, ThreadManager#fetchActive() should not exist. GuildChannel#threads.fetchActive() is very misleading, it looks like it’s only getting active threads in that channel, when in reality it’s searching the whole server. Should this be deprecated?

rain bramble
rigid haven
#

ooooh interesting

uncut kelp
rigid haven
#

hm

#

is the breaking change going to be reverted?

uncut kelp
#

Yes, it's just a bug

rigid haven
#

ok cool

uncut kelp
#

It does what it does now except filters the output to the parent channel lol

solemn sparrow
uncut kelp
#

Of course it's possible, but egh... helper methods

solemn sparrow
#

looks like a new guild feature was added, CREATOR_ACCEPTED_NEW_TERMS

#

thought the picture uploaded w the message Kek

#

theres no upstream PR for the feature on the api docs afaik

uncut kelp
#

It only matters what is documented

#

Everything else is irrelevant

sinful helm
uncut kelp
#

No, it's major

solemn sparrow
uncut kelp
#

I am confused reading that, can you just explain the issue

silent hedge
#

p sure this is correct

#

since dapi-types just follows docs

#

but this is unfortunate to say the least

#

does it work fine at runtime?

#

I'll assume so, either way, v v annoying

steel haven
#

The typings for parseEmoji function are just plain wrong... it returns id: Snowflake|undefined not null...

solid sail
uncut kelp
#

@velvet jasper maybe^

hoary fox
#

I agree, token in get should be in options, instead of other optional param

#

but changing it will be a braking change

solid sail
#

well there's already breaking changes merged for 0.7.0

#

it's 0.x.y and allowed by semantic versioning anyway

midnight plume
#

want to know, we should use discord.js/core instead of discord.js itself ?

snow crow
#

Depends on what you want, discord.js/core is the very core ws implementation and d.js has helper utilities and cache so uses more ram (for most people, discord.js is better as core is more advanced ||and is kinda in beta still v0.6||)

hoary fox
#

but definitely it is usable

#

it just requires more creativity

snow crow
# hoary fox but definitely it is usable

currently it works well for a basic bot (I am using for a bot status notifier - sends a message in channel when offline), but as it is new it probably is more buggy

solid sail
#

Supporting the api like this is a lot of repetitive work, which often results in some mistakes, so yeah right now there are problems sometimes

cinder wraith
#

problems? like what

solid sail
#

Mostly stuff like incorrect typings, not major problems

snow crow
#
  1. item 1
  2. item 2
1. item 1
1. item 2
forest elm
#

I don't see the problem, it won't even use the numbers you put there anyway, e.g.:

1. a
3. b
5. c

Still formats to

  1. a
  2. b
  3. c
rain bramble
#

You can even use

1. a
- b
- c
  1. a
  • b
  • c
snow crow
#

yeah, i know that you 'can' but i don't think it is the best especially as it isn't too hard to implement a proper approact

#

I am also saying not only old clients, but people may log the output and be confused why it is only one's (i know it isn't that much of an issue though - just wanted to check if it is really that good practice to do it)

mortal patio
#

any reason why search wont work on the new documentation site?

snow crow
#

ok, it is more weird with versioned packages (not main)

mortal patio
#

is the search handles by search. domain something?

#

its working now but when i wrote that the console was filled with errors

#

for that subdomain

#

i think it was 401

arctic lodge
#

Should AutoModerationActionExecution.channel typing include ForumChannel? Apparently you get a forum channel if the opening message or its title triggers the automod rule

uncut kelp
#

There are no messages in a forum channel. Are you confusing it with a thread channel?

arctic lodge
#

No i'm talking about forum channels
Creating a post in them might trigger the content rules
But if so, according to my tests, the AutoModerationActionExecution.channelId is the forum id and not the thread one
And the AutoModerationActionExecution.messageId might be the post id or null depending on which of the title and message content triggered the rule

#

For regular messages inside threads inside forum channels, i indeed get the thread id and the message id as usual

uncut kelp
#

Lol, I can reproduce this

#

Then I guess the answer to your question is yes, it should include forum channels

arctic lodge
#

That means if the post title triggered the rule, there is no way to retrieve the actual post message / thread
Would that mean it's also a bug on Discord side and not only in Discord.js?

uncut kelp
#

You will receive matched keyword, matched content, and content still

arctic lodge
#

I guess they consider post titles not being part of message then, thanks for the link

uncut kelp
#

Just as a caution, I looked at the raw request and message_id was indeed missing (even with the guild messages + message content flag)

#

It looks like the only issue here is that the channel should just have forum channels added to the types

dull mulchBOT
ocean flicker
#

Are there any plans to change User#tag in any following version

dull mulchBOT
ocean flicker
#

ty

haughty sorrel
#

Of course

jagged marsh
#

is useUpdate not fired upon global display name changes? I'm not sure if that is a bug with this wrapper or if it is a limitation with the official API

knotty plover
#

We havent released a version with support for global name changes yet

#

Are you using the dev release?

#

Support was merged 8 hours ago

#

A dev release was only published 2 hours ago

jagged marsh
#

yes I'm on the dev version

#

sorry, I assumed that PR merge would have included support for that change!

knotty plover
#

Only if you updated to the dev release 2 hours ago?

#

If so, we might need to review the user event filtering. Technically userUpdate is only for the client user - everything else is a guildMemberUpdate

#

But we redirect changes to the user object to userUpdate I think

jagged marsh
jagged marsh
#

it has to be done via userUpdate

knotty plover
#

No, it comes from GuildMemberUpdate

#

Well, from Discord

#

Discord emits USER_UPDATE for the current user (the bot) and GUILD_MEMBER_UPDATE for everyone else

#

But I think this is a bug, User#_equals doesnt check global_name

knotty plover
#

So we wont be emitting userUpdate on global name changes

jagged marsh
#

hrm I see, that is confusing that discord.js handles it differently

jaunty vault
knotty plover
#

Well, we handle it the way people would expect it to be handled, which is user object changes emit user update

jagged marsh
uncut kelp
#

Coolio

knotty plover
#

This assumes Discord emits an event at all on that change though

knotty plover
#

Otherwise theres nothing to check

#

Two components here

uncut kelp
#

Yeah what Monbrey said is definitely believable, don't recall seeing that being updated

knotty plover
#

I'll PR the change to _equals

jagged marsh
#

I'd assume discord emits an event on that change, but I'm not sure

jagged marsh
knotty plover
#

No idea

#

But _equals should check it regardless

#

IF an event is emitted, fixing equals will cause userUpdate to fire

jagged marsh
#

fingers crossed!

#

thanks for your help! :)

dull mulchBOT
jagged marsh
#

:)

copper latch
#

What is the difference between djs in devv version, and normal djs

haughty sorrel
haughty sorrel
#

Of course

jagged marsh
#

any idea what could be causing this?

at Object.makeRequest (node_modules/@discordjs/rest/dist/index.js:66:18)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async makeNetworkRequest (node_modules/@discordjs/rest/dist/index.js:651:11)
at async SequentialHandler.runRequest (node_modules/@discordjs/rest/dist/index.js:980:17)
at async SequentialHandler.queueRequest (node_modules/@discordjs/rest/dist/index.js:915:14)
at async REST.request (node_modules/@discordjs/rest/dist/index.js:1441:22)
at async WebSocketManager.fetchGatewayInformation (node_modules/@discordjs/ws/dist/index.js:1322:18)
at async WebSocketManager.connect (node_modules/discord.js/src/client/websocket/WebSocketManager.js:167:9)
at async Client.login (node_modules/discord.js/src/client/Client.js:226:7)

this error is only thrown in the production environment, not locally

#

and yes, I'm on the latest builders/rest/ws dev versions

uncut kelp
#

Wat

#

Are you using this in a browser?!

jagged marsh
#

why would you think that?

uncut kelp
#

What is your Node.js version?

jagged marsh
#

ah hrm, production might be different...

uncut kelp
#

Yes please double-check

jagged marsh
#

redeploying with node v18, fingers crossed

uncut kelp
#

You need Node.js 18.12.0 or higher

#

The reason why I asked if you were using this in a browser was because that error comes from when there was no native fetch API support in Node.js

jagged marsh
#

ah welp- when did that change? I'm not sure if the service I'm using supports higher than v18

uncut kelp
#

6th May 2023

dull mulchBOT
jagged marsh
#

ah I see

#

nevermind, looks like the service I'm using has the latest v18 version, so I'm in the clear

#

thanks for your help!

uncut kelp
#

You're welcome (:

jagged marsh
#

:)

green plume
#

I suggest adding another field which will show the globalName, and if it's null then it will show username. And for bot it will show Bot Name#discriminator.

knotty plover
#

Thats already in the dev version

naive vigil
#

kind of a dumb question but what version is this?

#

i know it's the developer version, but what number is it (ex: v14, v15, etc)

knotty plover
#

Its whatever number it needs to be

#

At the moment its a 14.12.0 because theres no major changes in it

naive vigil
#

alright thank you

knotty plover
#

If we add something that would be major / break existing v14 code, it has to be a v15

naive vigil
#

i was still using v13 until like a couple minutes ago so i just need to wrap my head around it

naive vigil
analog sable
#

what dev version should I use so tags do not appear?

#

like edinlol#0

hoary fox
#

look at pined messages to find out what it is
and yeah dev version already has support for new username system

analog sable
#

thanks

short cosmos
#

Using the new Discord.js system (@discordjs/core), is there the Color type or is that not going to be added for this update

uncut kelp
#

What is that type?

#

Oh

#

No, that's a helper

short cosmos
#

Oh alright!

#

How can I use it now? I looked through the documentation on the new site but could not find it

hoary fox
copper nymph
#

Is there a djs way to get the new displayname stat of a user yet?

sinful helm
copper nymph
knotty plover
#

It's user.globalName

snow crow
fading atlas
#

I don't know if this is where I ask about it, but here we go. I was testing @discordjs/core, but I ran into a problem (may be my mistake). When I use defer and try to reply again I get an Unknown Webhook error. I've tried both editReply and followUp and I still get this error

solid sail
#

show code

#

though i'm already going to guess that you might have passed the interaction ID instead of the application ID to editReply and followUp

fading atlas
#

Omg lol

#

Thanks ❤️

solid sail
#

no worries... happened to me at first too lol

fading atlas
#

Okay it definitely worked, ty again

shut edge
#

helloy, I've created script for ticket with slash command but idk what is wrong

#

It just says error when i interact

steel haven
steep kiln
#

Hey - Just wondering when we can expect global name to be in an official release?

steel haven
#

It‘ll be in the next release. We don’t give ETAs though

steep kiln
#

Like hidden away on some magic property 🤞

steel haven
steep kiln
#

Is there much risk? Currently over 100k users per day on our app 😅

steel haven
#

Well, it’s not guaranteed to be stable, it’s not a release. Using a dev version always is on your own risk… which is why I said if you need it that urgently

steep kiln
#

Right. Trying to weigh known vs unknown risk... guess we'll wait

#

And max out our oauth capabilities in the meantime

uncut kelp
#

If you use pnpm or Yarn, you could patch

marble dagger
#

for the upcoming version would there be a way to fetch a user with their username?

uncut kelp
#

The answer though, is no

solemn sparrow
knotty plover
#

Depends what it is I guess

solemn sparrow
#

just some phrasing and code changes for the new username system, theres a few things that still use .tag and .discriminator

knotty plover
#

Yeah that can go to the existing one

snow crow
#

can it be done for both?

knotty plover
#

I mean we're not going to release a new guide that's wrong

#

Obviously it'll be done for the new one eventually

#

But for now, the old guide is the published one where fixes like that belong

snow crow
#

👍 (i would react but...)

brazen knoll
#

since discord will stick with discrims for bots, will <user>.tag stay?

solemn sparrow
brazen knoll
#

so it'll just stay as deprecated until discord gets their stuff together

rough token
#

if that member have the new username

rigid haven
#

why is the dev release sometimes 14.11 and sometimes 14.12? there's currently one of each that aren't deprecated, but it looks like there's typically only the 14.11 release, so which should i use?

#

(also, what's the easiest way to download dev releases of subpackages?)

solemn sparrow
solemn sparrow
rigid haven
#

but @discordjs/builders for example is still the stable version

solemn sparrow
#

there are very few times where a dev version will use a dev version of a subpackage, if at all

rigid haven
#

hmm

#

ok so example: currently on djs@dev, User#defaultAvatarURL throws because calculateUserDefaultAvatarIndex is only in rest@dev

#

how would i install rest@dev when i don't directly depend on it? ideally it'd automatically use dev versions of subpackages so i don't have to worry about it

solemn sparrow
#

you can use

"@discordjs/builders": <version>
}```

in your `package.json`
rigid haven
#

hm, noted

wary wharf
#

Would this be the place to report bugs with the new guide?

velvet jasper
# wary wharf

We have an issue template on GitHub for issues relating to guide and website, you can use that

unreal smelt
#

Hello everyone, Will the Tag function be removed in the next version of Discord.js (14.12.0) ?

sinful helm
unreal smelt
cinder wraith
#

while correct, removal cannot be done without changing the major version, so it's quite impossible to remove it in 14.12

unreal smelt
cinder wraith
#

uhh, what?

unreal smelt
cinder wraith
#

what are you even talking about right now

rain bramble
keen abyss
#

Surely bots would still use .tag though? As discord said that wouldn’t be changing or something. Plus not everyone would change right?

cinder wraith
#

that's why it's deprecated

#

bots will eventually get moved onto their own system

keen abyss
#

Ah, just not atm

cinder wraith
#

and for users it's going to be useless the moment everyone gets migrated

rain bramble
keen abyss
#

Gotcha cheers

rigid haven
hexed lichen
#

Is there a difference between using .globalName and .username? Since I noticed .globalName can be null according to the types

cinder wraith
#

well, one is global name and the other is username

knotty plover
#

Yeah people dont have to set a global name

hexed lichen
#

ah, I see. So, global name refers to the default display name for all servers?

uncut kelp
knotty plover
#

Yeah its a little confusing

#

Since we use display as the prefix for our getters which dynamically determine nickname > global name > username and stuff

#

But the API property for that is "global_name"

hexed lichen
#

alrighty, thanks for the clarification blobSalute

sinful helm
#

What's the difference between <User>.globalName and <User>.username? From what I understand username is unique and globalName isn't?

rain bramble
#

Yes

sinful helm
# rain bramble Yes

Ok, so let's take your example. Your username will be syjalo and globalName would be Syjalo right?

rain bramble
#

Yes

rain bramble
#

There's <User>.displayName that returns the global name, or username if the user don't have the global one. Like <GuildMember>.displayName that now returns the nickname or the user's display name.

obsidian oriole
uncut kelp
#

You need to pin /rest to its dev version

obsidian oriole
uncut kelp
#

No problem

copper nymph
#

Is there a change to how the statuses are set as mine keeps going blank after an hour or two.

steel haven
#

Pass it into client constructor to have it persist beyond restarts

copper nymph
#

I see.

#

So instead of client.on('ready') do it in the client = part?

#

Like this? (the intents are all listed because of testing, the prod version is more selective, not sure what happened to guildbans and what it was replaced with)

snow crow
#

put your let result = await bot.db.query( below where you define bot const bot = new Discord.Client({

copper nymph
#

fixed that

#

doesnt matter now, just tryna make it wait for the response before doing anything, but its not working.

copper nymph
#

This is not letting botConf[0] have anything, its not waiting for the DB to return a result.

copper nymph
haughty sorrel
copper nymph
#

Probably not... stupid promises, but thats the error causing the bot not to deploy now...

copper nymph
#

This isn't setting any presence

frank atlas
copper nymph
#

well it is when I change it to just presence (copilot error there, autocorrecting) but its not setting the status to DND

fierce lantern
copper nymph
frank atlas
copper nymph
#

Hmm it works now... But I had to wrap my entire code into a main

copper nymph
#

as it says in the docs

frank atlas
#

ok nvm im blind, ActivityType is use for activity not for status

copper nymph
#

you can see, not showing as dnd

#

but test is?

#

Unless there is a cache on this that updates on the bot slowly, cus now its dnd... Which is annoying.

steel haven
copper nymph
#

ah ok thanks

copper nymph
steel haven
#

Yes. But none of your questions are specific to the dev version. Use #djs-help-v14 for general v14 issues like yours

copper nymph
#

I thought this was changes to dev.

scarlet tangle
#

Guys,

i need help with the new name update for my djs 14.90 structure

i want to know which is the correct string to use the displayed name (not the global one), for example: to pull the name of a full user defined (originally), we use ${user.username}, or to pull the tag ${user. tag}, but how do I pull the name of the display that is the first to be displayed?

i want to do the test, but I don't know the correct parameter of the string, i say the display name

rain bramble
scarlet tangle
#

this string would already work to return the global name?

#

mainly, I want to do what is in this attachment

make a button and add the global name, but I don't know the correct string to pull it

@rain bramble

#

Nome Global = Global Name

#

but this was not what I did, I want to replicate it in my bot

rain bramble
#

As you have said you're using v14.9 which doesn't support the new username system. It's currently onin the dev version. Property names in JavaScript are in camalCase, so it's <User>.globalName. Global name is nullable so there's <User>.displayName which returns the username if the user doesn't has global one.

scarlet tangle
#

But is there any way I can pull this property without the dev version?

#

I can assign the user part as a user if I create a ne variable?

#

variable for example:

const usuário - interaction.options.getUser('user')

steel haven
scarlet tangle
#

ty @rain bramble @steel haven

scarlet tangle
steel haven
scarlet tangle
#

ok

south dove
#

is there anything for usernames

plain roverBOT
#

Documentation suggestion for @south dove:
property User#globalName
The global name of this user

south dove
#

How can i install the latest discord.js dev?

vague coyote
#

channel topic

south dove
#

Ah got it

#

So Display Name is .globalName and .username is now the username (ipexa) ?

vague coyote
#

yes

south dove
#

Thanks, so then i just replace .tag everywhere with .username where i want the username (because it works similar then .tag) ?

#

If you understand what i mean

vague coyote
#

i guess

south dove
#

okay thanks so much

vague coyote
#

you could also just use user.discriminator === '0' ? user.username : user.tag

south dove
#

but i mean soon there is only going to be usernames

#

oh, but bots keep them

south dove
vague coyote
south dove
#

isnt that good? 😂

vague coyote
south dove
#

ok chef

south dove
vague coyote
#

well yeah

south dove
steel haven
south dove
steel haven
south dove
#

I try to reproduce it, I changed back to stable

oak tusk
#

When will the full version be released? (v14.11.1)

vague coyote
#

when its done, we dont do ETAs

light eagle
#

guys do you find the wording confusing? for the description of filterOld param

uncut kelp
#

Whether to only consider messages within 2 weeks
This would probably be a better description.

light eagle
#

Messages that are more than two weeks old will be automatically filtered out and removed.
i thought of this initially

knotty plover
#

All of those are still confusing imo

uncut kelp
#

I also thought of "Filters messages out of the collection that are older than 2 weeks"

knotty plover
#

There's no usage of bulkDelete that allows you to action messages older than two weeks. The Boolean to "filter" and "remove" only makes sense if you're passing a Collection of messages. It's misleading if you just give it a number

#

That one is definitely better, though not perfect

#

It's hard to find a way that doesn't imply you could not have the filter, and expect them to be deleted

#

What it's actually doing is "Ignore/filter messages which cannot be bulk deleted due to age" which happens to be two weeks

#

I'm not sure that wording is ideal either

light eagle
#

A

~~ Filters messages out of the collection that are older than 2 weeks~~
B
~~ Filters out messages of the collection that are older than 2 weeks ~~
~~which looks better/correct? ~~
i think we should provide that 2 weeks duration, just saying "can't be deleted due to age" might not be correct
nvm both don't feel right

solemn sparrow
#

"When given a collection, will filter out entries that are older than two weeks."

#

actually, seems like passing a number just fetches messages and calls the method again internally

#

was that option added because it would error if it was passed an older message?

steel haven
#

It does yes.

solemn sparrow
#

mmLol, interesting its false as default

cinder wraith
#

Yes, because if you tell it to delete 30 messages, it is supposed to try and delete 30 messages until you explicitly allow less

light eagle
#

Filter messages out from the collection that are older than two weeks. Keep in mind that disabling the option won't enable deleting messages older than two weeks

solemn sparrow
#

i dont think making it longer will make it easier to read

#

"Removes messages from being deleted that are more than two weeks old."

uncut kelp
cinder wraith
#

Considered?

solemn sparrow
#

I think a warning should be added for this method, saying that this method will error if there are messages that are older than two weeks being passed, unless you pass true to the filterOld param

cinder wraith
solemn sparrow
#

the wording on the methods docs doesn't hint to the method flat out erroring and not deleting anything if there is a message that is older than two weeks

cinder wraith
#

Well, it's a direct APIError, not our own

#

That should probably say why it isn't documented

solemn sparrow
#

should djs emit an error if theres a message in the collection that is older than two weeks?

uncut kelp
#

I would prefer we didn't

cinder wraith
#

Didn't we go away from guarding against such api errors?

#

Also, what's the difference anyway

uncut kelp
#

Saving a potential API call

cinder wraith
#

You have to do it anyway

#

Cause you did not delete anything

uncut kelp
#

It's just that we might as well do that across the entire library then we'd have like error checks in every single method and cba

solemn sparrow
#

it'd be a nice potential idea in a new major or rewrite

cinder wraith
#

:/

#

How would you even communicate why djs prevented the call

uncut kelp
#

And then there's the slight chance of the error no longer being applicable because Discord's API has modified something, and we have already fallen victim to that

cinder wraith
#

You have to parse the error somehow in case there is a number given (which isn't given by discord), and try with some other number again

uncut kelp
#

We threw an error if a server did not have the vanity guild feature if you're fetching the vanity URL, but along came server web pages and our error threw incorrectly 🙃

jaunty vault
#

Isn't this why we have the filterOld parameter...?

cinder wraith
#

Yes

solemn sparrow
#

love how this went from a phrasing issue to a topic on invalid api calls mmLol

cinder wraith
#

You started it 🤷‍♀️

solemn sparrow
#

fair

light eagle
#

Should we rename the param
bc filterOld can mean anything, filter in this scenario can mean we are reserving message s or ignoring the messages, it should be something which implies we ignore old messages.. something like ignoreOld i don't think ignoreOld is good though, but something similar is needed

solemn sparrow
#

could, but that'd have to go in a major version (or not, since its not changing the placement of the param)

rigid haven
#

is there a reason ThreadMemberManager#remove() doesn't take UserResolvable?

uncut kelp
#

No

topaz crane
#

I noticed that now <Member>.displayName shows server nickname or user display name or username respectively is that correct?
so no need to check for <User>.globalName if there's no member nickname

uncut kelp
#

so no need to check for <User>.globalName if there's no member nickname
You don't see the issue with this statement if you re-read it? A username, a global name, and a nickname are three different things

topaz crane
#

when I say or I meant that if the property doesn't find a nickname then it will check for a user display name, and so on.

uncut kelp
#

I wasn't responding to your question

#

But the answer would be yes

oak tusk
cerulean stag
#

Is it possible to make a feature with emojis for example, which indicates in real time the number of views of the last message sent?
For example on an announcements channel, a script in the bot, which when a new message is sent in the announcements channel, the bot adds a "👁️" emoji and a database adds in real time the number of times the message has been seen and the emoji counter increases according to the number of views?

rain bramble
umbral slate
#

Why was User#tag deprecated but User#discriminator wasn't?

#

I don't think tag should be deprecated while there are still accounts with tags