#voice-chat-text-0

1 messages Β· Page 756 of 1

hushed elm
#

hahahahahaha

honest pier
#

the jokes write themselves

hushed elm
#

i still gotta write them though

#

i like my tea black

#

same way i like my watches

rugged root
#

Irish Wristwatch

hushed elm
#

IRIST

zealous wave
hollow ridge
#

Heelo

#

Hello

#

I from brazil can you help me?

hushed elm
#

uh no the police is here

rugged root
#

!server

wise cargoBOT
#
Server Information

Created: 4 years, 1 month and 3 days ago
Voice region: us-east
Roles: 82
Member status: status_online 46225 status_offline 100619

Members: 146844

Helpers: 89
Moderators: 27
Admins: 14
Owners: 3
Contributors: 36

Channels: 208

Category: 26
News: 8
Staff: 56
Text: 108
Voice: 10

flat sentinel
#

that is a lot of numbers

hollow ridge
#

This is so cool

whole bear
#

i would like to join

rugged root
#

Back in a bit

sick dew
#

ok thank you

zealous wave
#

hemlock how could you leave us

dull hollow
#

yes we need the big daniel bro

whole bear
#

why do u have pronouns in ur name

rugged root
#

By standing up and moving away from the keyboard.

dull hollow
#

nooooooo

rugged root
#

It's really starting to bother me

flat sentinel
#

Hemlock

dull hollow
#

oh ok sorry mr hemlock

rugged root
#

Thank you

flat sentinel
#

we are on a first name basese

hollow ridge
#

Mr hemlock did you create python?

hushed elm
#

@somber heath you've made any interesting art lately?

hollow ridge
#

I dont now

whole bear
#

i did @hollow ridge

zealous wave
somber heath
#

There is a saying. "Familiarity breeds contempt."

whole bear
#

are you transgender not to be rude

hollow ridge
hollow ridge
#

Wtf???

#

KKKKKKKKKKKKKKKKK

zealous wave
whole bear
#

i knew it

hollow ridge
#

Does that mean I should go?

dull hollow
#

lol

hollow ridge
#

Does that mean I should go? @flat sentinel

flat sentinel
#

yes

hollow ridge
#

😦

#

WhyΒ°

#

?*

flat sentinel
#

you are ciber

zealous wave
hollow ridge
#

Cuber?

flat sentinel
#

truck

hollow ridge
#

I dont understand

hushed elm
#

my mom was coding while i was being born

#

@flat sentinel

zealous wave
hushed elm
#

so i'm better than you

hollow ridge
#

Fells bad

hushed elm
#

nooiiiice

#

sexy

hollow ridge
#

I stay here only for learn python

hushed elm
#

127.0.0.1 is my IP

#

come at me

#

UDP me

zealous wave
hushed elm
#

@whole bear where did you go?

hollow ridge
#

wtf???

hushed elm
hushed elm
#

in some way?

#

it's a joeyck

thorny pulsar
#

JeffBezos is my father

hushed elm
#

you'd wish

plain dagger
hushed elm
zealous wave
sick dew
#

Clearly a dolphin

flat sentinel
#

free pings here

zealous wave
#

no, hes a knock off monkey

somber heath
hushed elm
#

would be neat

#

whiskey neat

#

heccer @thorny pulsar

#

mare heccer

whole bear
#

i did say excuse me.

hushed elm
#

so where did you go?

#

no don't tell her to come back

#

let her be

zealous wave
whole bear
#

WHAT????

shy summit
#

32!!!

hushed elm
#

????

#

?!?!?!?!?!????!?

plain dagger
#

i will say some words of monkey wisdom

#

let it be

#

let it be

zealous wave
hushed elm
#

what?

#

PACKED

whole bear
#

guys please

#

im a busy person

hushed elm
#

ahem chili is not a guy ok?

zealous wave
whole bear
#

lmaojmdoaw

verbal oasis
#

@zealous wave I can join you on typeracer

hushed elm
zealous wave
verbal oasis
#

why?

zealous wave
hushed elm
verbal oasis
#

what's the problem? @zealous wave

hollow ridge
#

hi i'm from brazil and i would like to know if someone can give me some tips in python is my first language. and i would also like to improve my english

hushed elm
#

hahaHAHA

plain dagger
#

what a weird movie

zealous wave
#

This is what I'm talking about

hushed elm
#

do you know felix? @zealous wave

zealous wave
hushed elm
zealous wave
#

pls ignore

hushed elm
zealous wave
#

greetings @icy axle

somber heath
#

L-system, Lindenmayer system.

icy axle
#

Greetings, fellow humans

somber heath
#

IFS, Iterated Function System

slim hinge
#

yo can someone help me out with a python problem

hushed elm
#

i am robot pls

zealous wave
icy axle
#

Ah, same

sly osprey
hushed elm
#

<128

#

512<>256

hollow ridge
#

hi i'm from brazil and i would like to know if someone can give me some tips in python is my first language. and i would also like to improve my english

zealous wave
#

hola @olive hedge

olive hedge
#

howdy

hushed elm
#

howdy

icy axle
#

Hola, seΓ±or

olive hedge
#

morning mr gurkan

hushed elm
#

did hemlock call for reinforcements?

icy axle
#

Evening

zealous wave
olive hedge
hushed elm
icy axle
#

Covid is who we're fighting

zealous wave
hushed elm
olive hedge
#

haha

icy axle
#

Fun keeper*

zealous wave
#

LMFAOOOO

#

the emojis too

hushed elm
#

oh no i ruined it

#

variable: any

olive hedge
#

.randomcase what could go wrong

viscid lagoonBOT
#

wHAT COUlD GO wroNG

icy axle
#

yikes

somber heath
#

Information can be harm reduction. It needn't always be considered as enabling.

olive hedge
#

Lol wait foreal ^any

zealous wave
viscid lagoonBOT
#

DIDNt kNow tHiS was a CoMManD

hushed elm
#

i love writing typescript because i've got types everywhere

#

so good

icy axle
#

