#development

1 messages ยท Page 814 of 1

pale vessel
#

cmon

golden condor
soft flare
#

just go away if you dont want to help

vernal yoke
#

Neko

#

Dont be rude

#

You asked in a channel of 30k+ members

golden condor
#

@quartz kindle It wasn't found

soft flare
#

i just asked how to make a js ex. kick.js i dont want to put it in Server.js

#

do you understand?

quartz kindle
#

@golden condor are you sure one of your packages uses a package called integer? And why do you need to know which one?

golden condor
#

That's what it says in heroku

zenith terrace
#

I said to go make a command handler

pale vessel
#

why

#

he can't even make an embed

vernal yoke
golden condor
#

It won't work with integer

quartz kindle
#

Where does it say that?

pale vessel
#

isn't this have something to do with node-gyp not being able to be installed

#

so it can't install integer

golden condor
#

My friend told me integer doesn't work with heroku

quartz kindle
#

I sense XY problem

#

@golden condor what is the actual problem?

vernal yoke
#

@soft flare a friendly advice. Please understand the environment and language you work with, read a bit and then ask questions about it. If you don't know at least the basics people won't spoonfeed you. And dont be rude with anyone.

soft flare
#

DONE

#

FINALLY

#

THANK YOU

golden condor
pale vessel
#

yeah node-gyp

#

i remember

golden condor
#

I checked for that

#

Don't have it either

pale vessel
#

node-gyp is a pain

golden condor
#
       > integer@1.0.7 install /tmp/build_277986059d589a07d563188433818e05/node_modules/integer

       > node-gyp rebuild``` this is what fails
vernal yoke
#

Yea gyp is a pain

#

Usually i apt install it on ubuntu rather than npm

#

But i guess on heroku you are not allowed

golden condor
#

i have no idea why it is doing this

#

What is the package 12?

zenith terrace
#

Wat

pale vessel
#

package #12

golden condor
#

Yes that

pale vessel
#

i was bullshitting

#

still don't know what you're talking about

zenith terrace
#

^

quartz kindle
#

gyp is likely not the problem

golden condor
#

Is it because I am using node 13 maybe?

pale vessel
#

heroku?

#

oh. can you try downgrading?

#

maybe to 12

golden condor
#

I am trying

#

Should I send the enitre log?

pale vessel
#

sure

#

hastebin pog

golden condor
#

?

pale vessel
#

try going through the troubleshooting page

golden condor
#

I'm doing it from github

#

How would I do that

pale vessel
quartz kindle
#

Are you using better-sqlite3?

soft flare
#

dude...

#

ITS

#

ANNOYING

#

GOD SAKE

pale vessel
#

what's so annoying

soft flare
#

let me call you

pale vessel
#

flaz

#

he legit called me

#

y tho

soft flare
#

he legit

#

join da call

pale vessel
#

no

soft flare
#

YES

pale vessel
quartz kindle
#

neko stop being annoying

pale vessel
#

No

soft flare
#

ANNOYING?

#

LET ME SHOW YOU

pale vessel
#

gachiHYPER

#

development only thankssss

golden condor
#

@quartz kindle I don't use better sqlite

quartz kindle
#

Im not gonna join your call dude

#

Stop calling people

pale vessel
#

wait he called you too

quartz kindle
#

Yes

pale vessel
#

why

soft flare
#

its just screenshare

pale vessel
#

what for?

soft flare
#

meh

quartz kindle
#

I dont want to screen share, plus im on mobile, dont wanna waste data

pale vessel
#

so you want to or don't want to

quartz kindle
#

dont*

pale vessel
#

wtf

#

oh ok

#

please calm down @soft flare

quartz kindle
#

@golden condor can i see your package.json?

golden condor
#

Yes

pale vessel
#

how do you pronounce json?

#

Jason?

sudden geyser
#

That's how I do it, except the O like "aw".

slender thistle
#

Each letter spelled separately

pale vessel
#

that's... unexpected

quartz kindle
#

I spell it j'son

golden condor
#

I say js-on

#

I say j s on

#

Actually

#

More like j'son yeah

soft flare
pale vessel
#

stop

golden condor
#

Tim I dmed you

quartz kindle
#

@golden condor why do you have node in your dependencies lmao

#

Remove it

#

Also remove anything youre not using

#

You have a lot of stuff that you probably dont use

#

Also, afaik quick.db uses better-sqlite3 which uses integer

#

What buildpacks are you using in heroku?

golden condor
#

What can I replace it with then

#

node.js buildpack

soft flare
#

damn i just want to make a command ex !help and display the Embed stuff!

#

but!!! its a error

pale vessel
#

put the command on where you put other commands

golden condor
#

it's a simple error

#

You forgot the end bracket of help

soft flare
#

i did...

#

i showed you in the viceo

quartz kindle
#

Also, afaik, heroku doesnt allow writing to disk

pale vessel
#

it does

quartz kindle
#

It uses sqlite under the hood which will attempt to store your data in the file system. On Heroku, that file system is ephemeral and your data will be wiped at least once per day.

golden condor
#

if (command === "help"){}

pale vessel
#

just temporarily

soft flare
#

ok i think i will use embed generator

pale vessel
#

most generators are old so change RichEmbed to MessageEmbed

golden condor
#

Oh well that's shit

soft flare
#

k

golden condor
#

I need the database

pale vessel
#

use a server?

golden condor
#

Like?

soft flare
#

do i need to put something in the url ?

pale vessel
#

no

golden condor
#

Idk how to use mongo

soft flare
#

k

pale vessel
#

everything is optional

#

but you just have at least one element

#

why not a normal mysql server?

#

that's what i use

golden condor
#

I dunno how

pale vessel
#

make a caching system

quartz kindle
#

Heroku has its own postgre database you can use

#

Check the docs

soft flare
#

here my Embed...

pale vessel
#

delete it

#

for god's sake

#

that's python

#

you're using discord js

#

my brainnnnn

soft flare
#

;-;

golden condor
#

How do you use postgre @quartz kindle

soft flare
#

mhm.hmh

pale vessel
#

i didn't know heroku have that

golden condor
#

I figured it out

quartz kindle
#

@golden condor i dont use postgre nor heroku, so i cant help you

pale vessel
#

the add-on is free nice

golden condor
#

I figured it out

pale vessel
#

interesting. how?

golden condor
#

IT WORKED

#

I looked it up

quartz kindle
#

^ thats how you do things

pale vessel
#

google is my best friend

#

stack overflow too

soft flare
#

nah embed is hate me

#

i will do something else

pale vessel
#

ok

soft flare
#

i ll thx cuz i just made a simply bot

#

can ban kick members

#

have some goods stuff

#

Who can tell me Clearly step by step can make a Category ex. Kick.js and Ban.js because i dont want to put them in Server.js

quartz kindle
#

google how to use module.exports

fallow mango
#

excuse me but can i get some help?

finite bough
#

@fallow mango on?

fallow mango
#

i keep getting this error

#

Traceback (most recent call last):
File "bot.py", line 126, in <module>
async def kick_member(Ctx, targets:Greedy[DiscordMember], , reason:Optional[str]""):
TypeError: can't multiply sequence by non-int of type '_GenericAlias'

golden condor
#

Help, it keeps disconnecting my db

soft flare
#

thx @quartz kindle

fallow mango
#

i keep getting this error
__
Traceback (most recent call last):
File "bot.py", line 126, in <module>
async def kick_member(Ctx, targets:Greedy[DiscordMember], , reason:Optional[str]""):
TypeError: can't multiply sequence by non-int of type '_GenericAlias

#

i keep getting this error
__
Traceback (most recent call last):
  File "bot.py", line 126, in <module>
    async def kick_member(Ctx, targets:Greedy[DiscordMember], , reason:Optional[str]""):
TypeError: can't multiply sequence by non-int of type '_GenericAlias```
slender thistle
#

