#voice-chat-text-0

1 messages ยท Page 891 of 1

amber raptor
#

@coarse cape absolutely not

coarse cape
#

hewwo wabbit

coarse cape
amber raptor
#

Friend request

coarse cape
#

oh yikes

#

alright

#

thats cool

pastel finch
#

how i have to use the init function?

brittle mango
#

noise supresion ftw

amber raptor
#

We call that proper voice chat etiquette

coarse cape
amber raptor
#

Sparingly

brittle mango
#

people usually don't add randoms to friend list

gentle flint
#

@rugged root

coarse cape
#

i cant stay silent for 10s straight

#

lul

#

cya hemlock

amber raptor
#

Can I veto voice verification

honest pier
#

approved

amber raptor
#

!tvveto

coarse cape
#

so lemme tell about all the animals in this vc

gentle flint
rich gyro
#

what is that

#

some kind of sprayer

gentle flint
gentle flint
rich gyro
vivid palm
#

@somber heath are you sleeping lol

amber raptor
#
import logging
from discord_interactions import verify_key


class Auth:
    def __init__(self, public_key:str) -> None:
        self.public_key = public_key

    def verify(self, body:str, signature:str , timestamp:str) -> bool:
        try:
            if verify_key(body, signature, timestamp, self.public_key) is True:
                return True
            else:
                return False
        except Exception as e:
            logging.error("Unable to validate due to error while encoding")
            logging.info(f"{e}")
            return False```
#
    auth = Auth(os.getenv("app_public_key"))
    body = await request.json()
    body_str = await request.body()
    if auth.verify(
        body=body_str,
        signature=X_Signature_Ed25519,
        timestamp=X_Signature_Timestamp
    ) is False: #Meaning it's invalid
      raise HTTPException(
            status_code=401,
            detail="Invalid Token"
        )```
#

discord-interactions==0.3.0

gentle flint
#

Gonna go change the bins
back in a bit, maybe

brave steppe
gentle flint
#

hi opal

somber heath
gentle flint
#

small snores

#

I'm off, cya

honest pier
#

๐Ÿ‘€

sweet lodge
#

What happened was...

#

Can I throw a Sphinx question here?

So - I'm importing some information for Sphinx from the Poetry section in mypyproject.toml. But there are a few pieces of information that Sphinx wants that Poetry doesn't. For example,
pyproject.toml

[tool.poetry]
name = "bradworks"
version = "0.3.0"

Sphinx conf.py

project_config = toml.load('../../pyproject.toml')
project = project_config['tool']['poetry']['name']
release = project_config['tool']['poetry']['version']
copyright = '2021, Darbia'

Can I just add copyright as another attribute under tool.poetry?
Should I add a tool.sphinx?
Or should I add another tool._ that doesn't overlap Sphinx's name?

somber heath
#

Is it a hello wave?

#

"Hi! Kpschch!"

hidden flower
#

hello!

cobalt fractal
rugged root
#

!e

def add(a, b):
  return a + b

functions = {
  "print": print,
  "add": add
}

functions["print"]("hello")
functions["print"](functions["add"](1, 2))
wise cargoBOT
#

@rugged root :white_check_mark: Your eval job has completed with return code 0.

001 | hello
002 | 3
rugged root
somber heath
#

Imperfect. I'm perfect.

#

Looks like something that'd go with a Live Laugh Love style wall hanging.

gentle flint
#

I must go

#

farewell

somber heath
#

Your people need you.

gentle flint
#

adieu

swift valley
#

Hello

#

Trying to boot Alpine Linux on a VM but it won't budge

#

Also half-finished with the deserialization thingie

rugged root
#

!tvban 859699211775639562 1w Looking back through your history, you seem to only be here to troll. Jumping into voice calls and interrupting people and talking loudly is not acceptable behavior.

wise cargoBOT
#

:incoming_envelope: :ok_hand: applied voice ban to @whole bear until <t:1631291432:f> (6 days and 23 hours).

swift valley
#

There we are

brave steppe
#

lol what

rugged root
#

Dude who did you piss off

brave steppe
#

On Python 3 '{}'.format(b'abc') produces "b'abc'", not 'abc'; use '{!r}'.format(b'abc') if this is desired behavior

rugged root
#

Sure but the first response to jumping into a channel shouldn't be loud talking. There could be an ongoing conversation, which could be (and was) interrupted

vast lion
#

Why 50 text messages are needed for voice channel

dense ibex
rugged root
#

@vast lion So the reason is that for a long while, we had a bunch of what I call hit and run trolls. They join the server, join the voice chat, scream, and then leave. This has eliminated that issue almost entirely. Before we were having 4 or 5 a day. Now it's closer to 1 or 2 a month

#

If you plan on being in the server for a while, the 3 days and 50 messages over three 10 minute blocks is a drop in the bucket.

safe dew
#

@pine minnow hi how are

#

i can hear you but i dont have permission to talk

#

@whole bear hey man

#

no sadly

#

i k

#

but i have to a lot of things

#

yea yea

#

any ways

#

i am software eng

#

this is my first year

#

do i need python?

#

actually if i dont need it i will try to read because i like the simply of python

#

i use pycharm

#

idk man but pycharm seems so good for learning

pine minnow
#

i do to

safe dew
#

i use the normal vs

#

not vs code

#

it doesn't have terminal isn't it

#

yea

pine minnow
#

I am Afk for a moment just getting some smokes

safe dew
#

do you work ?

#

or a student

#

very nice man

#

i need some advices here

#

am just a student in the first year

#

and idk what to do

celest mantle
#

Lol

safe dew
#

how to get the exp to work

#

in my country its very hard to work

#

my college is not that good also

celest mantle
#

I'm applying for jobs that pay less than $50 a month in my country to get my foot in the door.

safe dew
#

Jordan

celest mantle
#

I tried Fiver and Freelancer couldn't make that work.

#

Bangladesh.

safe dew
#

in middle east

celest mantle
#

South Asia country are the worst place to work dev jobs IMO.

#

Couldn't have said better myself.

safe dew
#

@whole bear where are you from

celest mantle
#

Supply goes up, demands stay stagnant, wages go down.

safe dew
#

maybe i will come to work in US as a cash captain or something

celest mantle
#

We got startups operating from apartments driving up the housing price in here.

safe dew
#