(that was just because i don't have nitro; thanks for the emoji mr fish)

plain dagger
hushed elm
#

no-nitro plebs

zealous wave
#

sending discord money plebs

plain dagger
hushed elm
plain dagger
# hushed elm y u against this?

im using python for the programming zen, the duck typing and all the valuable things that python has in the favor of fast development

hushed elm
plain dagger
#

if im going to use static typing and waste time in that i would go for a static typed language, since i would be sacrificing the things i use python for

zealous wave
#

and no, i did not mean fuck

plain dagger
#

hahaha

hushed elm
#

if i'd want to use python and django, but i also want to use static types. would using mypy be bad?

plain dagger
#

i think

#

i do work in a 2.5 million lines django repo

uncut meteor
#

Consistenkey

hushed elm
plain dagger
#

and type hint has been enough

#

static typing would be a liability in development

zealous wave
#

!e print(int(bool(None)))

hushed elm
#

i don't wanna be annoying, i'm just curious i wanna understand your reasoning

wise cargoBOT
#

@zealous wave :white_check_mark: Your eval job has completed with return code 0.

0
plain dagger
rugged root
#

@hushed elm Typically you'd want something that just overviews your code and checks it for holes rather than something that actively watch it

olive hedge
#

!e

print(None is 0)
print(None == 0)
wise cargoBOT
#

@olive hedge :white_check_mark: Your eval job has completed with return code 0.

001 | <string>:1: SyntaxWarning: "is" with a literal. Did you mean "=="?
002 | False
003 | False
hushed elm
rugged root
#

I typically write as if things are typed. I don't reuse variable names, I do my best to typehint and know what the type of something will be at a given time, and adjusting as needed. I think starting with Java got me in those good habits

hushed elm
#

yeh, same

#

and i also started in Java, really useful

paper tendon
#

pick your pickle πŸ™‚
Just pickling python.
joke.

hushed elm
#

hhhh

paper tendon
#

I had recently an error with pickle not being able to pickle some cookies.

icy axle
rugged root
#

Dongle Goblin

icy axle
#

What on earth is that?

plain dagger
rugged root
#

It was something that came up during one of the meetings (lead meetings I think?) and I just friggin lost it. It was something about all the extra plugin devices we have

#

I think

#

I don't remember

#

The only thing that stuck with me was dongle goblin

#

For obvious reasons

icy axle
#

Ohh righty

#

I think I saw something about that a while back

rugged root
#

Likely me giggling like a moron

icy axle
#

HAhahah yess

hushed elm
icy axle
#

Dongle Goblins are great. I have many at home

rugged root
#

I've got far too many

icy axle
zealous wave
rugged root
#

Adobe ish

hushed elm
icy axle
#

Hahah

rugged root
paper tendon
#

Linode

icy axle
#

I just got an Adobe licence

zealous wave
hushed elm
#

are those fiberglass?

hushed elm
rugged root
#

Why the crap would they be fiberglass?

icy axle
#

Eh?

hushed elm
rugged root
#

I would really hope not

#

Nothing like getting cancer while trying to prevent COVID

hushed elm
icy axle
#

Hahah

hushed elm
rugged root
hushed elm
somber heath
#

It's fine, I'm an Aquarius.

hushed elm
somber heath
#

She'll be right.

rugged root
hushed elm
#

hihihih

zealous wave
#

what the fuck is going on here

rugged root
#

I have. No idea

hushed elm
#

what the fuck is with that fucking language?

icy axle
#

No clue

zealous wave
icy axle
#

Let's talk in vc 3 instead

hushed elm
zealous wave
rugged root
#

Chill the fuck out, you guys

somber heath
#

We're typing text. Watching it is kind of something that happens, there.

rugged root
#

True

hushed elm
#

fucking ok

zealous wave
#

fucking fine

#

that's a lot of fucking fucks

hushed elm
zealous wave
icy axle
hushed elm
#

wahtevah

zealous wave
#

I mean we could go to code help and talk there

#

brb

gilded rivet
#

Illustrator !

hushed elm
#

swarm? beeware?

#

hahahahaha

icy axle
#

Beeware

whole bear
#

peepeepoopoo

rugged root
hushed elm
icy axle
hushed elm
#

that's like owl eyes

pure anchor
#

Those wings could be eyelashes

#

or hair

somber heath
#

Chun-Li pom poms.

pure anchor
#

YES!

somber heath
#

Chun-Bee!

pure anchor
#

Yeah. Just pay them enough.

icy axle
#

@uncut meteor pay me 5 dollars (ps, here you go with 3 dollars)

alpine path
paper tendon
#

Hedge fund story from 4$ to 400$ shorting and back to 5$

hushed elm
icy axle
#

.hemjoke

hushed elm
#

wow what was that

#

pls kick them

#

jk

#

πŸ˜—

#

guys i'm starting a web dev shop, send me some name recommendations

paper tendon
#

!e print(random.choice(["funny", "not funny"]))

#

!e import random; print(random.choice(["funny", "not funny"]))

wise cargoBOT
#

@paper tendon :white_check_mark: Your eval job has completed with return code 0.

funny
hushed elm
#

wapshop

#

wapp

amber raptor
#

Nintendo Switch, best way to get through meetings

hushed elm
#

nice

zealous wave
#

theres some cooode in this shop, theres some cooode in this shop

hushed elm
#

lllolllll

#

hhh

uncut meteor
#

and if you don't i'm just gonna pretend you do

amber raptor
uncut meteor
#

fair fair

rugged root
#

You share a single account?

amber raptor
#

I’m replaying Super Mario Odssey

#

No but Animal Ccrossing doesn’t support multiple users because reasons

rugged root
#

Yes it does

#

You just share one town

#

Or I guess campsite in this case

#

Island?

#

Island

#

That one

amber raptor
#

Which means I would interfere with the wife

rugged root
#

Or help her

#

Or is she super picky

amber raptor
#

No

#

Picky

paper tendon
#

Dude sniff hellium πŸ˜„

rugged root
#

My condolences

amber raptor
#

She plays with a bunch of girlfriends

somber heath
#

Animal crossing

hushed elm
#

It's in the name!

amber raptor
#

Like they have 7 person chat about it

#

I prefer Stardew Valley

rugged root
#

It really should be one or the other. Like join the village or start a new one

alpine path
rugged root
#

It's always been weird that it HAS to be the same one

#

Not as if timestamps are that hard to check or verify

#

I'm sure Nintendo can juggle two separate sets of numbers.

#

I hope

#

Right, back in a sec

uncut meteor
#

docker exec -it <docker container id> /bin/sh

paper tendon
#

docker exec --rm dockerid /bin/bash

#

oh yeah -it as well

zealous wave
#

ok random question but when do I use async def instead of def? do I use async def if its an asynchronous function or something?

plain dagger
#

with compose: docker-compose exec <container name> /bin/bash

plain dagger
hushed elm
#

πŸ‘ πŸ‘ πŸ‘ πŸ‘

#

πŸ‘Ž πŸ‘Ž πŸ‘Ž πŸ‘Ž

supple axle
#

hello everyone

zealous wave
hushed elm
#

hhhelloo

supple axle
#

so how's the weather

hushed elm
#

windy and snowy really sucky

supple axle
#

that is really good

hushed elm
#

no it's not

supple axle
#

make a snowman

supple axle
hushed elm
#

too much wind bro

#

years!

somber heath
#

Making snowmen in blizzards has precious little to be recommended for it.

hushed elm
#

yes

supple axle
#

okay

#

epic

midnight sonnet
#

127.0.0.1

#

😎

supple axle
#

ip πŸ˜‚

hushed elm
#

ping me broo

uncut meteor
#

STOP

midnight sonnet
#

omg

#

sorry

#

i'm sorry

icy axle
#

Wait

midnight sonnet
#

lol

#

noo

icy axle
#

You just doxed my ip

uncut meteor
#

i'm tell @rapid crown

supple axle
icy axle
#

:(

midnight sonnet
paper tendon
#

Just use IP mask πŸ™‚ say no to 255.255.255.255 πŸ™‚

#

print that on a mask πŸ™‚

hushed elm
#

banπŸ”¨

#

i don't understand

somber heath
#

I get it, but I don't think it really works.

hushed elm
#

😩 😩 😩 😩

#

byee I'm going

#

luv u :*

hoary dirge
#

@rugged root ohhhh <33333

paper tendon
uncut meteor
#

oh so its a actual address?

#

i was thinking it was a netmask cos of 255.255.255.0

#

oops

paper tendon
#

that specific address send broadcast to each network you are connected to so not only one.

plain dagger
#
            SELECT id FROM table
            WHERE table.user_id = u.id AND something IS NOT NULL
            ORDER BY .created DESC
            LIMIT 1
        )```
uncut meteor
stuck furnace
#

I'm sure I heard someone talking about having a sauna here once before...

uncut meteor
icy axle
ebon flume
#

Different Background pls

icy axle
#

Loll

stuck furnace
#

Alright

ebon flume
#

There is a rabbit to Hitler

#

Wiki game

#

Cant remember how many hours we wasted in school doing rabbit hole

#

Link ?

#

I don't think I can play it on phone

stuck furnace
#

I tried to go via 'mouse' πŸ˜„

#

That failed lemon_pensive

ebon flume
#

Logo is kiling my eyes

#

?

#

Yes

#

I don't get it

#

Start from beginning

#

Voldemort?

pure anchor
#

New round?

ebon flume
#

Idk

#

Do they even read chat ?

stuck furnace
#

Yeah, some people do that because we have an English only rule.

ebon flume
#

I mean it's 1 am here can't use the mic rht now

pure anchor
#

Wikigame, new round?

ebon flume
#

Not me

#

It is what it is

#

+1

#

I be taking one side LoL

#

Illegal?

#

Wdym ?

#

@rugged root what did you mean about can't install thing ?

flat sentinel
ebon flume
#

?

rugged root
#

!warn 549621244731850754 Consider this a follow up of the verbal warning I just gave you. If you continue to interrupt people, attempt to derail the conversation with nonsense and general trolly behavior, I will revoke your voice chat permissions.

wise cargoBOT
#

failmail :ok_hand: applied warning to @whole bear.

pure anchor
#

I dlled books for java, to now work with it. So I mean, it works πŸ˜›

ebon flume
#

Just asking
Was there a topic set for VC ?

pure anchor
ebon flume
#

The topic currently discuss is a bit big brain

#

Defcon

#

Defcon is also a conference

rugged root
flat sentinel
stuck furnace
#

Go to clown school @uncut meteor

uncut meteor
plain dagger
#
A = 2
print    ( A )
faint ermine
#

!e ```py
from future import braces

wise cargoBOT
#

@faint ermine :x: Your eval job has completed with return code 1.

001 |   File "<string>", line 1
002 | SyntaxError: not a chance
flat sentinel
#
    -[                       Skip forward if character is 0
        >>++++[>++++++++<-]  Set up divisor (32) for division loop
                               (MEMORY LAYOUT: dividend copy remainder divisor quotient zero zero)
        <+<-[                Set up dividend (x minus 1) and enter division loop
            >+>+>-[>>>]      Increase copy and remainder / reduce divisor / Normal case: skip forward
            <[[>+<-]>>+>]    Special case: move remainder back to divisor and increase quotient
            <<<<<-           Decrement dividend
        ]                    End division loop
    ]>>>[-]+                 End skip loop; zero former divisor and reuse space for a flag
    >--[-[<->+++[-]]]<[         Zero that flag unless quotient was 2 or 3; zero quotient; check flag
        ++++++++++++<[       If flag then set up divisor (13) for second division loop
                               (MEMORY LAYOUT: zero copy dividend divisor remainder quotient zero zero)
            >-[>+>>]         Reduce divisor; Normal case: increase remainder
            >[+[<+>-]>+>>]   Special case: increase remainder / move it back to divisor / increase quotient
            <<<<<-           Decrease dividend
      ]                    End division loop
        >>[<+>-]             Add remainder back to divisor to get a useful 13
        >[                   Skip forward if quotient was 0
            -[               Decrement quotient and skip forward if quotient was 1
                -<<[-]>>     Zero quotient and divisor if quotient was 2
            ]<<[<<->>-]>>    Zero divisor and subtract 13 from copy if quotient was 1
   
stuck furnace
#

BF is actually kind of cool

#

It has a very simple execution model.

ebon flume
#

It's called

#

Esoteric programming language

flat sentinel
#

[][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]][([][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]]+[])[!+[]+!+[]+!+[]]+(!![]+[][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]])[+!+[]+[+[]]]+([][[]]+[])[+!+[]]+(![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[])[+!+[]]+([][[]]+[])[+[]]+([][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]])[+!+[]+[+[]]]+(!![]+[])[+!+[]]]((!![]+[])[+!+[]]+(!![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+[]]+([][[]]+[])[+[]]+(!![]+[])[+!+[]]+([][[]]+[])[+!+[]]+(+[![]]+[][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]])[+!+[]+[+!+[]]]+(!![]+[])[!+[]+!+[]+!+[]]+(+(!+[]+!+[]+!+[]+[+!+[]]))[(!![]+[])[+[]]+(!![]+[][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]])[+!+[]+[+[]]]+([]+[])[([][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]]+[])[!+[]+!+[]+!+[]]+(!![]+[][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]])[+!+[]+[+[]]]+([][[]]+[])[+!+[]]+(![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[])[+!+[]]+([][[]]+[])[+[]]+([][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]])[+!+[]+[+[]]]+(!![]+[])[+!+[]]][([][[]]+[])[+!+[]]+(![]+[])[+!+[]]+((+[])[([][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]]+[])[!+[]+!+[]+!+[]]+(!![]+[][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]])[+!+[]+[+[]]]+([][[]]+[])[+!+[]]+(![]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[])[+!+[]]+([][[]]+[])[+[]]+([][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]]+[])[!+[]+!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]])[+!+[]+[+[]]]+(!![]+[])[+!+[]]]+[])[+!+[]+[+!+[]]]+(!![]+[])[!+[]+!+

ebon flume
#

There are a lot of then

flat sentinel
#

[]+!+[]+!+[]]+(!![]+[])[+[]]+(!![]+[][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]])[+!+[]+[+[]]]+(!![]+[])[+!+[]]]+[])[+!+[]+[+!+[]]]+(!![]+[])[!+[]+!++[])[+[]]]+[])[+!+[]+[!+[]+!+[]+!+[]]]+[+!+[]]+([+[]]+![]+[][(![]+[])[+[]]+(![]+[])[!+[]+!+[]]+(![]+[])[+!+[]]+(!![]+[])[+[]]])[!+[]+!+[]+[+[]]])