eghm you send the same message three times

fallow mango
#

i know ;-;

#

oh i see it now

#

nope i was wrong

#

i have an , *, and it wont take that ๐Ÿ˜ฆ

#

can someone help me? for the last few days nobody has been that helpful (if they'd even respond)

fallow mango
#

?

pale vessel
#

nm

soft flare
#

how can i make the Kick.js works in glitch...

pale vessel
#

i thought you saw what you got wrong

fallow mango
#

nope

pale vessel
#

i guess you meant the message

fallow mango
#

i thought i did

pale vessel
#

is there a new error?

fallow mango
#

no its the same

#
async def kick_member(Ctx, targets:Greedy[DiscordMember], *, reason:Optional[str]*""):
TypeError: can't multiply sequence by non-int of type '_GenericAlias'```
pale vessel
#

any pythoners here?

quartz kindle
#

What are you trying to do?

#

Youre trying to multiply two different types of data

slender thistle
#

reason:Optional[str] * ""

finite bough
#

@soft flare there is no different method for glitch a kick cmd is a kick cmd

fallow mango
#

what am i multiplying?

soft flare
#

i just want to run a file called kick.js to make the bot use it

pale vessel
#

kicc

fallow mango
#

my kick is being stupid asf

pale vessel
finite bough
#

@soft flare do u have a command handler?

soft flare
#

cmd?

pale vessel
#

yes

#

command.

soft flare
#

ye they have one

pale vessel
#

did you just make a file called kick.js and hoping it would work?

soft flare
#

called console

#

its for a command...

pale vessel
#

my brain cells are decreasing

soft flare
#

i can call it also Moderator

finite bough
pale vessel
#

don't give him a video

soft flare
#

he use glitch?

finite bough
#

no

pale vessel
#

videos are hard to understand

#

for beginners

finite bough
#

try understanding the concept

golden condor
#

Help

#

I am tryna move from quick.db to myqsl

finite bough
#

and see how a kick cmd is made

soft flare
#

i just want to make the kick.js aka moderator.js to run

golden condor
#

I am getting so stressed

quartz kindle
#

@fallow mango * is a multiplication operator, unless it has another meaning in python

pale vessel
#

it did say can't multiply sequence by non int

finite bough
#

@soft flare by the looks of ur files I cant see a folder/ command handler

pale vessel
#

it definitely means multiply

fallow mango
#

idk what it means thoughhghghg

quartz kindle
#

Dude

#

It means

#

If you do 5 * 5

#

Its 25

pale vessel
#

25

fallow mango
#

yeah ik that

pale vessel
#

quick maths

fallow mango
#

๐Ÿ˜ 

quartz kindle
#

And youre doing someThing * ""

fallow mango
#

its 25

pale vessel
#

why are you multiplying a string

fallow mango
#

i fixed it ๐Ÿ™‚

finite bough
#

@soft flare I would recommend starting off with basic stuff like sending and reading messages before making s kick cmd

soft flare
#

i did the kick stuff

#

and ban stuff

finite bough
#

did u u understand it?

soft flare
#

BUT I WANT TO PUT THEM SOMEWHERE ELSE

pale vessel
#

yeah but you must've blindly followed a guide without knowing what it does

soft flare
#

I DONT WANT TO KEEP THEM IN SERVER.JS

golden condor
#

Can anyone help me

quartz kindle
#

Stop screaming

golden condor
#

I need a db that's easy to setup

#

That isn't better-sqlite3

earnest phoenix
#

why not

golden condor
#

I'm tryna use hroky

#

*heroku

earnest phoenix
#

lol

#

solution: don't

finite bough
#

quickdb

golden condor
#

It's either glitch or heroku

earnest phoenix
#

neither

golden condor
#

And heroku is much better

quartz kindle
#

quickdb uses sqlite

earnest phoenix
#

get a vps

pale vessel
#

use. a. server.

earnest phoenix
#

it's like 3 bucks a month

finite bough
#

@soft flare please it's for ur own good

golden condor
#

I need to easily be able to transfer data from an sqlite file to a db

pale vessel
#

there's like tons of mysql server hosting for free

earnest phoenix
#

even cheaper if you find discount codes

finite bough
#

when u understand it, I will myself help u

quartz kindle
#

@golden condor the only way is to use heroku's postgre, or an external database such as mongodb atlas

golden condor
#

I have a mysql server already

pale vessel
#

then use it

golden condor
#

Yeah well I can't easily transfer data over

pale vessel
#

you can

golden condor
#

How

pale vessel
#

queries

golden condor
#

What

quartz kindle
#

Where is your mysql hosted?

golden condor
#

Heroku

pale vessel
#

wut

golden condor
#

It's postgre

quartz kindle
#

And why is it hard to use it?

golden condor
#

I have quick.db storage

#

I need to move it over

earnest phoenix
#

there's like tons of mysql server hosting for free

yeah don't do that, free database hosting means anyone can snoop at your data, you don't have full control over the database and it'll most likely get purged every few weeks

quartz kindle
#

@golden condor there is no easy way to migrate between databases

pale vessel
#

it's bunch of ids tho

#

unless he's storing passwords

golden condor
#

I just have to reset the db?

finite bough
#

another question who names their main file server.js bloblul

pale vessel
#

him

golden condor
#

glitch

earnest phoenix
#

a part of discords TOS is that if you store data you guarantee protection and encryption with it

finite bough
#

glitch does not

quartz kindle
#

You need to create a function that opens all entries in your old database and saves each of them in the new one @golden condor

golden condor
#

how do i

finite bough
#

server.js is the server retrieving stuff

quartz kindle
#

Dude...

#

How were you using yoir database until now?

golden condor
#

I was using quick.db

pale vessel
#

a part of discords TOS is that if you store data you guarantee protection and encryption with it
@earnest phoenix i see

quartz kindle
#

And you know how to read data from it?

golden condor
#

Yes

#

db.fetch

quartz kindle
#

Then do it

#

Read data from it

golden condor
#

I can't

#

I can't use quick.db anymore

quartz kindle
#

And write the data into the other db

pale vessel
#

you don't need quickdb

golden condor
#

I have a file called json.sqlite

#

where it stores all the data

#

Can I move over from that

finite bough
#

yes @golden condor

pale vessel
#

sqlite aren't as reliable anyway

golden condor
#

How

#

I wanna convert from a .sqlite file to mysql

pale vessel
#

it doesn't work like that

golden condor
#

Fuck

pale vessel
#

i know, fuck

finite bough
#

well

#

it can work

#

u have to fletch data from ur old database

#

and write it in the new db

#

for example

earnest phoenix
#

it's literally just

opening a connection to sqlite
grab data
open a connection to mysql
insert said data

soft flare
#

ok i got it

#

nobody knows...

#

wow

golden condor
#

I don't know how

earnest phoenix
#

google and docs

golden condor
#

I've never used mysql before

fallow mango
#

hey umm i have a new error

earnest phoenix
#

it's an sql server

#

it follows the same syntax

#

???

golden condor
#

i used quick.db

fallow mango
#

  File "bot.py", line 126
    async def kick_member(Ctx, targets:Greedy[DiscordMember], *, reason:Optional[str]""):
                     ^```
pale vessel
#

quickdb isn't the same

fallow mango
#

pls help

earnest phoenix
#

then use an ORM

#

if you don't know how to write sql

fallow mango
#

sql is easy

finite bough
#

@golden condor question

#

why r u asking how to get data to mysql when u dont know how to use it

golden condor
#

i need another database to use

pale vessel
#

mysql

golden condor
#

other than sqlite

finite bough
#

sqlite is better

#

as it's more reliable

earnest phoenix
#

eh no

finite bough
#

and recommended

pale vessel
#

what

#

no

golden condor
#

Does sqlite use integer

sudden geyser
#

Shiemi that's a big no

pale vessel
#

where did you get that information

finite bough
#

ehh

pale vessel
#

that's a nono

finite bough
#

guide

#

lmao

earnest phoenix
#

mysql is way superior than sqlite but that doesn't excuse the fact that mysql is still slow and disgusting

finite bough
#

wdym slow

#

like

pale vessel
#

like slow-slow

finite bough
#

even if it's like some seconds slow

#

how fast do u want it to be

#

xd

pale vessel
#

not some seconds

golden condor
#

It uses sqlite 3 format

#

So

earnest phoenix
#

jesus christ

mossy vine
#

@earnest phoenix what database do you support then lol

slender thistle
#

Postgre for life

finite bough
#

@mossy vine json db

golden condor
#

I might try mongo

earnest phoenix
#

i go for postgres

finite bough
#

XD

golden condor
#

THAT'S WHAT I AM TRYNA USE @earnest phoenix

earnest phoenix
#

you just said mysql

pale vessel
#

hey don't scream

earnest phoenix
#

...

golden condor
#

Sorry

#

i am getting stressed

pale vessel
#

you think we aren't stressed hearing you rambling

earnest phoenix
#

instead of throwing a tantrum you could've already done your research

golden condor
#

I am gonna get rid of all my db entries

#

and redo all the commands

pale vessel
#

great idea

#

don't let discord distract you

golden condor
#

I am more worried about hw rn

pale vessel
#

do that first

golden condor
#

I am using github

finite bough
#

question

#

what's the best db

red hollow
#

imo rethinkdb

earnest phoenix
#

json kek

golden condor
#

lmao

amber fractal
#

Every db is better at different things

#

If you want better horizontal scalability, use a (most) nosql database, if you want better vertical scalability use a sql database. Not the only difference, but one of them

honest pebble
#

what happened to RichEmbed in djs?

#

cant call it anymore

zenith terrace
#

Its MessageEmbed now in v12

honest pebble
#

oh i see

#

they changed it

zenith terrace
#

They changed a few things

#

You gotta have .cache in some of the coding as well

summer torrent
quartz kindle
#

The reason of the .cache change is to make it easier to differentiate between rest methods and collection methods

#

ie: all collection methods (get,set,find,filter,map,reduce,has,etc) have been moved to .cache

#

While rest methods such as fetch (which need to send data to the discord api), stay in the manager, not in the cache

modest maple
#

Tim

#

i need yer help

#

do i needddd a usb drive to stick ubuntu to boot off or can i just have it as is which is a seperate partition?

quartz kindle
#

wat

modest maple
#

im installing Ubuntu because windows fucced me a lil bit

#

i downloaded ubuntu and put it onto a seperate ssd

#

can i boot of that or does it need to be on a usb to be booted off initially

quartz kindle
#

Is it just the bootable iso? Or an actuall installation?

modest maple
#

iso

quartz kindle
#

The iso needs to be imaged into a device to make it bootable

#

You can format your entire ssd and clone the iso onto it i guess, but then you cant install it on itself (or maybe you can but it will be weird af)

#

Its best to just format the usb with it and install it to the ssd

modest maple
#

atm it thinks its on a F drive Disc

#

i rlly cba to go to the shops and get an usb ๐Ÿ˜ซ

quartz kindle
#

Well. I guess you could split the ssd into two partitions

#

Make like an 8gb partition and clone the iso into it lol

#

And install it on the other partition

#

Then merge them after installed

scenic kelp
#

bruh you don't have a single flash drive laying around

modest maple
#

i seem to of lost them all

scenic kelp
#

damn

earnest phoenix
#

you can install onto the media it's booted on

#

its not too hard either

#

make a partiton the same size as the iso, and a partition covering the rest

#

install onto said separate partition

#

then use the 1st os (im assuming you're dualbooting) to delete the partiton with the iso and resize the partition with the os on it

floral bloom
#

Not sure why I'm getting the error or even what it means.

pale vessel
#

it's not a function

earnest phoenix
#

someone somewhere is calling .flat on your fields ):

honest pebble
earnest phoenix
#

imma just guess that somethign changed internally

#

someone was getting that error yesterday too

honest pebble
#

its discord embed again

pale vessel
#

ptsd

floral bloom
#

I don't have anything that has fields.flat though. ๐Ÿค”

pale vessel
#

Ctrl f

honest pebble
#

are you calling message embeds?

floral bloom
#

Hm?

quartz kindle
#

@floral bloom are you using discord.js v12?

honest pebble
#

i mean, old message embeds

quartz kindle
#

You need to use node.js v12 or newer as well

pale vessel
#

it's showing MessageEmbed

#

so yes

honest pebble
pale vessel
#

it does

quartz kindle
#

It does

#

The problem is that array.flat() mas added with node v11

#

Hes likely using v10

floral bloom
#

Updated Node to v12 and it works now. Thanks, Tim!

quartz kindle
#

the latest discord.js requires node v12 or higher precisely because they added many internal functions that are not available in older versions of node

feral fiber
#

What is required to invite your bot?

zenith terrace
#

Invite it here?

feral fiber
#

Yes.

quartz kindle
zenith terrace
#

^

quartz kindle
#

Then wait for approval

zenith terrace
#

Was about to say that

feral fiber
#

How many command do I need, etc?

zenith terrace
#

Doesnt matter

feral fiber
#

Are there any requirements I mean

quartz kindle
#

For approval, the only requirment is that it has at least a couple funcional commands, and that its online

zenith terrace
#

And whatever the requirements are when adding the bot

quartz kindle
#

But if youre starting to develop it now, i suggest waiting until you have a better bot

earnest phoenix
quartz kindle
#

Top.gg is meant for public ready to use bots

#

If your bot is not ready to use by public servers, you should wait until it is

vapid ferry
#

My bots current prefix is -
Should I change it?

mossy vine
#

does eris work well with typescript

zenith terrace
#

Whats the bots ID? @vapid ferry

vapid ferry
#

Client or User?

zenith terrace
#

Client

vapid ferry
#

@hexed marten
client ill get one sec

#

619734666697637889

quartz kindle
#

They should be the same lol

vapid ferry
#

they are? lmao i didnt know that

#

since i cant use the prefix, do y'all have any ideas on what to change it to?

quartz kindle
#

You can, just not in this server

#

But if you want to change it, common practice is to use something like your bots initials

vapid ferry
#

like tb-

zenith terrace
#

Unless you make a prefix command and ask the mods to change the prefix to something?

#

tb- works

quartz kindle
#

Do the mods even do that here?

zenith terrace
#

Not hard to ask I guess

#

@flat pelican are yous allowed to do that?

flat pelican
#

hmh?

zenith terrace
#

Like if a bot has a common prefix. But has a prefix command to change it, could you change it for this server?

#

So that the dev doesnt have to go change the whole bot prefix itself

flat pelican
#

We can do it but I don't see why? If your bot's prefix is changeable for each server, then simply make the change from your DB and ask us to remove the role

vapid ferry
#

uh so once i change my bots prefix, who would i contact to get it unmuted or is it automatic?

zenith terrace
#

One of the mods

#

Just ping them asking to remove it

flat pelican
#

Ping me once you're done

vapid ferry
#

i'll apply the updates first and update the website

quartz kindle
#

I actually havent thought of that. Of course you can just change it in your own db lol

golden condor
#

What if I use a glitch project to be my db and connect to it using axios, would that work as a database?

quartz kindle
#

You just want to extract the data from your sql fils right?

golden condor
#

Yeah

quartz kindle
#

If you cant get any sqlite db to work on heroku, its an optoon i guess

flat pelican
#

frick

golden condor
#

Awesome

flat pelican
#

accidentally removed Tim's bot dev role for a second

quartz kindle
#

But id first try to install other sqlite dbs

#

Loool

golden condor
#

Yeah well I got it figured out already

#

And it would be really simpel

zenith terrace
#

Oof

quartz kindle
#

My bots were not autokicked or anything, right?

#

Lmao

golden condor
#

What bots are yours

#

None of them are here

zenith terrace
#

Oof

quartz kindle
#

They are, just not cached by your client

golden condor
#

Can bots add other bots by an oauth link?

#

No they can't

zenith terrace
#

No

vapid ferry
#

fuck i broke my bot

golden condor
#

Because they have to prove they aren;t bots

zenith terrace
#

Rip turret

#

F

vapid ferry
#

its probably syntax ngl

quartz kindle
#

bot was hit by a turret shot

zenith terrace
#

Lmao

vapid ferry
#

when u realise that ur internet is so shitty that you cant even ssh into your hosting server

#

but when u realise the laptop you applied the updates from can perfectly run the bot

finite bough
#

Tim what vps and db do u use if u don't mind me asking

vapid ferry
#

@flat pelican i updated the prefix

flat pelican
#

Bot ID + new prefix, please?

vapid ferry
#

619734666697637889 (@hexed marten) tb-

quartz kindle
#

@finite bough galaxygate and better-sqlite3

finite bough
#

okie

#

btw

flat pelican
finite bough
#

how can u view sqlite table

vapid ferry
#

yes

earnest phoenix
flat pelican
#

I thought you can setup custom prefixes for each guild

quartz kindle
#

You can use an sql file viewer, or use an eval command to load and display data from it

vapid ferry
#

i can

#

but i dont rly want to

flat pelican
#

hmh

#

aight

finite bough
#

does VSC have a sql viewer module

quartz kindle
#

No idea

finite bough
#

what editor do u use

#

notepad?

#

xd

quartz kindle
#

Mostly sublime text 3

#

Occasionally notepad++

flat pelican
#

Tim

vapid ferry
#

ty

flat pelican
#

i'm disappointed

quartz kindle
#

Im considering moving to vsc tho

earnest phoenix
#

webstorm

flat pelican
#

notepad++ is just

#

uh

earnest phoenix
#

jetbrains > microsoft

quartz kindle
#

@flat pelican its great for taking a quick look at a file lol

#

Without loading my entire workspace

flat pelican
#

well yeah

finite bough
#

what SQL viewer can I use

earnest phoenix
quartz kindle
#

DBBrowser, sqlite viewer

#

There are more than one

finite bough
#

okie

heavy marsh
#

In discord.js is there a way to unban Deleted Users?

finite bough
#

tyy

#

just get their Id ig

quartz kindle
#

You should be able to unban them by id

heavy marsh
#

Yes but i have ove 5k deleted users

finite bough
#

their name changes their Id remains the same

#

.

heavy marsh
#

in my servers and its annoing

quartz kindle
#

Lol then just use the prune function in your servers user list?

finite bough
#

u can do like

earnest phoenix
#

delete the server

#

oh yea

#

thats an idea

quartz kindle
#

Or is it purge

finite bough
#

prune

heavy marsh
#

purge will kick alot of users right?

#

purge*

quartz kindle
#

Will kick users who have no role and have been offline for 30 days

heavy marsh
#

I dont want to do that

finite bough
#

no

quartz kindle
#

Or inactive for 30 days

finite bough
#

thats a bad idea

heavy marsh
#

I just was to unban Deleted users

finite bough
#

donlike

#

find the user map by name

quartz kindle
#

Oh wait i was thinking about removing idk why lol

finite bough
#

if name has ["deleted", "user",]

#

that is suppose to work right?

quartz kindle
#

^ what if a person named themselves "deleted user"? Lmao

heavy marsh
#

there are some users in the ban list with deleted user name

#

So yes like tim said

finite bough
#

and

#

discriminator = 0000

earnest phoenix
#

profile pic = nothing

quartz kindle
#

All of those can b forged by a real user lmao

finite bough
#

2 filters

quartz kindle
#

But the chances of that happening are stupidly low

finite bough
#

yes

#

YES

earnest phoenix
#

they ALWAYS follow /Deleted User [0-9a-f]{8}/ regex

finite bough
#

ok 3 filters

earnest phoenix
#

check if their discrim is 0000

#

users cant have that

finite bough
#

name has deleted + user

earnest phoenix
#

no

finite bough
#

discriminator = 0000

earnest phoenix
#

my regex has less false matches

finite bough
#

wait

#

I think users cant have 0000

heavy marsh
#

hold on wait

finite bough
#

omg

earnest phoenix
#

like. its the pattern they all follow.

finite bough
#

tim

#

we need to talk

#

people cant have 0000

quartz kindle
#

Users cant have 0000? Even with nitro?

earnest phoenix
finite bough
#

ehh

quartz kindle
#

Interesting

finite bough
#

ima ask something to try it

earnest phoenix
#

users cant have 0000

it's reserved for webhooks and deleted users

prime cliff
#

And system users

earnest phoenix
#

accidentally bans webhook

heavy marsh
finite bough
#

@quartz kindle write said no

#

wait

earnest phoenix
#

exactly @heavy marsh all of them match /Deleted User [0-9a-f]{8}/ regex

quartz kindle
#

Wait, so a deleted user without the regex is not really deleted?

earnest phoenix
#

i have never seen one that did not match that

#

those are fake deleted users

heavy marsh
#

How to do a eval properly?

earnest phoenix
#

they just changed their username to that

finite bough
#

@heavy marsh by doing it properly

earnest phoenix
#

^

#

discord changed how deleted users work ageeees ago to comply with GDPR

prime cliff
earnest phoenix
#

w h y

finite bough
#

LMAO

earnest phoenix
#

no info is left exposed but the id

quartz kindle
#

Without the 8 digit code?

earnest phoenix
#

correct

heavy marsh
#

๐Ÿง 

quartz kindle
#

Then what about those with the 8 digit?

earnest phoenix
#

discord changed how deleted users work ageeees ago to comply with GDPR
this includes removing the code

#

then explain my ex's account

#

i watchedd her delete it

vapid ferry
#

wanna hear a fun fact about my bot?

earnest phoenix
#

probably not

#

but yet here it is

#

hm ig that accounts deleted prior to the GDPR compliance change weren't affected by it

heavy marsh
#

ahhh

earnest phoenix
#

that was in the last few months tho

#

thank you discord for being inconsistent again

quartz kindle
#

Discord being inconsistent once again

#

Lmao

earnest phoenix
#

tbf discord isn't ever consistent peepoClown

#

xD

quartz kindle
#

Speaking of which

#

Why does discord sometimes render mentions as invalid-user?

#

Instead of showing the id

earnest phoenix
#

broken client cache maybe

quartz kindle
#

lul

earnest phoenix
#

also fun fact

#

she still has a discrim

#

they also forced half of large guilds into this weird a/b testing feature where the mention format for text channels is entirely different - it ended up breaking bots and official clients lol

#

o?

mossy vine
#

this is why discord is the best platform ever made

earnest phoenix
#

i think they reverted that

#

o

quartz kindle
#

Wait they changed channel mentions?

#

What was the change?

earnest phoenix
#

it was reverted a while back but basically the format became <#guildid-textchannelid-textchannelname>

#

ew

quartz kindle
#

Wow lol

#

It would have broken one of mine too

earnest phoenix
#

it was a horrible attempt at making cross server mentions easier

tight plinth
#

Lol wtf

heavy marsh
tight plinth
#

This is not

#

Deleted users have #0000

#

That's just a troll

heavy marsh
#

hmm ok

earnest phoenix
#

but you're missing the fact that i watched my ex delete her account

tight plinth
earnest phoenix
#

was there a point where discord didnt change it?

tight plinth
#

(yes that's my old acc)

earnest phoenix
#

btw @heavy marsh

heavy marsh
#

Ya true

quartz kindle
#

Why so many bans lol

#

Raids?

heavy marsh
#

I had a bot that did global bans

#

and it got me 10K

earnest phoenix
#

w h y

amber fractal
#

ew stinky global bans bot

heavy marsh
#

I kicked it thought

quartz kindle
#

So bans in other servers would make it also ban them there?

heavy marsh
#

yep. But most raids

quartz kindle
#

I mean, its not a bad idea

amber fractal
#

That can be abused so easily

quartz kindle
#

But its execution is questionable

earnest phoenix
#

well

#

if it was a self-hosted bot

#

and you owned related discord servers

quartz kindle
#

Anyway, if you want to unban them, i think the best approach would be to test for both

#

0000 and 8 char code

heavy marsh
#

na i dont want to any more due to ip bans

sudden geyser
#

@tight plinth @heavy marsh I think Deleted Users sometimes just appear like that.

tight plinth
#

wdym by "that"

tight plinth
#

This

#

Is

#

A

#

Troll

earnest phoenix
#

then explain.

#

how

quartz kindle
#

Its not

earnest phoenix
#

i watched IN PERSON

sudden geyser
#

It's not a troll

earnest phoenix
#

someone delete their account

sudden geyser
#

I have many of those in my server ban lists.

earnest phoenix
#

and they have a discrim

tight plinth
#

Wait no

#

It's not

quartz kindle
#

@tight plinth we have been discussing this for the past 30min lol

#

They are deleted users

tight plinth
#

They are

heavy marsh
#

ahh

tight plinth
#

Okay

heavy marsh
#

god

earnest phoenix
#

xD

tight plinth
#

Just looking at the tag and I understood

quartz kindle
#

Apparently discord is just inconsistent like that

earnest phoenix
#

so yea anyone who matches /Deleted User [0-9a-f]{8}/, has no profile pic is almost probably deleted

quartz kindle
#

I mean

earnest phoenix
#

and isnt accepting friend requests

quartz kindle
#

Is there a way to try fetching it with the bot and catch the error?

#

Or maybe not because no shared servers

earnest phoenix
#

be nice if discord had an endpoint for it

#

to see if an id was deleted

quartz kindle
#

Its likely that discord has multiple layers of deletition

#

Like a deleted status but not totally deleted

slender thistle
#

What could this white part be between the left (container) and right (Opera background)

#

Border, margin and padding don't apply

quartz kindle
#

Ig box-shadow

earnest phoenix
#

margin of the parent?

quartz kindle
#

Or padding of the parent

earnest phoenix
#

Or maybe not because no shared servers

you actually can. there is a REST endpoint to get basic information about a user via their id

#

wait

#

doing it in mass requests'll be heavy on ratelimits though

#

really

#

yes

#

yup

#

what happens if said user is deleted?

quartz kindle
#

Well if you do one user per 5 seconds, it will only take about 20 hours to go through 10k

earnest phoenix
#

it provides username, discrim, id and some other thing

#

it'll return 404 probably

#

ohhh

quartz kindle
#

Good to know, ty for testing

#

<3

earnest phoenix
#

noice :D

earnest phoenix
#

wait

modest maple
#

๐Ÿ‘‹

earnest phoenix
#

ok so

#

tasks.loop()

#

probs the best way to do something repeatedly?

#

instead of kicking off another thread on your own?

modest maple
#

tasks.loop() doesnt make a new thread

earnest phoenix
#

O.o

#

what does it do?

modest maple
#

you can use tasks.loop() or just create another task

#

just creates a task every X seconds

earnest phoenix
#

task?

#

im still very unfamiliar with how await/async works

modest maple
#

if its a loop you can just do client/bot.loop.create_task(coro)

earnest phoenix
#

o

#

oki

#

i was gonna use that to update my bot's guild count in status and top.gg

modest maple
#

if ur using the dblpy module just have it autosend

earnest phoenix
#

but guild status still

slender thistle
#

DBLClient(autopost=True)

#

Oh, misread

modest maple
#

autopost should work

#

every 30 mins

earnest phoenix
#

welp imma go add another cog to do that

#

i'll be back to share results

slender thistle
#

autopost_interval accepting the interval between each POST request in minutes ๐Ÿค”

earnest phoenix
#

new question

#

when passing multiple env vars in bash

#

semicolons or spaces

#
TOKEN=akjshdjadhasjkdhashdkhasjkhdkajsh;OTHERTOKEN=akshdkjaskjdhkjaskjdh python3.7 main.py

or

TOKEN=akjshdjadhasjkdhashdkhasjkhdkajsh OTHERTOKEN=akshdkjaskjdhkjaskjdh python3.7 main.py
slender thistle
#

python3.7 main.py token=lalala othertoken=bobobo

modest maple
#

why are you doing dat anyway

earnest phoenix
#
cd Ansura
while true; do
 git pull
 sudo pip install -r requirements.txt
 ANSURA=ashdkjashdkjashkdashkdkhash python3.7 main.py
done
#

thats my bot's run script

#

@slender thistle im using bash env variables not python arguments

slender thistle
#

I'll just say that my opinion is objectively correct since I'm not familiar with bash

earnest phoenix
#

i mean it wouldnt take too much to change,but i was curious abt bash

#

ty tho

#

if i cant find an answer i'll use that way

modest maple
#

ngl i hate the fact that switching to 32 bit PyPy fixed the latency issue

#

-_-

solemn quartz
#

Guys how can i do a bot reload cmd?

#

I thinked something like

#

(code to turn it off)

#

console.log(node .)

#

so it restarts

quartz kindle
#

You cant turn it back on from inside

#

You need an external script or a process manager / auto restarter

#

For example pm2

solemn quartz
#

hmmm

white anvil
#

if ur using node you can clear require cache

solemn quartz
#

im lazy so i think im not gonna do it

white anvil
#

and require all the commands again

#

provided ur commands are actually exported

solemn quartz
#

I just have index.js

white anvil
#

ok just clear your commands list and re-add them

#

or somethiong

quartz kindle
#

PM2 is super easy yo use tho

white anvil
#

it might be a bit more complicated if its only one file

solemn quartz
#

pI think im not gonna do the restart bot cmd :p

white anvil
#

pm2 is a bit of a pointless daemon imo just use systemd or make a 6-liner run bash script

quartz kindle
#

npm install pm2 -g
pm2 start yourbot.js (instead of node yourbot.js)

white anvil
#
#! /bin/sh

while :
do
        echo "Starting process..."
    cd /home/assyst/JS
        node index.js
        if [ $? -eq 0 ]
        then
                echo "Stopping process..." # exit shell script if exit code is 0
                break
        fi
        sleep 10 # wait 10 seconds before restarting
done
#

this is the start script for my bot

quartz kindle
#

Or that heah lmao

white anvil
#

if exit code is not 0, it will wait 10 sec and restart

#

if it is 0, it will kill process

quartz kindle
#

But thats more advancrd

solemn quartz
#

I hate that when you do :P it makes that ๐Ÿ˜›

white anvil
#

you can disable that

solemn quartz
#

Rly?

#

How

white anvil
fast zenith
#

pretty simple script to be fair good way to do it

solemn quartz
#

:P

#

FUCK YEAH

quartz kindle
#

But that script requires using tmux or similar

white anvil
#

either way since my bot is dockerised pm2 is a bit pointless

quartz kindle
#

On ssh

solemn quartz
#

I think im not gonna do that command

#

i was thinking to do a simple 4 lines code with nothing else

quartz kindle
#

Its less than that

white anvil
#

all u need to do is copy this and run

#

lol

#

while changing the directory

solemn quartz
#

I dont think i can add another thing to my node modules

quartz kindle
#

He doesnt understand that code

solemn quartz
#

wat

quartz kindle
#

Not a good idea to run something he doesnt underatand

solemn quartz
#

:/

white anvil
#

the only problem with this script is i will run it

#

and exit container

#

and when i go back in i wont be put in stdout of this file so i have to kill it manually to stop the current process

quartz kindle
#

And it will stop as soon as he closes the ssh connection

white anvil
#

no?

#

oh

fast zenith
#

uh

white anvil
#

unless there is some difference to how it works containerised that doesnt happen to me

modest maple
#

makes me glad with python's importlib xD

quaint sorrel
#

wher can i get help with my bot script?

fast zenith
#

screen could be used to keep the session active

white anvil
#

here

quaint sorrel
#

whre

quartz kindle
#

screen or tmux yes

white anvil
#

i just exit the container and it carries on running

quartz kindle
#

Well idk about containers

#

Havent used one

quaint sorrel
#

can someboody help me with my discord bot?

quartz kindle
#

Just post your issue

quaint sorrel
#

my code dows not working

#

a sec

quartz kindle
#

You named your file indox.js

fast zenith
#

you might want to get a new token

quartz kindle
#

Not index

#

rename it to index

solemn quartz
#

you might want to get a new token
@fast zenith lol i already said him in DM

quaint sorrel
#

i did it

solemn quartz
#

Gud

quaint sorrel
#

ok i rename it

solemn quartz
#

lol

quaint sorrel
#

it's still not working and i dont know why

solemn quartz
#

lol

#

@quaint sorrel Copy your token

quaint sorrel
#

i did it

solemn quartz
#

and dont show us

#

right click + cut

#

Sorry

quartz kindle
#

@quaint sorrel whats the error now?

solemn quartz
#

writed wrong

#

Yea

#

I was asking that

quaint sorrel
#

this is the error

fast zenith
#

npm install discord.js

#

run that

quartz kindle
#

Dude...

fast zenith
#

you need to install the module

quartz kindle
#

Your file is still called indox.js lol

#

And you dont need to send a full screenshot

#

Just the error part

solemn quartz
#

yea

quartz kindle
#

Or just copy and paste the error text

quaint sorrel
#

ok

quartz kindle
#

And you need to install discord.js

solemn quartz
#

the only thing i see wrong is this

quaint sorrel
#

@fast zenith i am it installd

#

yayyy

#

it's working

#

thx for evrey boody

solemn quartz
#

bot.on('ready', () =>{
There is no spac |
console.log('This Bot Is Online!')
}

#

oh

#

i didnt readed

earnest phoenix
#

lol spaces dont really matter ever in js

solemn quartz
#

i tooked me 3 mins to do this fucking message

#

I wanna die

quaint sorrel
#

but now it's working alot beeter i did something else @solemn quartz

solemn quartz
#

oki

peak venture
#

if i'd want to execute a funtion for every id i'm having.
How would i need to do that in a loop using the array?`

    if (current.isLoggedIn()) {
      voiceMembers = await userCheck(client, current.getDiscordID(), voiceChannelID)
    }
    let voiceMembersIDs = voiceMembers.map(m => m.id)```
like for every id inside the voiceMembersIDs
would i need to use a for let loop or voiceMembersIDs.forEach(id => {})
solemn quartz
#

u need to make the let args and your first command

#

if i'd want to execute a funtion for every id i'm having.
How would i need to do that in a loop using the array?`

    if (current.isLoggedIn()) {
      voiceMembers = await userCheck(client, current.getDiscordID(), voiceChannelID)
    }
    let voiceMembersIDs = voiceMembers.map(m => m.id)```
like for every id inside the voiceMembersIDs
would i need to use a for let loop or voiceMembersIDs.forEach(id => {})

@peak venture wat

#

:p

peak venture
#

ahm

#

i want to execute a function. and get the results from thta

#

for each id

wide ruin
#

Ok I have a question about TOS

#

are you allowed an admin only commands that lets you get an invite to a server the bot is in

copper cradle
#

well

#

ig

modest maple
#

not really no

#

its a massive privacy Breach

earnest phoenix
#

Hi, looking to count messages for a server to award ranks/perks, yet quality discussion is to be promoted. For example single-emote messages or "lol" should not be added to the total

The hope is that this is achievable by not adding messages below a minimum character limit to the total, or by counting characters a user has sent (over the amount of messages) - is there any bot out there which can already do this? Hard to believe this is a problem only one server has, I know a minimum delay between messages is already possible with some bots. Otherwise the extreme solution would be to create a custom bot just for the server, hoping to find one first though ๐Ÿ™‚

modest maple
#

im not sure if there is an already existing bot

#

there might be

#

ive made that sort of system for a few custom bots

#

e.g More XP given to longer sentences upto a certain limit, spam not counted short words ignored /less xp etc..

earnest phoenix
#

while I do have experience with Python and Java, I've never considered creating a custom bot, wouldn't know where to start. Guessing there is a discord provided platform / server space for running bots?

modest maple
#

not really no

#

you get a bot token in discord's dev portal essentially creating a bot account

#

after that you have to use a Lib and programming language of your choice to program the bot and run that code 24/7 using a VPS or self hosting

#

lotta code

solemn quartz
#

guys

#

i just realized that oily is a boy

#

i dont see good little images

#

it seemed a girl

copper cradle
#

bruh

true ravine
#

Oliy is an egirl confirmed

solemn quartz
#

lol

earnest phoenix
#

would hope to find an existing bot before starting a host just to accommodate a simple counting feature. Otherwise we'd have to consider not adding this before we have other features we could add to a custom bot, just for this it isn't worth creating a custom one

true ravine
#

It seems like a very specific feature so I doubt there will be many if any public bots that are capable of that

#

Either manually check out a load of moderation bots one by one or bite the bullet and make one yourself I guess

earnest phoenix
#

that is surprising. I'd think many servers who want to promote discussion would face the issue of one sentence being

"well
i agree
but
you need to consider xyz
otherwise you are correct"

or "well I'd agree, but you need to consider xyz. otherwise you are correct" in a single message which messes with the results. Eitherway thanks for the help @true ravine and @modest maple ๐Ÿ™‚ Much appreciated!

Oh, and If anyone sees this conversation in the future and knows of a bot which can count characters, please message me! ๐Ÿ™‚