how to know when i joined this group

celest mantle
#

They buy cheap 1000 square foot flats to avoid commercial places that charge more rent than residential places.

#

@whole bear speaks... Windows takes notes

#

Like market research.

safe dew
#

laguna do you know where i should learn python and java

celest mantle
#

~$5 per line.

#

Companies gonna have a field day when they automate coding jobs.

pine minnow
#

i am back

safe dew
#

welcome

celest mantle
#

Like in 50 years I mean at least.

safe dew
#

do know somewhere to learn python @pine minnow

celest mantle
#

Low-code are hard as hell to customize.

safe dew
#

yes

celest mantle
#

@safe dew Hit the docs bro.

safe dew
#

what docs

celest mantle
#

True.

safe dew
#

me and my friends just leant c++

#

nothing else

#

yea college

pine minnow
#

i learnt what i now from youtube and reading textbooks

celest mantle
#

Check out the CS50 Python classes online in YouTube.

safe dew
#

can you give me a link

#

Harvard?

celest mantle
#

My Prof said only C++ programmers are real programmers. Everyone else are script kidies.

safe dew
#

am learnt that thing man

#

am just studied the arrays and func

celest mantle
#

I mean Python basics in those courses basics that translate well to any languages in my experience.

safe dew
#

i think the next lang in college c#

celest mantle
#

I mean people want fast I just ask them right opcodes for the processor their gonna run it on. Or better yet, program your FPGA and stop blowing air up by rear end.

safe dew
#

idk man java || python

#

what FPGA means?

celest mantle
#

Field-programmable gate array

safe dew
#

am too bad with eng i have to learn eng first

celest mantle
#

Java and C# makes me sweat balls. I too enterprisey.
True.

safe dew
#

thanks balls

#

_00

#

This course will give you a full introduction into all of the core concepts in python. Follow along with the videos and you'll be a python programmer in no time!
Want more from Mike? He's starting a coding RPG/Bootcamp - https://simulator.dev/

โญ๏ธ Contents โญ
โŒจ๏ธ (0:00) Introduction
โŒจ๏ธ (1:45) Installing Python & PyCharm
โŒจ๏ธ (6:40) Setup & Hello Wor...

โ–ถ Play video
pine minnow
safe dew
#

is this vid good

safe dew
celest mantle
#

True. NPM is like "you have 69 outdated packages. 420 packages are looking for funding" after 6 months.

#

pip coming in cluth.

#

*clutch.

#

Pipenv and poetry support this as well.

pine minnow
#

can i make a suggestion? lets start a group where we all can talk?

celest mantle
#

Python's package managers are the best in my experience. Cargo is good as well.

safe dew
#

am in man

#

still 3 days!

celest mantle
#

You @safe dew ask for python recommendations in the other channels to rack up the requirements.

safe dew
#

requirements of what

celest mantle
#

For permission to speak in the Voice Chat.

safe dew
#

i did

#

Voice Gate failed
You are not currently eligible to use voice inside Python Discord for the following reasons:

โ€ข You have been on the server for less than 3 days.

#

nah man

#

i think something like this

#

i forgot

#

idk i want to talk

#

am very bad typer

latent zealot
celest mantle
#

Nope.

#

It says less than 50.

#

Been here for about 6 months.

safe dew
#

i do 21 wpm

#

so i am bad

celest mantle
#

I don't wanna spam in the other channel.

#

Been fine. Thank you for asking.

#

I mean, it hasn't been worse than normal so I'm grateful for that.

safe dew
#

so you want to go to other group to talk

celest mantle
#

I used it for my thesis. Currently trying to find some company who will let it use me for some job.

#

It's a sub in my opinion.

#

Software engineering.

#

B D S M.

#

Likewise.

#

It's like potato. Goes well alone or with anything else.

#

Math bro.

#

I had trouble explaining long division to someone else a few days back.

#

Lol.

#

Sorry man. Everyone in my class laughed when our prof said BigO.

#

No lol. We used to memorize math.

#

It's like finding the right thing to search. Stackoverflow has you covered for the most part after that.

#

Yeah.

#

At least that makes us good.

#

People don't google in other industries and makes silly mistakes and don't get with the times.

#

At least Google won't share the ad revenue. At least let me use the search result to make money.

#

Inception.

#

Duckduckgo all the way bro for me.

#

Of course.

#

The right tool for the right job.

#

I just !g on duck duck go when I need to go to Google.

#

I'm not even married to this career.

#

Yes.

#

Probably an obscene amount.

#

I'm trying to buy farm land so I can grow my own food and raise my own cows and chicken.

#

It's not about the money.

#

It's about sustenance.

#

I saw a company like that.

#

Right?

#

Singapore won't give me visa so I can't go work there.

#

I open to both.

#

*am

#

USA, UK sounds good as well.

#

No China.

#

I know people who work in China personally.

#

They won't speak to me about their work condition over the phone.

tulip plover
#

hi

celest mantle
#

I only know the real dets cause they came to visit me in our country.

#

You can live in peace and even like kings as long as you suckle the CCP.

#

Every company worth working in has tries to the govt.

#

You need those ties if you want to climb the proverbial career ladder.

#

Of course.

#

They give you marks.

#

Their private companies have ties with the government as well.

#

Lockheed martin be swimming in that F-35 dollar money.

#

US military has china screws holding them armor plates.

#

My voice verification channel has dissapeared.

#

I can't unmute though.

#

Okay. BRB.

#

Maybe my mic died. Let me check.

brave steppe
#

!voice

wise cargoBOT
#

Voice verification

Canโ€™t talk in voice chat? Check out #voice-verification to get access. The criteria for verifying are specified there.

brave steppe
#

@slim marsh

whole bear
kind blaze
#

aaa

#

I can't talk!

somber heath
#

!e py def func(): pass print(func.__repr__())

wise cargoBOT
#

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

<function func at 0x7fa29e3a2040>
somber heath
#

!e from random import randint print(randint.__repr__())โ€Š

wise cargoBOT
#

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

<bound method Random.randint of <random.Random object at 0x56120ad08a60>>
somber heath
#

@past pawn I'm afraid I must disappoint. I gave up on chains very early on into my internet presence. ๐Ÿ˜

past pawn
#

hang on ill get headphones

somber heath
#

Nevertheless, I appreciate the whimsy.