uncut meteor
#

!paste

wise cargoBOT
#

Pasting large amounts of code

If your code is too long to fit in a codeblock in discord, you can paste your code here:
https://paste.pydis.com/

After pasting your code, save it by clicking the floppy disk icon in the top right, or by typing ctrl + S. After doing that, the URL should change. Copy the URL and post it here so others can see it.

uncut meteor
icy axle
uncut meteor
ebon flume
#

Noice

terse vigil
#

so many people

uncut meteor
#

enviormentally friendly paper

icy axle
uncut meteor
#

@faint ermine change ur status to /ˈlɔːnːdΜͺmoΚŠΙ™(r)/

icy axle
uncut meteor
#

/ˈɑrΙͺf/

flat sentinel
#

me sad

pure anchor
#

Feel like I'm regressing in this chat

uncut meteor
#

yeh, I have that effect on people

icy axle
#

The roots of education are bitter, but the fruit is sweet

#
  • Aristotle
hoary dirge
#

is there any science python channel? πŸ˜„

icy axle
hoary dirge
#

might be the closest thing here for that

#

ty πŸ˜„

icy axle
#

No worries πŸ˜„

whole bear
#

guys

#

do u understand this question

#

HELLP

uncut meteor
#

what is the question?

rugged root
#

@whole bear You have to actually ask the question in order for people to understand or help

whole bear
#

this is the question

rugged root
#

Cool, more trolling.

#

Good to know

whole bear
#

no omg

#

its part of my class

#

wtf?/

#

look

rugged root
#

The boxes that block the questions?

whole bear
#

yes im confused

rugged root
#

So are you wanting help with Question 4 down there or figuring out why 3 5 and 6 are messed up?

whole bear
#

theres no 5 and 6

#

its just question 3 and 4

#

idk what question 3 is

#

i thought the prompt is telling you about a JavaScript provided function that can determine if a variable is a number or not and how to use it

rugged root
#

If it's for a class I'd contact your professor and explain the situation

whole bear
#

i dont like him

rugged root
#

That's unfortunate, but it happens

whole bear
#

how about question 4

rugged root
#

And no, the question is about making your own function using an if statement

#

It does mention using isNAN() to make sure that you're filtering out things that aren't numbers, but for the rest it's something you have to write

whole bear
#

oh okay

#

thanks

wet mason
#

Hey trying to extract tar gz with python

rugged root
wet mason
#

Is there a way to automatically make dirs based on path

whole bear
#

so how do i write the function

rugged root
#

That's the part you have to do. It's your homework

wet mason
#

Rip

rugged root
#

@wet mason pathlib might be able to help?

#

Not 100% sure off the top of my head

hollow ridge
#

Mr hemlock brazilians are not welcome here?

amber raptor
knotty spoke
#

voice chat

#

!voiceverify

faint ermine
knotty spoke
#

50 messages ;-;

wise cargoBOT
#

:x: According to my records, this user already has a mute infraction. See infraction #28080.

#

:incoming_envelope: :ok_hand: applied mute to @knotty spoke until 2021-02-12 00:09 (9 minutes and 59 seconds) (reason: duplicates rule: sent 4 duplicated messages in 10s).

sly jolt
#

yeah, no

#

!unmute 766712205952942110

wise cargoBOT
#

:incoming_envelope: :ok_hand: pardoned infraction mute for @knotty spoke.

sly jolt
#

!tempmute 766712205952942110 1d Spamming isn't productive

wise cargoBOT
#

:incoming_envelope: :ok_hand: applied mute to @knotty spoke until 2021-02-12 23:59 (23 hours and 59 minutes).

sly jolt
#

!tvban 766712205952942110 "2 weeks" Spamming messages to up your message count is not the way to get voice verified. You can still join voice channels without being verified; you just have to get some legitimate server activity in order to get verified.

wise cargoBOT
#

:incoming_envelope: :ok_hand: applied voice ban to @knotty spoke until 2021-02-26 00:00 (13 days and 23 hours).

uncut meteor
whole bear
#

!e
from future import braces

wise cargoBOT
#

@whole bear :x: Your eval job has completed with return code 1.

001 |   File "<string>", line 1
002 | SyntaxError: not a chance
tender coral
#

!e
print("hello")

wise cargoBOT
#

@tender coral :white_check_mark: Your eval job has completed with return code 0.

hello
tender coral
#

!e
import turtle, random
turtles = [turtle.Turtle() for i in range(10)]
[t.setheading(random.randrange(360)) for t in turtles]
[t.forward(100) for t in turtles]

wise cargoBOT
#

@tender coral :x: Your eval job has completed with return code 1.

001 | Traceback (most recent call last):
002 |   File "<string>", line 1, in <module>
003 |   File "/usr/local/lib/python3.9/turtle.py", line 107, in <module>
004 |     import tkinter as TK
005 |   File "/usr/local/lib/python3.9/tkinter/__init__.py", line 37, in <module>
006 |     import _tkinter # If this fails your Python may not be configured for Tk
007 | ImportError: libtk8.6.so: cannot open shared object file: No such file or directory
tender coral
#

hello chili

#

it's ok, what are you up to?

#

that's cool what does the discord bot do?

#

I'm just showing my friend discord, how to use it here

#

oh nice

#

that's cool

neat seal
#

hey

zealous wave
#