past pawn
#

I just owe it to the last person i DMed ||"Tomato"||

#

@cobalt fractal you are playing Path of Exile.
In Act 2, there's an easter egg aimed specifically at Australians.
Go to the Western Forest (Act 2) and run around some trees. Preferably after researching Australian legends ;)

somber heath
#

Dropbears?

past pawn
#

yes

#

except they're called "Plummeting Ursa" or something like that

#

the plummeting ursa look like marsupials, too

#

except with red eyes and sharp blood dripping teeth

#

XD

#

I walked past a massive snake, it was pretty chill until 20 different birds started bullying it

#

they were plovers, miner birds, magpies and rainbow lorikeets

#

the plovers were the first to bully the snake, which looked like it was about to eat one of them

#

@somber heath you got bin chickens?

#

lol q

#

yeah they stink too

#

i've seen a few ducks, theyre not common though

#

it's been a few years since i've seen black ibii, but white one's are common, and they bully my chickens :/

#

You get curlews?

#

they frikin scream at night time

#

I'll see if i have a photo of one

#

hang on...

#

sounds like someone screaming

#

lmao

#

magpies seem intelligent compared to most other birds around here

#

they wont say no to food, but they're still cautious.
If bullied, they become a swooping magpie during mating season.
There's this one trying to get in my windows for a few months straight just pecking on the window while i have breakfast near it

somber heath
past pawn
#

ooh, nice

#

hey, same!

cobalt magnet
#

hello there

#

cant speak today lol

past pawn
#

it is the 4th for three hours and 45mins

cobalt magnet
#

ill do some redstone while in vc

past pawn
#

@cobalt magnet sign language XD

cobalt magnet
#

but my webcam is like 2 pixels

past pawn
#

lmao

brave steppe
#

hahaha

past pawn
cobalt magnet
#

im like 0.094504950868045 braincells

#

hello

past pawn
#

my cat is being cute

cobalt magnet
past pawn
#

she's also right here

#

next to me

#

also on her own office chair

#

I can move the chair around and she's completely chill

#

If that isn't a good enough reason for temporary video perms I dunno what is

past pawn
#

well she's got bored and walked off now

#

I guess I'll feed her then

#

she's back

#

can you hear the purring?

cobalt magnet
#

i can hear a keyboard

brave steppe
#
"""
My thing here.
"""
#
"""
My small thing here.

Long description I don't care about because I can't support it.
"""
coarse cape
#

hewwo bluenix

past pawn
#

There I fed Lily, she should purr louder for you guys

#

just a sec though i gotta feed myself

somber heath
#

!e py print("Apple".split("."))

wise cargoBOT
#

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

['Apple']
cobalt magnet
#

yes

brave steppe
cobalt magnet
#

whispering dude

#

um why did my icons just refresh for no reason

past pawn
#

probably windows updating or settings being applied

cobalt magnet
#

i just alt tabbed out of minecraft

coarse cape
#

bluenix have you tried vim ?

cobalt magnet
#

and saw all icons refresh

coarse cape
#

oh hehe

#

hmm

past pawn
#

probably lazy loaded

cobalt magnet
#

there's so much color in maxed out minecraft fireworks

#

they do damage when shot out of crossbows

#

they do a LOT of damage

#

yes splash damage

#

i didnt get you

#

you just hold the firework in offhand and crossbow in main hand and then hold right click to load

#

in offhand if you have other loadable projectiles

#

in your inventory

cobalt magnet
#

i have a beautiful 1600 x 900 monitor lol

#

oh god i kept firing fireworks from a redstone clock now the sound is in my head

whole bear
#

yes

past pawn
#

something in my laptop sounds like crackling electricty

#

its very faint though

cobalt magnet
#

thats scary

past pawn
#

i gotta put my ear to it

cobalt magnet
#

anyway im gonna edit a video now

#

while in vc

past pawn
#

yeah that's what it sounds like

#

but very quiet

#

I pulled out the charger cable it stopped buzzing

coarse cape
#

im good!!!

#

ty for asking

#

hbu?

cobalt magnet
#

im pretty sure you usually leave a few micro meters anyway

coarse cape
#

awesome

#

yeah

#

its kinda pleasant here

#

yea

#

but goin back

#

tomorrow

#

australia

#

^

#

lol

#

bluenix, i had a doubt-

#

when will wumpy be functional?

#

ah

#

docs now?

#

oh

#

like that-

#

yup

#

pog

#

i use a custom client written in 20 lines

#

๐Ÿ˜‚

#

lemme finD iT OnE min

#

not 20, maybe 40

#

not dpy

#

its interacting with the api directly

#

ws*

past pawn
#

aight i gona get food

coarse cape
#

there's a bit more

past pawn
#

the cat is trying to murder my door :/

coarse cape
#

here's the message class :

#

decorators kill me

#

dont understand and dislike

#

heh

#

more like that

#

i didnt know you could use it directly in vscode tho :0

#

now i get it

#

tysm bluenix <3

#

yup

past pawn
#

decorator?
I made a really cool command decorator for dpy

#

I got toast sandwich and beer :)

#

If Lily keeps running around like this imma put sticky tape on her paws

coarse cape
#

oh

past pawn
#

at least it would be entertaining, and wont decrease the lifespan of my carpet

coarse cape
#

yeee

#

tysm bluenIx

#

<3

#

pog,

past pawn
#

my two different command decorators


def command(_flags:int):
  def wrapper(af):
    async def inner(message, *options, flags:int=0):
      if flags<_flags:
|        return await message.channel.send('ACCESS DENIED')
      else:
          return await af(message, *options)
    COMMANDS[af.__name__] = inner
    return hack_wrapper(1)(af)
  return wrapper

def _command(af):
  COMMANDS[af.__name__] = af
  return hack_wrapper(1)(af)
#

here's another decorator:

def hack_wrapper(n):
  from sys import _getframe
  frame=_getframe(n+1)
  fl = frame.f_locals
  fg = frame.f_globals
  fb = frame.f_builtins
  return lambda f:fl.get(f.__name__,fg.get(f.__name__,fb.get(f.__name__,None)))
coarse cape
#

oh now it makes sense

past pawn
#

!e here's a rewrite of above