!e ```py
import typing

def foo(bar : typing.Union[str, int]):
print(bar)

foo(10)
foo('10')
foo({10:'10'})

wise cargoBOT
#

@zealous wave :white_check_mark: Your eval job has completed with return code 0.

001 | 10
002 | 10
003 | {10: '10'}
obtuse trail
#

i had to fix a super annoying issue today, my organization was still using SHA1 hashes on our internal CA, and I couldn't connect with LDAPS. It took me 8 months to figure that out.

eternal bough
lime frost
obtuse trail
#

How is everyone doing?

eternal bough
eternal bough
obtuse trail
#

the actual certs themselves were fine, they were just signed with sha1

#

CA was created in 2014 with an OS from 2012, so what can you expect?

plain dagger
#

at least it wasnt md5

obtuse trail
#

also I'm a bit behind, did they actually break sha-1? I thought they only broke it in theory or on cases that didn't matter

plain dagger
#

well in my country they breached through sha-1 hashed passwords from the government

#

someone*

obtuse trail
#

oh wait nevermind, confirmed in early 2020 that they really broke it

plain dagger
#

yeah

obtuse trail
#

well, our domain controllers for active directory are no longer using it anymore, so that's good! over the next year, all of our SHA1 certs should die out on their own

plain dagger
obtuse trail
#

yup, that's what we're using now

#

fixed the issue I was having with ldaps connections from the ldap3 library almost immediately

limpid pagoda
#

hello

#

@trail perch where are you from India??pithink

limpid pagoda
trail perch
limpid pagoda
#

am i the only one who doesn't have permission to open the micπŸ‘€

trail perch
clear shadow
#

hey @normal hinge

normal hinge
#

Hey bro

limpid pagoda
normal hinge
#

U will

#

Soon

#

Canary

limpid pagoda
#

yeahhπŸ‘€

normal hinge
#

Where are u from?

limpid pagoda
#

Opal i have noticed that you sing really well πŸ‘€

limpid pagoda
normal hinge
#

Oh

limpid pagoda
#

yesterday i guessπŸ‘€

#

can you plz πŸ‘€

#

one songπŸ‘€

normal hinge
#

What does canary means

somber heath
#

It's a bird.

#

Often kept as a pet.

limpid pagoda
#

oh its a kind of bird..and also a female DC character BLACK CANARY you might have heardπŸ‘€

somber heath
#

Often in enclosures far smaller than is humane.

limpid pagoda
#

oh ohkay my net is not working properly πŸ‘€

somber heath
#

Short term for transport and such, the smaller ones are fine.

normal hinge
#

Oh

somber heath
#

Longer term you really want a decently sized setup.

whole bear
#

How to solve dictionary changed size during iteration error

#

?

#

0_0

#

!rule 1

wise cargoBOT
whole bear
#

!rule 5

wise cargoBOT
#

5. Do not provide or request help on projects that may break laws, breach terms of services, be considered malicious or inappropriate. Do not help with ongoing exams. Do not provide or request solutions for graded assignments, although general guidance is okay.

whole bear
#

0_0

#

!rule 3

wise cargoBOT
#

3. Listen to and respect staff members and their instructions.

whole bear
#

!rule 7

wise cargoBOT
#

7. Keep discussions relevant to channel topics and guidelines.

whole bear
#

!rule 6

wise cargoBOT
#

6. No spamming or unapproved advertising, including requests for paid work. Open-source projects can be shared with others in #python-general and code reviews can be asked for in a help channel.

prisma sail
#

hii

whole bear
#

hiii

sick dew
terse needle
#

TOKEN = Secrets[str("Token")] explain

vocal coyote
#

damn(){
console.log("DAMN")
}

terse needle
#
>++++++++[<+++++++++>-]<.>++++[<+++++++>-]<+.+++++++..+++.>>++++++[<+++++++>-]<+
+.------------.>++++++[<+++++++++>-]<+.<.+++.------.--------.>>>++++[<++++++++>-
]<+.
vocal coyote
#

++++++++ [>++++++++++++>+++++++++++++<<-] >++++. -. >+++++++. <+. +.

terse needle
#

[][][][]

#
        c1 = random.choice(suits)
        c2 = random.choice(suits)
        c3 = random.choice(suits)
        c4 = random.choice(suits)
        c5 = random.choice(suits)
        c6 = random.choice(suits)
        c7 = random.choice(suits)
        c8 = random.choice(suits)
        c9 = random.choice(suits)
        c0 = random.choice(suits)
        user1_hand = []
        user2_hand = []
        user1_hand.append(c1)
        user1_hand.append(c2)
        user1_hand.append(c3)
        user1_hand.append(c4)
        user1_hand.append(c5)
        user2_hand.append(c6)
        user2_hand.append(c7)
        user2_hand.append(c8)
        user2_hand.append(c9)
        user2_hand.append(c0)
        v_user1_hand = ""
        v_user2_hand = ""
        v_user1_hand += f"{c1} "
        v_user1_hand += f"{c2} "
        v_user1_hand += f"{c3} "
        v_user1_hand += f"{c4} "
        v_user1_hand += f"{c5} "
        v_user2_hand += f"{c6} "
        v_user2_hand += f"{c7} "
        v_user2_hand += f"{c8} "
        v_user2_hand += f"{c9} "
        v_user2_hand += f"{c0} "
#
            except:
                pass
#
c = [random.choice(suits) for i in range(10)]
vocal coyote
#

01001101 01001111 01000101 01001001 01001110

somber heath
#

!e

alpha = [i for i in range(10)]
print(alpha)```
wise cargoBOT
#

@somber heath :white_check_mark: Your eval job has completed with return code 0.

[0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
pure anchor
#

Anyone worked with Kafka?

somber heath
#

!e python alpha = [(x,y) for x in range(4) for y in range(4)] print(alpha)

wise cargoBOT
#

@somber heath :white_check_mark: Your eval job has completed with return code 0.

[(0, 0), (0, 1), (0, 2), (0, 3), (1, 0), (1, 1), (1, 2), (1, 3), (2, 0), (2, 1), (2, 2), (2, 3), (3, 0), (3, 1), (3, 2), (3, 3)]
terse needle
#
c = [random.choice(suits) for i in range(10)]
user1_hand = [c[i] for i in range(5)]
user2_hand = [c[i+5] for i in range(5)]
v_user1_hand = ' '.join([f'{c[i]}' for i in range(5)])
v_user2_hand = ' '.join([f'{c[i+5]}' for i in range(5)])
somber heath
#

!e print('*'.join('APPLE'))

wise cargoBOT
#

@somber heath :white_check_mark: Your eval job has completed with return code 0.

A*P*P*L*E
terse needle
#

!e

import random

suits = [":hearts:", ":clubs:", ":diamonds:", ":spades:"]
c = [random.choice(suits) for i in range(10)]
user1_hand = [c[i] for i in range(5)]
user2_hand = [c[i+5] for i in range(5)]
v_user1_hand = ' '.join([f'{c[i]}' for i in range(5)])
v_user2_hand = ' '.join([f'{c[i+5]}' for i in range(5)])
print(c, user1_hand, user2_hand, v_user1_hand, v_user2_hand)
wise cargoBOT
#

@terse needle :white_check_mark: Your eval job has completed with return code 0.

[':hearts:', ':spades:', ':spades:', ':spades:', ':clubs:', ':clubs:', ':hearts:', ':clubs:', ':hearts:', ':hearts:'] [':hearts:', ':spades:', ':spades:', ':spades:', ':clubs:'] [':clubs:', ':hearts:', ':clubs:', ':hearts:', ':hearts:'] :hearts: :spades: :spades: :spades: :clubs: :clubs: :hearts: :clubs: :hearts: :hearts:
graceful sail
#

trying to get every "overall" column, along with the date in the column level above

candid plinth
#

can somone teach me how to use python?

graceful sail
#

This Python 3 tutorial course aims to teach everyone the basics of programming computers using Python. The course has no pre-requisites and avoids all but the simplest mathematics.

πŸ”— Sample Code Zip: https://www.py4e.com/code3.zip
πŸ”— Lecture Slides and Handouts: https://www.py4e.com/lectures3/
πŸ”— Free Textbook: https://www.py4e.com/book.php
πŸ”— Co...

β–Ά Play video
#

have fun

somber heath
#

@candid plinth Youtubers Corey Schafer and sentdex are also great to look up.

#

Also

#

!resources

wise cargoBOT
#
Resources

The Resources page on our website contains a list of hand-selected learning resources that we regularly recommend to both beginners and experts.

candid plinth
#

ok thanks man

somber heath
#

@candid plinth If you need any clarifications on a specific point, feel free to ask about it on this server. πŸ™‚

candid plinth
#

ok

graceful sail
zealous wave
#

!e ```py
from future import braces

wise cargoBOT
#

@zealous wave :x: Your eval job has completed with return code 1.

001 |   File "<string>", line 1
002 | SyntaxError: not a chance
zealous wave
#

!e ```py
import antigravity
import hello
import this
"""from future import braces"""

graceful sail
#

look at this ish

wise cargoBOT
#

@zealous wave :white_check_mark: Your eval job has completed with return code 0.

001 | Hello world!
002 | The Zen of Python, by Tim Peters
003 | 
004 | Beautiful is better than ugly.
005 | Explicit is better than implicit.
006 | Simple is better than complex.
007 | Complex is better than complicated.
008 | Flat is better than nested.
009 | Sparse is better than dense.
010 | Readability counts.
011 | Special cases aren't special enough to break the rules.
... (truncated - too many lines)

Full output: https://paste.pythondiscord.com/foqomurisi.txt

graceful sail
#

look how good that is!!!

zealous wave
#

255.255.255.255

terse needle
#

192.168.0.1

zealous wave
#

@pure anchor are u french?

pure anchor
#

How so?

#

Curious how you arrived at france ^^

zealous wave
#
  1. you give me europe vibes, 2) the name of your song was in french just now
pure anchor
#

I'm European, same country as vestergurkan

zealous wave
#

ahh right

#

bc u know what a gurkan is

pure anchor
#

Exactly^_ ^

#

192.172 - error isp network

#

I worked with networking before this and security is lax af.

#

Lword shane. Just sayin

shy summit
#

talk more

rugged root
#

And proper talking, not spamming

#

We monitor that

shy summit
graceful sail
#

goodnight

shy summit
#

is there a lounge for foreign languages?

hoary dirge
#

any matplotlib.pyplot experts here? πŸ˜„

somber heath
lunar pendant
#

hello opalmist

somber heath
#

I ride the docs when I use it at all.

hoary dirge
#

Opal for the rescue. Im just trying to find out:
Is there way to present a graph and let the program keep running?
atm, I can either get one graph and only once I close it will the program calculate the next graph.
Or I will get all of the graphs at the end of the program.

somber heath
#

There's an animated plotting thing.

#

Which you might be able to update as you go.

#

I used it once a long time ago, but I can't remember enough to say if it would suit what you're trying to do.

hoary dirge
#

do you mean it will change the plot as it goes?

somber heath
#

Yeah. That's a thing that you can do. You can clear it out and start again, too, probably.

zealous wave
#

!d os.chdir

wise cargoBOT
#
os.chdir(path)```
Change the current working directory to *path*.

This function can support [specifying a file descriptor](#path-fd). The descriptor must refer to an opened directory, not an open file.

This function can raise [`OSError`](exceptions.html#OSError "OSError") and subclasses such as [`FileNotFoundError`](exceptions.html#FileNotFoundError "FileNotFoundError"), [`PermissionError`](exceptions.html#PermissionError "PermissionError"), and [`NotADirectoryError`](exceptions.html#NotADirectoryError "NotADirectoryError").

Raises an [auditing event](sys.html#auditing) `os.chdir` with argument `path`.

New in version 3.3: Added support for specifying *path* as a file descriptor on some platforms.

Changed in version 3.6: Accepts a [path-like object](../glossary.html#term-path-like-object).
zealous wave
#

@dense ibex if u are still getting that issue with the json file check this out

lucid mountain
#

Yeah

#

True

candid venture
#

@rugged root

#

ITS ALIVE

#

ITS WORKING

#

@hoary dirge israeli arent you?

hoary dirge
sick dew
#

.

hoary dirge
sick dew
#
def read_json(filename):
    with open(f"./{filename}.json", "r") as f:
        data = json.load(f)
    return data
honest pier
#

did he say not to use with open

candid venture
somber heath
#
import random
print(hex(random.randint(0,16777215))[2:].zfill(6))```
wise cargoBOT
zealous wave
#
import discord
from discord.ext import commands


class FooBar(commands.Cog):
  def __init__(self, bot):
    self.bot = bot


  @commands.command()
  async def foo(self, ctx):
    await ctx.send("bar")


  @commands.Cog.listener()
  async def on_message(self, message):
    await message.channel.send("foo")

  await self.bot.process_commands(message)


def setup(bot):
    bot.add_cog(FooBar(bot))
sick dew
#
import discord
from discord.ext import commands
import json

def read_json(filename):
    with open(f"./Data/{filename}.json", "r") as f:
        data = json.load(f)
    return data


def write_json(filename, data):
    with open(f"./Data/{filename}.json", "w") as f:
        json.dump(data, f)
    return data



class Template(commands.Cog):
    def __init__(self, BOT):
        self.BOT = BOT

    """
    @commands.command(name="", description="", usage="")
    async def
    """

    """
    @commands.Cog.listener()
    async def
    """


def setup(BOT):
    BOT.add_cog(Template(BOT))