def decorator(n):
  from sys import _getframe
  frame=_getframe(n+1)
  fl = frame.f_locals
  fg = frame.f_globals
  fb = frame.f_builtins
  def wrapper(f):
    return fl.get(
      f.__name__,
      fg.get(
        f.__name__,
        fb.get(f.__name__,None)
      )
    )
  return wrapper

n = 5

@decorator(0)
def print(a):
  try:print(a)
  except:print(a)

@decorator(0)
def n():return 2 + 2

print(n)
wise cargoBOT
#

@past pawn :white_check_mark: Your eval job has completed with return code 0.

5
coarse cape
#

this is one prob with jupyter

#

running both

#

i got in now :D

past pawn
#

Bluenix, you can change that number to select which frame you want to reference from

brave steppe
#

@compact yacht

coarse cape
#

Thanks bluenix :D

#

ill brb

past pawn
#

but stored somewhere other than the namespace

brave steppe
#

Huh ๐Ÿค”

past pawn
#

the "trick that allows parenthesis" is just another level of function nesting

#

it's a function that returns the actual wrapper

#

!e decorator-slinger```py
def hack_wrapper(n):
from sys import _getframe
frame=_getframe(n+1)
fl = frame.f_locals
fg = frame.f_globals
fb = frame.f_builtins
return lambda f:fl.get(f.name,fg.get(f.name,fb.get(f.name,None)))

d = {}
def decorator(value):
def wrapper(f):
d[value] = f
return hack_wrapper(1)(f)
return wrapper

@decorator('greet')
def print():return"Hello World!"

print(d'greet')

wise cargoBOT
#

@past pawn :white_check_mark: Your eval job has completed with return code 0.

Hello World!
brave steppe
past pawn
#

sorry that was my cat

#

she's trying to steal the cheese out my sandwich

#

@brave steppe you can talk while listening to this lyricy music? big brain!

#

I prefer Flume

#

it's sorta similar to this, less lyrics tho

stoic grail
#

So i was making a pong game using java script can anyone help me with that? i need to make a scoreboard?

past pawn
#

this is python discord

#

not javascript discord

#

so it's likely not many people here know

#

how to code in javascript

stoic grail
#

sorry but when i saw bluenix profile they are also an javascript programmer

#

yea

#

i just need a scoreboard,lol

brave steppe
#

Hi! Let's talk today about liaison between Web Storage API and JavaScript. Weโ€™ll use them in order to keep score numbers in our game permanently, in other words to save the score. I'm Anatol and you are watching the Good Parts of the FrontEnd development.

In one of the previous episodes, we've already created a simple game, however the data in ...

โ–ถ Play video
stoic grail
#

im using p5.js editor btw

stoic grail
#

okay sir

past pawn
#

@brave steppe wanna swap and try my music?

stoic grail
past pawn
#

lol

#

i recently got that out my head

#

im not putting it ba- ah too late

brave steppe
stoic grail
past pawn
#

oh thats a remix

stoic grail
#

that you so much @brave steppe

past pawn
#

๐Ÿค”

stoic grail
#

i actually made the game i just needed to add a scoreboard

#

sorry blunix

#

im actually a kid,lol i will not disturb you now ,sorry again :<

past pawn
#

I made a game of minesweeper, cautioning to do the exact opposite of everyone's advice about writing a game.
It runs from cmd, no gui, but it looks like a gui.
No curses, msvcrt, only two functions from that are used.
raw ANSI escape sequences all over the place.

The interesting thing is I am yet to find a python minesweeper as good as this one on the user side.
wasd keys to move a cursor that ignores already known squares, and usage of ascii and colours to look almost exactly like the classic Windows Minesweeper

stoic grail
stoic grail
#

omg ur the best man @brave steppe

past pawn
#

the number on the right ominously counts up every second

#

regardless of key press ;)

#

no threading

#

It's essentially spamming an infinite loop that makes a decision whether to do anything based on whatever's going on

#

i.e. "event loop"

#

msvcrt has a function that checks if a character is queued

#

kbhit()

wind raptor
#

Really cool implementation!

past pawn
#

my cat is disappointed cos i ate all my sandwich

#

the event loop is compactified cos im lazy and want to debug without any mouse wheel movement

#

The board is very soft-coded

#

that's where i switch whatever characters the board uses, what colour they are, etc..

stoic grail
#

Can you add me blunix? Wait im wasting everyones time i suck,sorry

past pawn
#

element 9 sorta doesn't follow the pattern though, and is for unknown squares

#

the "soft" code for the board.

brave steppe
past pawn
#

my usage of tuple assigning is very liberal and dynamic

stoic grail
past pawn
#

(x,y,n),clicked = self.xyn, self[i,j]
and
x,y,n,a,b,c = *self.xyn,*self.chars['board']

brave steppe
past pawn
#

my bomb generation is center-aligned

coarse cape
#

im back :3

past pawn
#

hi

coarse cape
#

cool

coarse cape
past pawn
#

!e ```py
class function:
def init(self, f):self.f=f
def call(self, *args):
return self.f(*args)

function(lambda a:print(a))("Hello World!")

wise cargoBOT
#

@past pawn :white_check_mark: Your eval job has completed with return code 0.

Hello World!
past pawn
#

It works for the wrong reason ;)

#

ok,

stoic grail
#

do you guys know hacking? hehe

past pawn
#

we all probably do, but we can't help you with it, sorry

#

not in DMs either

stoic grail
#

im not asking to help me with hacking,lol

#

i was just asking casualy

past pawn
#

I casually mention.... something related... and i get a warning ;)

coarse cape
#

my new nickname heh

#

im on the "good side of coding"

#

bruv, my nickname is bad

#

bots

stoic grail
#

gtg now bye ๐Ÿ˜ฆ @brave steppe pls friend me or me cry, thanks,hehe

coarse cape
#

@brave steppe , bots are here

#

reacting to msgs instantly

#

look at thatttt

#

@wraith cargo

#

huh

wraith cargo
#

?

#

lol

coarse cape
past pawn
#

I fed cat cheese now she's gone hyper

brave steppe
#

wut

coarse cape
#

userbots arent hard

past pawn
#

self bot illegal

coarse cape
#

but against ToS

#

m8,

frigid panther
#

!mute 883415857760464907 investigating

wise cargoBOT
#

:incoming_envelope: :ok_hand: applied mute to @wraith cargo until <t:1630761173:f> (59 minutes and 59 seconds).

past pawn
#

maaate

coarse cape
#

someone screenshot his

coarse cape
proud tangle
#

It's not the first time we've seen this

frigid panther
#

looks like a boy

#

bot*

coarse cape
#

first time im seeing this :P

coarse cape
frigid panther
#

the response time for the reactions is almost 0

solid shale
#

what was that ?

coarse cape
#

so basically

#

you have discord bots right?

green bone
vale panther
#

It was in multiple channels as well

coarse cape
#

wait will i get muted for explaining this ?

#

ok so

past pawn
#

@brave steppe my only assert statement in the whole script:

 (0 < n < x*y - 9 > x > 2 < y)or yo_mamma is fat
#

it semantically asserts

#

my main function catches this and makes it extremely cursed


def main():
    Minesweeper.terminal.save()
    try:Minesweeper(int(input('x> ')),int(input('y> ')),int(input('bombs> ')),not input("classic? ").lower().startswith('n'))
    except NameError as e:
        k = e.__str__()
        from ctypes import py_object as p
        hack = lambda:p.from_address(id(e)+8)
        hack().value = type(hack().value.__name__,(hack().value,),{'__str__':lambda s:k.removeprefix('name ').removesuffix('not defined') + 'obese'}); raise ValueError('Invalid input')
    except Exception as e:
        Minesweeper.terminal.reset()
        print(e.__class__.__qualname__+':',e,'                     ')
        input('restart? ').lower().startswith('y')and(Minesweeper.terminal.get(),main());raise e.__class__ from e;


__name__ == '__main__' == main()
coarse cape
#

user accounts have an accesstoken too

#

k

green bone
#

are you explaining what a selfbot is?

#

I don't see anything particularly wrong with that ๐Ÿคท

past pawn
#

Lily has burnt off the cheese she's calm now

#

yes

#

le event loop


    def start(self):
        self.running = True
        self.generate()
        self.update_board()
        import time
        T = time.time()//1
        while self.running:
            self.t = t = int(time.time()-T)
            char=msvcrt.getch().decode('ANSI')if msvcrt.kbhit()else'\1'
            (lambda i,j:{
char in'\t/?':lambda:self.right_click(i, j),
char in'\b\xff':self.reset,
char in' \r':lambda:self.react_select(i, j),
char in'wasdqezx':lambda:self.move(w=char in'qwe',a=char in'qaz',s=char in'zsx',d=char in'edx'),
char in'[\x1b':lambda:self.DIE(True),
char=='ร ':lambda:(c:=msvcrt.getch().decode('ANSI'))not in'KHMP'and(self.reset()or 1)or self.move(**{{'K':'a','H':'w','M':'d','P':'s'}[c]:1}),
char in'h;:':self.hint,
char in'rl':self.random_move,
char.isdigit():lambda:self.digit_move(int(char))
            }.get(1,lambda:0)()or self.update_board())(*self.here)
            if self.check_done():
                self.title("You Win!",0,'B-)',t)
                print(end=COLOURS['default'])
                @lambda E:(()for()in()).throw(E,MinesweeperBaseException('You Win!'))
                class GameWon(MinesweeperBaseException):self.running=False
#

you don't actually need any indentation when nesting brackets on a new line

#

so i throws the indent out the window

past pawn
#

also switching to decide the keyword instead of the value of such ;)

#

it looks scary, so much implicit behaviour

#

!zen

wise cargoBOT
#
The Zen of Python, by Tim Peters

Beautiful is better than ugly.
Explicit is better than implicit.
Simple is better than complex.
Complex is better than complicated.
Flat is better than nested.
Sparse is better than dense.
Readability counts.
Special cases aren't special enough to break the rules.
Although practicality beats purity.
Errors should never pass silently.
Unless explicitly silenced.
In the face of ambiguity, refuse the temptation to guess.
There should be one-- and preferably only one --obvious way to do it.
Although that way may not be obvious at first unless you're Dutch.
Now is better than never.
Although never is often better than right now.
If the implementation is hard to explain, it's a bad idea.
If the implementation is easy to explain, it may be a good idea.
Namespaces are one honking great idea -- let's do more of those!

past pawn
#

it abstracts away the mechanics so that there's just a lines of "condition of char:what to do"

#

although everything unrelated to user input is handled in the board printing subroutine

#

like the red numbers

#

they're calculated on the spot when formatting the extremely soft coded board

#
    def move(self,
w:int = 0,     a:int = 0,
s:int = 0,     d:int = 0
    ):
        o = i, j = self.here
        x,y,_= self.xyn
        w *= not not j
        a *= not not i
        I, J = d-a, s-w
        j += J
        i += I
        tolerance:int = x+y-1
        while(not(j in range(y)and i in range(x))or self[i,j]==1)and tolerance:
            tolerance -= 1
            j += J
            i += I
            if i >= x: i:int = x-1
            elif i<0 : i = int()
            if j >= y: j:int = y-1
            elif j<0 : j = int()
        if self[i,j]==1:#dam corner
            tolerance = 1
            if self==1:tolerance=0
            else:i,j = o
        if not tolerance and not self.check_done():
            for i,j in self:
                if self[i,j] != 1: break
        self.terminal.log('moved from '+str(self.here)+' to '+str((i,j)))if self.here!=(i,j)else self.terminal.log('unable to move that way')
        self.here = i,j
#

that's advanced wasd

#

it jumps known squares only if there's an unknown square on the other side

#

it's a lot harder than it sounds

#

not to mention diagonal movement, when it hits the edge, will become movement in a cardinal direction along the edge

#

like if you pushed an object diagonally against a wall, how it would move

#

since there's two game modes, the sweep mode implements this additional algorithm

    def right_click(self, *a):
        if self[a]==1:return
        x,y,n=self.xyn
        self[a] = {0:2,2:3,3:0,1:1}[self[a]]
        if self.sweep_mode:
            i,j = a
            if self.bombs[j][i]:
                self[a]=1
                self.bombs[j][i]=0
                self.xyn = x,y,n-1
                for k,l in product(range(-1,2),repeat=2):
                    for m,n in[(i+k,j+l)]:
                        if m in range(x)and n in range(y)and self.numbers[n][m]:
                            self.numbers[n][m]-=1
                            if not self.numbers[n][m]:self.select(m,n)
            else:self.DIE()