somber heath
#
import random
choice = ''.join([random.choice('abcdef0123456789') for i in range(6)])
print(choice)``` A little nicer, probably.
honest pier
#

!d random.choices

wise cargoBOT
#
random.choices(population, weights=None, *, cum_weights=None, k=1)```
Return a *k* sized list of elements chosen from the *population* with replacement. If the *population* is empty, raises [`IndexError`](exceptions.html#IndexError "IndexError").

If a *weights* sequence is specified, selections are made according to the relative weights. Alternatively, if a *cum\_weights* sequence is given, the selections are made according to the cumulative weights (perhaps computed using [`itertools.accumulate()`](itertools.html#itertools.accumulate "itertools.accumulate")). For example, the relative weights `[10, 5, 30, 5]` are equivalent to the cumulative weights `[10, 15, 45, 50]`. Internally, the relative weights are converted to cumulative weights before making selections, so supplying the cumulative weights saves work.... [read more](https://docs.python.org/3/library/random.html#random.choices)
hoary dirge
sick dew
honest pier
#

!e

import random
choice = ''.join([random.choice('abcdef0123456789') for i in range(6)])
print(choice)
wise cargoBOT
#

@honest pier :white_check_mark: Your eval job has completed with return code 0.

759cb7
honest pier
#

?

honest pier
#

oh

somber heath
#

Old code.

#

Use new, better code.

somber heath
#

Yes.

sick dew
#

ight

honest pier
#

why not use randint lol

swift valley
#

I lurk

honest pier
#

!e

from random import randint
print(hex(randint(0, 16777216)))
wise cargoBOT
#

@honest pier :white_check_mark: Your eval job has completed with return code 0.

0x494810
honest pier
#

πŸ€”

somber heath
#

Now subscript, then zfill.

#

Which is the old code.

#

New code is more readable.

hoary dirge
sick dew
#

0x000000 -> 0xFFFFFF

honest pier
#

πŸ˜ƒ

somber heath
hoary dirge
honest pier
#

although that actually doesn't work lol

sick dew
swift valley
#

Greetings

#

I was actually gonna buy one for my laptop lol

dense ibex
honest pier
#

πŸ‘€

swift valley
#

It just calls stow for me

honest pier
#

where's your init.vim

swift valley
#

But fancier

rugged root
swift valley
#

logo_emacsmacs gang

honest pier
#

smh

swift valley
#

You can protect it with a license Β―_(ツ)_/Β―

#

or no license

lunar pendant
swift valley
#

@terse needle A window manager is basically what renders your applications while desktop environments are bundles of software that may or may not invoke your window manager as well as manage a few startup resources

terse needle
#

right

#

so a desktop environment is a window manager and more

swift valley
#

A desktop environment is a collection of similarly-looking GUI applications

terse needle
#

hmmm

#

so i've been thinking of switching to dwm on arch, all I want is Atom, Chrome, Discord and a terminal. I can get all of that on a window manager like dwm. right?

rugged root
swift valley
terse needle
#

nice

dense ibex
sick dew
swift valley
#

Neovim has an API for Python-based plugins lemon_eyes

#

Although it prefers Lua

icy axle
#

I honestly don't like the body of these things

hushed elm
#

wrangle people

#

that's hot

somber heath
#

Regex is very good at doing what it does. It's powerful and highly adaptable. It looks like garbled sorcery, but once you go through it, it starts to make a lot of sense and then it's not as intimidating.

zealous wave
hushed elm
#

hat

#

HAT

lethal crest
#

i cant hear anyone. are you guys talking?

zealous wave
lethal crest
#

okay

final ember
#

what is better vim or neovim?

honest pier
#

personal preference

#

they're both orders of magnitude better than sublime

hushed elm
#

oooh noo

#

we're gonna get into this discussion again

final ember
hushed elm
#

oooh noooo

zealous wave
#

ima stay out of this bc i use pycharm :sadge:

icy axle
final ember
#

lel

hushed elm
#

vscode bestcode

hushed elm
icy axle
#

It's a weird ox

honest pier
rugged root
icy axle
#

:(

dense ibex
#

!source

wise cargoBOT
rugged root
#

Nope, still seeing a canoe

#

He is adorable, though

icy axle
#

HAhah

rugged root
#

Back later, delivery run time. Will likely be back in like.... an hourish?

dense ibex
#

Sounds good

dense ibex
honest pier
#

just use a relative path

dense ibex
honest pier
#

with open('banned_words.json') ...

dense ibex
paper tendon
#

yeap

sick dew
#
{"banned words": ["Hello", "Hi"]}
plush willow
#

does anyone know about a web based editor which edits python according to pep8?

paper tendon
#

{"banned words": ["Hello", "Hi"]}

honest pier
#

@plush willow look up black

#

not web based, but does what you want

paper tendon
#

flake8 πŸ™‚

honest pier
#

flake8 πŸ‘Ž

spiral monolith
#

black

icy axle
paper tendon
#

gray 8D

sick dew
#
with open("./cogs/*filename*.json", "r") as f:
  data = json.load(f)

banned_words = data["banned words"]

for word in banned_words:
  if word in message.content:
    #Do whatever here
honest pier
#
...
banned_words = json.load(f)
...
paper tendon
#

data structure πŸ™‚

sick dew
paper tendon
#

use sqlite

honest pier
sick dew
#

Not to sound cocky but that is why I but the statement like it is

honest pier
#

?

sick dew
honest pier
#

i wouldn't say correct

#

since yours isn't wrong

sick dew
#

fair

honest pier
#

it's just doing something that makes no sense

sick dew
#

o

honest pier
#

you have an object with 1 field in it

#

why

icy axle
#

lol

zealous wave
#
    @commands.command(aliases=['h'])
    async def help(self, ctx, command : commandtypehint = None):
sick dew
#
async def help(self, ctx, thing):
  searched_command = self.BOT.get_command(thing.lower())
  if not searched_command:
    await ctx.send(f"Invalid argument: '{thing}'. Please choose a page number from 1-{total_pages} or specify the category.")
    return
zealous wave
#

!e ```py
import datetime

print(datetime.datetime.now())

honest pier
#

nice

wise cargoBOT
#

@zealous wave :white_check_mark: Your eval job has completed with return code 0.

2021-02-12 16:56:42.541120
zealous wave
#

hmm idk why it works for me

honest pier
#

presumably because you did from datetime import datetime

zealous wave
#

!e ```py
from datetime import datetime

print(datetime.now())

wise cargoBOT
#

@zealous wave :white_check_mark: Your eval job has completed with return code 0.

2021-02-12 16:57:45.887086
zealous wave
#

hmm ok

#

ig im magical

honest pier
#

i bet you did from datetime import datetime

zealous wave
#

i mean its possible bc i am blind

round prawn
#

Π“Π΄Π΅ я

dense ibex
#
import discord
from discord.ext import commands
# discord imports

import json
import datetime


class Antiswear(commands.Cog):
    # creating the cog class
    def __init__(self, bot):
        self.bot = bot
        # initializing the class and defining bot

    @commands.Cog.listener()
    async def on_message(self, message):
        if message.author.bot:
            return
            # checks if the message author is a bot, and if they are the bot ignores them
        else:
            with open("./cogs/bannedwords.json", "r") as f:
                data = json.load(f)

                for word in data:
                    if word in message.content():
                        await message.delete()

                        # checks if any word in our banned word list is in the message

                        embed = discord.Embed(
                            colour=discord.Colour.default(),
                            timestamp=datetime.datetime.now()
                        )
                        # creating and setting the color of an embed object

                        embed.add_field(name="Deleted Message", value=f"Deleted message from {message.author}")
                        # setting the embed value
                        embed.set_footer(text=message.author, icon_url=message.author.avatar_url)
                        # adding a timestamp to the embed

                        await message.channel.send(embed=embed)
                        # sending the embed

        await self.bot.process_commands(message)
        # if the message is a command, let the command be processed


def setup(bot):
    bot.add_cog(Antiswear(bot))
    # registering the cog
#
                    if word.lower() in message.content.lower():
                        await message.delete()
#

cuddlybunny

sick dew
#
await message.channel.send(embed=embed, delete_after=10)
honest pier
#

ngl, just telling him exactly what to write is not very productive or helpful

paper tendon
#

damn still that

honest pier
#

@sick dew ^

sick dew
#

oh sorry

dull hollow
#

what does the import mean

#

on jake's code

sick dew
#

?

#

which one?

dull hollow
#

is there a way in python to make functions and save them and use them when writing other pieces of code

sick dew
#
with open("./cogs/bannedwords.json", "rw") as f:
  data = json.load(f)

#Code Here

with open("./cogs/bannedwords.json", "rw") as f:
  json.dump(data, f)
#

[prefix][command name] [args]

honest pier
#

that would not work

#

after exiting the context manager, the file is closed

#

@dense ibex show code

sick dew
viscid perch
#

everything

terse needle
#

<< >> ::

stuck furnace
#

How does importing work in Rust. Is it text-based like C? πŸ˜„

honest pier
#

wdym tetx based

stuck furnace
#

Like how when you include in C it's literally like copying and pasting the source code

honest pier
#

huh, idk

stuck furnace
#

At least, as far as I remember...

dense ibex
#
    @commands.command()
    async def addword(self, ctx, *, word):
        with open('./cogs/bannedwords.json', 'w') as f:
            data = json.load(f)

            data.append(word)
        with open('/cogs/bannedwords.json', 'w') as f:
            json.dump(data, f)

#
 @commands.command()
    async def addword(self, ctx, *, word):
        with open('./cogs/bannedwords.json', 'r') as f:
            data = json.load(f)
            print('Data Loaded')

            data.append(word)
        with open('./cogs/bannedwords.json', 'w') as f:
            json.dump(data, f)
            print('Data Dumped')
#

Data Loaded
Data Dumped
Data Loaded
Data Dumped

honest pier
#

fuuck !

dense ibex
#

!source

wise cargoBOT
terse needle
honest pier
#

.

stuck furnace
honest pier
#

.xkcd

viscid lagoonBOT
#
XKCD comic #558
stuck furnace
#

Oh right πŸ˜„

#

.xkcd 292

viscid lagoonBOT
#
XKCD comic #292
honest pier
#

yay

zealous wave
#

!e ```py
import typing

def foo(bar : typing.Union[str, int]):
print(bar)

foo(1)
foo('1')
foo(10.0)

wise cargoBOT
#

@zealous wave :white_check_mark: Your eval job has completed with return code 0.

001 | 1
002 | 1
003 | 10.0
honest pier
#

!e

x: str = 10
print(x)
stuck furnace
#

Let's run that through mypy...

wise cargoBOT
#

@honest pier :white_check_mark: Your eval job has completed with return code 0.

10
honest pier
#

!e

x: "lmfao, you can literally put any python expression here" = 10
print(x)
wise cargoBOT
#

@honest pier :white_check_mark: Your eval job has completed with return code 0.

10
stuck furnace
#
> mypy test.py
test.py:8: error: Argument 1 to "foo" has incompatible type "float"; expected "Union[str, int]"
Found 1 error in 1 file (checked 1 source file)
honest pier
#

πŸ˜”

stuck furnace
#

Would be cool if we had a .mypy command actually πŸ€”

honest pier
#

πŸ€” maybe

#

even better would be a !black

#

or maybe
!e pypy

zealous wave
#

!e ```py
import typing

def foo(bar : typing.Optional[str]):
print(bar)

def bar(foo = None):
print(foo)

wise cargoBOT
#

@zealous wave :warning: Your eval job has completed with return code 0.

[No output]
stuck furnace
#
def bar(foo : str = None):
  print(foo)
``` wouldn't pass static type checking.
#

As None isn't a str.

#

Optional[str] == Union[str, None]

#

Hello πŸ‘‹

#

You asking me? πŸ˜„

#

I think in swift they use ?

honest pier
#

swift has an actual optional type

stuck furnace
#

Actually, I just tested it and it passed pithink

#

Weird. This fails: py def foo(x: str): ... foo(None) but this is fine: ```py
def foo(x: str = None):
...
foo()

honest pier
#

wild

#

that's cute πŸ₯Ί

somber heath
#

@rugged root Bottle of whine.

stuck furnace
#

Did some language lawyering...

#

A past version of this PEP allowed type checkers to assume an optional type when the default value is None, as in this code:

def handle_employee(e: Employee = None): ...

This would have been treated as equivalent to:

def handle_employee(e: Optional[Employee] = None) -> None: ...

This is no longer the recommended behavior. Type checkers should move towards requiring the optional type to be made explicit.

#

PEP 484

honest pier
#

cat pep-484

#

πŸ˜”

#

enzyme kinetics are cringe

#

or is, actually

somber heath
#

There's a lot of employee handling going on, there. Are we sure HR doesn't need to get involved?

stuck furnace
#

Toothpick?

#

I like the umbrellas πŸ˜„

honest pier
#

it's like, how enzymes fold

#

||i'm not 24||

stuck furnace
#

Soo...

#

What's everyone up to?

honest pier
#

wikipedia pages !

stuck furnace
#

Wombats?

#

You are in Australia πŸ˜„

dire oriole
#

folding funnel 😳 @honest pier

honest pier
#

i-

rugged root
#

Daaaaaaaaaaaaaaawwwwwwwwwwwwwww

stuck furnace
#

They're so cute πŸ˜„

topaz schooner
#

^_^

#

lol

rugged root
#

Their pouches point backwards

stuck furnace
#

Probably gamey

#

I have experience, but no memory of that experience πŸ˜„

topaz schooner
#

lol XD

stuck furnace
#

Brain like a sieve lemon_pensive

rugged root
#

Drank to forget the memory of it

somber heath
#

Baby wombats are adorable.

rich cloud
#

misery

#

xD

stuck furnace
#

It's a kind of useful word

rich cloud
#

wut in tarnation

stuck furnace
#

I really want to use it, but I'd sound like a twat saying it πŸ˜„

topaz schooner
#

Its night for me Technically Sat now XD

rich cloud
#

finished cyberpunk lemon_thinking

#

gr8 game

topaz schooner
#

Dammn Cool

rich cloud
#

it's like neuralink in 50 years

#

partially

topaz schooner
#

I'm a Visual Effects Artist

plucky grail
#

I want to make a platform where people can buy and sell mailiing list, leads ?
How is the idea?

rich cloud
#

"Personality: Fire Ox people are hot tempered, and they are easily influenced by others' words and actions."

rugged root
stuck furnace
#

All I remember from chemistry is if you mix things on the left side, with things on the right side, it goes bang.

rich cloud
#

balancing equations ey?

honest pier
#

πŸ˜”

rich cloud
#

sounds fun

honest pier
#

redox reactions πŸ‘Ž

stuck furnace
#

That's because everything is optional once you reach A-levels @uncut meteor

#

I literally just did maths, physics, and further maths.

honest pier
#

"further maths"

stuck furnace
#

Ah right πŸ˜„

honest pier
#

"far maths"

stuck furnace
#

You can also do "additional further maths"

#

If you really want no variety in your curriculum πŸ˜„

#

A level maths 2: electric boogaloo

honest pier
#

smfh

#

||i thought he said torque, i was opening up my textbook||