which is really cool, as it properly deletes the mine, updating the surrounding numbers

#

but if you flag a safe square, you die

coarse cape
#

cya bluenix

past pawn
#

the title bar of the board:

    def title(self, message='', bombs=0, smiley=':-)', time=0):
        x,*_ = self.xyn
        bombs = f"{chr(27)}[91;40m{bombs:0>3d}{chr(27)}[30;47m"
        smiley = f'{chr(27)}[97m|{rgb:255;255;0;1}\x1b[30m{smiley:s}\x1b[47;90m|{chr(27)}[37m'
        t = f"{chr(27)}[40;91m{str(time).zfill(3):s}{chr(27)}[30;47m"
        self.terminal.log(f'{message}\n{bombs: <{2*x+len(bombs)-5}}{smiley:s}{t: >{2*x+len(t)-5+3-max([len(str(time)),3])}s}')
brave steppe
#

๐Ÿ‘‹

coarse cape
#

byee

past pawn
#

cya

cinder vector
#

Can you help me learn python from starting

dense ibex
#

!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.

cinder vector
#

ok thank you

dense ibex
#

Yeah and Corey Schafer is his name btw

stuck furnace
cinder vector
#

i have learnt till dictionaries

#

but still have problems in loops

somber heath
#

!e py print("Start") #First line in output for each_element in "this object": print(each_element) print("Stop") #Last line in output

wise cargoBOT
somber heath
#

Everything in the indentation, which here belongs to the for loop, is run for the number of times that there are elements...letters...in the object, here a string.

#

For each run of this indentation, the each element in turn is assigned to the variable each_object

#

So the first time, each_object is "t"

#

Next iteration of the loop, each_object is "h"

#

and so on

cinder vector
#

ok

#

thanks very much

somber heath
#

Other loop topics for research: while, continue, break, else, range

past pawn
#

else?

#

that's advanced :/

#

i use continue

past pawn
#

saves from the insanity of range(len(iterable))

somber heath
#

zip

past pawn
#
for i in range(len(a)):
  print(a[i])

seeing code like this makes me cringe

#

as opposed to ```py
for e in a:print(e)

#
for i in a:
  if c(i):
    do_stuff(i)
    break
else:
  do_other_stuff(a)
#

i ned slepp

#

mebbe ie sheld slepp

#

nehhh

#

actuallly

#

yeah

#

@somber heath what you talking about?

cinder vector
#

What do you do in these sessions

past pawn
#

i did try to stream Lily's purring but it was too quiet

#

and when i fed her to get her to purr louder that just made her hyperactive

#

occasionally politics

#

and animals

#

at least it's not like some servers where people fall asleep connected to vc and they're snoring

#

this one's quite civilised

#

there's one server i'm in they do it deliberately several times a week

#

some of them would also be streaming airplane simulations

#

essentially

#

Lily gon asleep

#

i think i should follow suite

#

byeeeeeeeeee

forest zodiac
#

hi opal

#

how is it going?

#

i am also just bored

#

yes

#

its lockdown here

#

:\/

#

have you tried the minecraft morph mod?

#

oh

#

its a mod that lets you be a mob

#

what do you prefer opal functional based approach or OOP based?

#

@somber heath

#

i think everyone gets at first

#

have you worked with the ctypes module?

#

can you give an example?

#

what

#

lol

analog swan
#

lol, everyone is on mute

#

well i guess thats true

#

me:starts coding
also me: destroys left hand and know its extremely hard to type :_

#

๐Ÿ˜

somber heath
#

Ergonomics is a thing.

#

As is correct technique.

#

But then some people just have shitty hands/health issues.

#

There was a time when my arthritis was really kicking my arse. It was thoroughly unpleasant to type.

forest zodiac
somber heath
#

Or do pretty much anything.

#

Not really.

forest zodiac
#

list slicing might help

#

something like this maybe

somber heath
#

!e py import random players = ["Peter", "Paul", "Anna", "Ferdinand", "Astrid", "Bort"] random.shuffle(players) half = len(players) // 2 team_a = players[half:] #right half of list team_b = players[:half] #left half of list print(team_a) print(team_b)

wise cargoBOT
#

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

001 | ['Bort', 'Astrid', 'Paul']
002 | ['Peter', 'Ferdinand', 'Anna']
forest zodiac
#
>>> a = list(range(10))
>>> half = len(a) // 2 
>>> first , second = a[0:half] , a[half : len(a)]
>>> first
[0, 1, 2, 3, 4]
>>> second
[5, 6, 7, 8, 9]
#

wouldnt this work @somber heath

#

opals way is more cleaner than mine

#

i dont think you should rush ๐Ÿ™‚

#

i think concept of OOP is necessary for dpy

#

personally i have also never tried dpy

#

but i have used djs

whole bear
#

hi'

primal yacht
# forest zodiac ```py >>> a = list(range(10)) >>> half = len(a) // 2 >>> first , second = a[0:h...

About your slicing with explicit values

>>> SIZE = 10 # for dummy length
>>> class A:
...   def __getitem__(self, x, /): return x
... 
>>> A = A() # due to making it easier
>>> A[ : 5], A[0 : 5]
(slice(None, 5, None), slice(0, 5, None))
>>> A[5 : ], A[5 : SIZE]
(slice(5, None, None), slice(5, 10, None))
>>> A[ : : -1], A[SIZE-1 : : -1] # -1 is something else as start and stop, so cannot use ... and 0 as stop will crop off index 0
(slice(None, None, -1), slice(9, None, -1))
whole bear
#

hlo @primal yacht

primal yacht
#

Your messages are not in English

#

I cannot understand non-English

#

Translations are not 100% accurate.

#

I'm okay

primal shadow
#

!rule 4 please

wise cargoBOT
#

4. Use English to the best of your ability. Be polite if someone speaks English imperfectly.

primal shadow
#

that's bing translate, yes. Currently set to spanish though.

primal yacht
primal shadow
#

it might be a local thing

#

!rule 4 please

wise cargoBOT
#

4. Use English to the best of your ability. Be polite if someone speaks English imperfectly.

primal shadow
#

These are the rules, unfortunately it is on you to translate to English, not us

primal yacht
primal yacht
#

^w^

primal yacht
gloomy vigil
#

@forest zodiac hi

forest zodiac
#

@spring relic

spring relic
#

hm

#

whats problem

#

๐Ÿ‘€

gloomy vigil
spring relic
#

which distro ?

#

oh oh

#

@gloomy vigilsearch in search menu there should be driver something

#

open that

spring relic
#

and

spring relic
spring relic
#

"hardware and driver"

blazing belfry
#

goodnight guys โค๏ธ

spring relic
#

๐Ÿฅบ

gloomy vigil
spring relic
#

oh no

gloomy vigil
spring relic
#

wait

#

there is nothing such software in your ubuntu

gloomy vigil
spring relic
#

waiit let me search google how to install it

#

manually

gloomy vigil
spring relic
#

hahha

#

@gloomy vigil

#

h

#

hi

#

see this

#

my bad .. i told you wrong name

#

search this additional software

gloomy vigil
#

yea i got

spring relic
#

can you

#

screen share

gloomy vigil
spring relic
#

ohoh

#

okay let it search

#

driver

gloomy vigil
spring relic
#

i haven't use ubuntu since many months & forgot everything

#

๐Ÿ˜†

spring relic
gloomy vigil
spring relic
#

wait

#

GPU isn't attached

#

i think

gloomy vigil
spring relic
#

graphics

#

card

#

๐Ÿ‘€

gloomy vigil
#

i mean i attached it

spring relic
#

@forest zodiachey explain

#

me

#

issue

#

ke ho

spring relic
spring relic
#

@forest zodiacexplain me

#

his/her problem

#

and issue he/she facing

gloomy vigil
wise cargoBOT
#

Voice verification

Canโ€™t talk in voice chat? Check out #voice-verification to get access. The criteria for verifying are specified there.

spring relic
#

ohh

#

i think

#

Graphics card wasn't connected properly

#

๐Ÿ‘€

#

ask for help with elder

#

๐Ÿ‘€

#

hahaah

#

exactly

#

@forest zodiac i cannot speak

#

fluently

#

english

forest zodiac
#

@gloomy vigil

#

eh?

spring relic
#

@gloomy vigili was unable to help

#

you

gloomy vigil
#

no worries dude

spring relic
#

good night beautiful soup ๐Ÿ˜†

gloomy vigil
#

i will watch a indian guy tutorial on youtube and he will prob have solution

gloomy vigil
gloomy vigil
#

the Beautiful soup module and requests

spring relic
#

hehe

#

yeah

#

as i guessed......

gloomy vigil
#

cool

#

goodnight

spring relic
terse needle
#

@indigo lion here

somber heath
#

Kivy

#

Corey Schafer

#

Playlists for Python

somber heath
#

!e py class MyClass: pass my_class_instance = MyClass() print(my_class_instance)

wise cargoBOT
#

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

<__main__.MyClass object at 0x7f476c2cdfd0>
somber heath
#

Nuances. Nuisances.

#

Same diff.

wind raptor
wise cargoBOT
forest zodiac
#

!e

wise cargoBOT
#
Command Help

!eval [code]
Can also use: e

*Run Python code and get the results.

This command supports multiple lines of code, including code wrapped inside a formatted code
block. Code can be re-evaluated by editing the original message within 10 seconds and
clicking the reaction that subsequently appears.

We've done our best to make this sandboxed, but do let us know if you manage to find an
issue with it!*

forest zodiac
#

!e

print(f"hello {*range(10)}")
wise cargoBOT
#

@forest zodiac :x: Your eval job has completed with return code 1.

001 |   File "<string>", line 1
002 |     (*range(10))
003 |      ^
004 | SyntaxError: f-string: can't use starred expression here
forest zodiac
#

print(f"012345678)}")

#

!e

print(f"hello {}").format(*range(10))
wise cargoBOT
#

@forest zodiac :x: Your eval job has completed with return code 1.

001 |   File "<string>", line 1
002 |     print(f"hello {}").format(*range(10))
003 |                      ^
004 | SyntaxError: f-string: empty expression not allowed
forest zodiac
#

!e

print("hello {}").format(*range(10))
wise cargoBOT
#

@forest zodiac :x: Your eval job has completed with return code 1.

001 | hello {}
002 | Traceback (most recent call last):
003 |   File "<string>", line 1, in <module>
004 | AttributeError: 'NoneType' object has no attribute 'format'
forest zodiac
#

!e

string = "hello {}".format(*range(10))
print(string)
wise cargoBOT
#

@forest zodiac :white_check_mark: Your eval job has completed with return code 0.

hello 0
forest zodiac
#

!e```py
string = "hello {} {} {} {} {} {} {} {}".format(*range(10))
print(string)

#

!e

string = "hello {} {} {} {} {} {} {} {}".format(*range(10))
print(string)
wise cargoBOT
#

@forest zodiac :white_check_mark: Your eval job has completed with return code 0.

hello 0 1 2 3 4 5 6 7
forest zodiac
#

!e

string = "hello {}".format("{}" * 10).format(*range(10))
print(string)
wise cargoBOT
#

@forest zodiac :white_check_mark: Your eval job has completed with return code 0.

hello 0123456789
wind raptor
past pawn
#

@somber heath more curlew

#

And it's still in exactly the same pose right now

wind raptor
forest zodiac
#

hey @somber heath

#

will be here after like a hour?

somber heath
#

Much is possible.

forest zodiac
#

if it is okay

somber heath
#

As you would have it.

stoic grail
#

@somber heath My mic is not working dude ๐Ÿ˜ฆ

#

its physically wrong

#

are you a real coder?

#

lol

#

yesterday a guy got my all private info :<

#

im not kiddin

#

he said hes a software engineer

#

then i got a VPN

#

he was nice though

#

nono

#

i was in a server and then i was just writing something and he randomly said my real name there and then i was scared so i chat him privatley

#

just my real name

#

i dont have a phone no.

#

yea

whole bear
#

hi

stoic grail
#

he was sayin he knows my IP but wont tell me cause i will be too scared then

#

then i got a vpn

forest zodiac
#

you cant speak here

whole bear
#

@somber heath so yea i am self taught dev tryna secure an internship. and i am finding quite difficult do you have any advice i have my website portfilio in my bio

#

hi

stoic grail
forest zodiac
#

unless you are voice verified

whole bear
#

np

stoic grail
#

yea i thought about this after that conversation

#

i was trying to be cool

#

btw yesterday i also made my first game using java script :>

#

ik dude i started 2 days ago

#

it took me hours to learn stuffs

#

hehe im just wasting your time

#

hehe

#

rickroll never dies

#

ok sorry sir

#

lol yea

#

yea?

#

yea

#

also hecker is a character in a youtube channel :>

#

which engine do you use for python?

#

like visual code studio,etc

#

oh

#

i have pycharm but i dont know python i just have pycharm,hehe

pure scroll
#

hi

stoic grail
#

visual studio code is complicated for me i also have it downloaded

forest zodiac
#

vscode is more simpler than pycharm

#

what was i thinking lol i wrote python lol

stoic grail
#

i need to learn C before coding,lol

#

yea ik

pure scroll
#
Voice Gate failed
โ€ข You have sent less than 50 messages.
โ€ข You have been active for fewer than 3 ten-minute blocks.

๐Ÿ˜ฆ

#

i will have to send msgs ๐Ÿ˜›

stoic grail
#

i just wrote like 50 messages

whole bear
#

what notebook u guys use??

pure scroll
#

now do the voice verify

stoic grail
#

im not bored

pure scroll
#

yesterday i downloaded anaconda

#

i still don't know how it works xD

stoic grail
whole bear
#

yeah i use jupyter

stoic grail
whole bear
#

i do classes and i started in nested for loops and stuff

stoic grail
#

oh

whole bear
#

shit my mom came i gtg

#

peace

stoic grail
#

peace

pure scroll
#

there is a course on edx about machine learning from MIT that points in the first lesson to download anaconda

#

that's why

#

it seems to be pretty hard to study

#

many people left

stoic grail
#

hi happy sloth

pure scroll
#

hi

#

welcome to guys muted

stoic grail
#

opalmist no offence you sound like 40,hehe jk

pure scroll
#

how old are you all?

stoic grail
#

13

#

lol

#

hi @whole bear

whole bear
#

hlo

#

all

#

hlo opal

stoic grail
#

hllooo

whole bear
#

good morning ,

pure scroll
#

wow happy sloth can talk!

stoic grail
#

thier voice is verified

#

can we listen to songs?

#

ok sowy

#

how did yall find discord?

#

my friends told me bout it

#

you are a minecraft dev?

#

your what>?

#

oh

#

lol

#

its 31 degree in india i suppose

#

so which language are you learning or masters in? @whole bear

#

do you know python?

#

ohhh

#

i started coding 2 days ago and im learning java script i made like 2 games till now

#

oh

#

i was stuck with the variables

#

java script is just for beginners i suppose

#

these photos have my name in it :<

#

lol

#

i did

#

its actually my email id

#

hello titan

#

im workin on making a scoreboard in my game

#

whats sublime?

#

im also from india @compact bay hehe

#

ohh

#

im afk

#

im bak

#

wot is linus

#

linux

#

afk again,lol

whole bear
#

rwxrob

compact bay
#

What's your goto response in meetings?

๐Ÿ“š Video courses from JomaClass:
๐ŸŽ“ New to programming? Learn Python here: https://joma.tech/35gCJTd
๐ŸŽ“ Learn SQL for data science and data analytics: https://joma.tech/3nteQih
๐ŸŽ“ Data Structures and Algorithms: https://joma.tech/2W89H33

๐Ÿ’ต Start Investing and get 2 FREE Stocks valued up to $1850 (when you dep...

โ–ถ Play video
stoic grail
#

do you guys play any games?

#

hax

#

lol yea

stoic grail
#

hello sir @somber heath

#

are you talking to me sir?

#

i though ur in a call

#

im actually having a problem

#

Can you help me with the problem sir?

#

hi guys

#

can somone help meh?

#

:<

cobalt magnet
#

if its python, maybe

stoic grail
#

its java script

cobalt magnet
#

idk javascript lol

stoic grail
cobalt magnet
#

idk lol

stoic grail
#

lol

#

blunix would know dis

cobalt magnet
#

hmm

#

then ask him ig

stoic grail
#

thay are offline

#

they*

#

i guess now we two are only left

cobalt magnet
#

yes

stoic grail
#

bored?

cobalt magnet
#

no, coding

stoic grail
#

oh i see

#

im disturbing you then,sorry

cobalt magnet
#

nah its fine

stoic grail
#

hi big syva

#

opalmist is back : )

cobalt magnet
#

its fine

whole bear
#

HI bros

stoic grail
cobalt magnet
#

hello

stoic grail
#

opalmist i have a problem can you help?

whole bear
#

Lol

#

Whats the problem brfo

stoic grail
#

sending a screenshot in a min

#

lol

cobalt magnet
#

are you really cropping the screenshot right now

#

lol

#

take a snip

whole bear
#

Guys should i troll some roblox kids ๐Ÿคฃ

stoic grail
#

so i added a code for a scoreboard in my game and i know im so dumb, hehe

cobalt magnet
#

so you were cropping the screenshot

somber heath
#

!code

wise cargoBOT
#

Here's how to format Python code on Discord:

```py
print('Hello world!')
```

These are backticks, not quotes. Check this out if you can't find the backtick key.

stoic grail
cobalt magnet
#

no need just take a snip lolololol

#

it copies it to your clipboard

#

do win + shift + s

#

and select the region

#

youwant to show

#

and then go to discord and paste it there

#

like this

#

thats done in seconds compared to taking a screenshot

#

taking like 40 seconds to crop

stoic grail
#

when i removed that code the game is working fine

cobalt magnet
#

lol

whole bear
#

What tf is that

stoic grail
#

fill ('#FF0004');
textSize(25);
text("Score :" + Score , 10, 25);

stoic grail
whole bear
#

Ah i dont use that

cobalt magnet
#

try js as vanity url

#

see?

#

i didnt even know this was a server llol

whole bear
#

Amogus

cobalt magnet
#

WAIT

#

WHERE

whole bear
#

Noonnononoo

#

Your suspect

#

: )

cobalt magnet
#

whar

stoic grail
#

weeeeeeeeeeeeeeeeeeeeeeeeeeeeee

whole bear
#

sussy

cobalt magnet
#

that is very offending to me

#

i am not the impostor

#

neither am i sus

whole bear