#ot2-the-original-pubsta
652 messages · Page 30 of 1
you don't need the more complicated features or the linear algebra, opencv just uses it as a convenient way of manipulating multidimensional arrays
ok
it really isn't horrible, but I can understand if you start out confused
did you learn about regular lists?
just the [1, 3, 4, 5]
yeah
did you ever try to put a list into another list like [[1]]
ye
then you should be fine
numpy is just a more powerful version of that
and by powerful I mean easy
so i should only do specific stuff in numpy?
you can do whatever you want more or less
I don't really know what you mean by specific
there are some confusing things in numpy, like the 3 arg form of np.where
use opencv and google what you want to do or ask in a help channel about it. That's more or less how I went about it
!pypi google
!pypi numpy
and if you find it boring, just stop and try something else. What was fun for me doesn't have to be fun for you
!pypi opencv-python
Is there a way to get rounded corners on openbox?
Google says maybe?
🤔 What is that
Can’t relate I have an iPhone
no clue sorry
lmao
I am signed into my account, that's the problem
I don't, I just dont know how to fix that error
@full marlin @bright leaf it really liked a password change
like, really really
really really really
👀
Can anyone pleaseee help me with a few things if so dm me
@wicked hollow will you be here in like 10 hours and could help me with git
Probably not, that's the middle of the work day for me
Ah okay
But I'm sure there will be someone around who can
Sheesh go to sleep
2 AM here, heh
Cute.
There actually are timezones that are 15 minutes off from an hour
None around GMT - 5, though
So its actually 2 am for you or you rounded slightly?
Rounded.
Oh okay
It's currently 11:30 AM in Nepal, though
11:15 am for me 🥴
alr
Ty
Shit.
@wicked hollow at this point it's 8 hours.
Lmao
lol
I need to sleep
Also
On Wednesday I'm wiping my raspberry pi 3
And replacing the SD card
Because ffs it's starting to have so serious issues
It mounted in read only yesterday it seems
damn
"grow your projects" can i advertise my bot? 
why don't you format it?
that should clean the corruption
Can any1 answer this....can we advertise our bot ?
no, i dont think so
but i think you can share the features as a project in off topic
but advertise link the source code btw
Showcasing opensource projects is fine.


vivekji
Vivekji indeed
ima call you vivekji 🙏 because
respect staff members and their..
💯
lol hahaha you even changed your name to vivekji
:Salute:
sure
😉
akarys baiyya we believe you
Its very difficult to press on "show message" over and over again 🥴
Yo is there a name for the language/pseudo language that command line interfaces use? Specifically looking for windows command line
I'm tempted to call the windows cmd language "Batch" because the files are called "batch files"
I'm really just looking for a good book on becoming a cmd superuser
#Create a function to combine the values of the important columns into a single string
def get_important_features(data):
important_features = []
for i in range(0, data.shape[0]):
important_features.append(data['Actors'][i]+' '+data['Director'][i]+' '+data['Genre'][i]+' '+data['Title'][i])
return important_features #Create a column to hold the combined strings
df['important_features'] = get_important_features(df)
#Show the data
df.head(3)
This is my code although i am getting below error: Traceback (most recent call last)
<ipython-input-10-50d23e3e0015> in <module>()
1 #Create a column to hold the combined strings
----> 2 df['important_features'] = get_important_features(df)
3
4 #Show the data
5 df.head(3)
3 frames
/usr/local/lib/python3.7/dist-packages/pandas/core/internals/construction.py in sanitize_index(data, index)
746 if len(data) != len(index):
747 raise ValueError(
--> 748 "Length of values "
749 f"({len(data)}) "
750 "does not match length of index "
ValueError: Length of values (1) does not match length of index (1000)
Please help
@fair creek try #data-science-and-ml
okay thanks
hi~~
.topic
Suggest more topics here!
ooof
ask: @joe you remind me of someone?
non
well, dont then
Guys, i got a finalized syntax for my language https://paste.pythondiscord.com/ekaxopunuh.txt
@languid osprey how is the language going?
Eh, im formulating the syntax atm
Im planning to start coding it next month
I need to finalize the features
ok
I'm planning to make it in rust for speed
i wanna make a language that is very generous and accepts both colons and indentations, or semicolons and braces,
php
Lol
PHP allows that? I haven't ever used it
I want my language to have optional type declaration
oh
well, IDK if its actually indentation
if ($pred):
$obj->method();
endif;
Hm
this is at least approximately correct syntax
Cool
also nim
and i wanna make it either static with type inference like rust, or dynamic
maybe static with type inference
I'm planning on dynamic
if cond: (
obj.hello,
atr.bye,
)
Ooh
you can also just do the python thing
So like how python handles types?
\o
I'm planning on something like ```
x = 10
// or
x: Int = 10
-- public
func my_func(num: Int) -> Int:
return num
Hello lak~~
gradual typing?
or just type hints
done deleting
or full on dynamic typing, but types are used for dispatch like in julia
or full static typing with inference, like haskell
Hm, well its mostly type hints, but if you declare the type like this py x: Int = 10 You cant do x = "Thing" Because you already declared it as an int, while on the other hand, if you do x = 10 You can do ```
x = "Thing"
No, i don't want full on static typing, all type declaration is optional
I want the syntax to be simple
With a lot of optional things that may be useful in some cases
if I have a program that looks like this
x: Int = 5
sleep(10)
x = 'a'
``` does it error before or after the sleep is done
It never errors
Hm, Its interpreted, so at the third line when you try to change it to a string
I have a lot to figure out lol
I see, so the julia approach
I've never used julia, but yeah ig
You could make a class that enforces typing
good option, julia is quite smart
Cool
we aren't talking about python
Lol, I'm planning out my own language that I'm planning to make
I also want match statements similar to rust, ```
match somethign:
case 1:
// Do code
case "two":
// do code
int
Hm?
raku would be an example where it errors before the sleep,
my $x = 4;
sleep(10);
$x = 100;
```^ fine
```perl
my Int $x = 4;
sleep(10)
$x = "100";
``` ^error before running
```perl
my Int(Any) $x = 4;
sleep(10)
$x = "100";
```^fine
```perl
my Int(Any) $x = 4;
sleep(10)
$x = "hello";
```^error after the sleep
this is called gradual typing
Ive never used raku
Ohh ok
Oh
butterflies are pretty cool
Im planning on adding something like this as well ```
x = "STRING"
@x
func randcase(self):
random_chars = ""
for char in self.characters:
match random.randchoice(1, 2):
1:
new_chars += char.to_upper()
2:
new_chars += char.to_lower()
return random_chars
So you can add your own functions into different variables
So a custom string method
Lol
I want to add something called function signing as well, where you can sign functions with different attributes, like below ```
// Makes public
-- public
func myfunc():
// do code
// Makes it a testing function
-- test
func testingfunc():
// do code
And its also used inside objects
obj Test:
--initialize // Functions signed by this are executed when the object is initialized, can have multiple of these
func myfunc(self):
...
Why is this ot name a thing
👀
Christians : You Heretics-
poor jesus
leave him be, the whole cross thing was enough 😠
hm
I wonder
oh that was a horrible idea
actually
that got blocked by my filters so uh
@storm birch pls delete it
what... is that
attachment link uwuifed
lol
ok, sure lol.
this is so sad
JESUS USES DISCORD
BOTTOM TEXT
lol
!unmute jesus
you don't have da power sadge
hmmm who is jesus? is he a fictional character? from a fictional book? oooooh
Man the open() syntax is screwing with my head
what about it?
Maybe I'm just misreading but It's used to create files and read/write from them?
Why would I have to open a file that's not created yet?
It can be used to create and open a file if it doesn't exist
But you can just open a file that already exists
Is that the only way to create files that don't exist?
Not at all, one other way that comes to mind would be executing some commands in the command line via a python program
There would be plenty of other ways
I think I'm just having trouble with open() not immediately returning an error if there isn't an existing file to open.
Not logically but
it can, it depends on what mode you use
Morally
It will only create the file if it doesn't find it if you specify it to do so
well actually, trying to remember which modes did and didn't
I know for sure reading will throw an error if it's not found
and most of the time when you're working with a file you'll be reading then writing some value to it, so the reading first will throw the error if the file doesn't exist
write I can't remember if only w+ creates the file or if both w+ and w do
Wait w+?
Huh okay thanks you learn something new every day
both creates the file, iirc
r and r+ errors out
@somber belfry can you give context on this channel name
This is as much as I could produce.
poor vivek
can I dm you something
hmmmmmmmm, sure
float AngleToPoint(Vector2 point)
{
float angle;
if (point.x == transform.position.x)
angle = point.y > transform.position.y ? 90 : 270;
else
angle = Mathf.Atan((point.y - transform.position.y) / (point.x - transform.position.x)) * 180.0f / Mathf.PI;
if (point.x - transform.position.x < 0)
angle += 180;
return angle;
}
Vector2 AngleToDir(float angle)
{
if (angle == 90)
return new Vector2(0, 1);
else if (angle == 270)
return new Vector2(0, -1);
Vector2 angleDir = new Vector2(1, Mathf.Tan(angle / 180.0f * Mathf.PI));
if (angle > 270 || angle < 90)
angleDir.x *= -1;
return angleDir;
}
so i have this, and i know for a fact that one or both of these functions don't work. any ideas?
nvm, got it working
nice
ncie
this is probably the longest ot name I've ever come across #ot2-the-original-pubsta
Disappointed there's no enterprise in there tbh
its not windows >:(
intellij-idea-charm-ultimate-professional-education-enterprise-premium-household-edition
I request the mods to pin this
beauty
!otn 
adds every single Intellij product
@Moderator
Really hope this becomes an ot
same
https://github.com/python-discord/meta/discussions/85 @worn sluice ask here to add to ot
Did before I even replied here
o ic
epic
I upvoted it
yaay
C'mon, someone add my vanity otname
!otn its-all-spaghettified
!otn it-s-just-more-spaghetti
first time using IntelliJ, what does this do?
like, what does it actually add compared to normal Java project, or compared with a Kotlin project?
My personal suggestion is use gradle for everything
I think it just adds kotlin as a dependency be default
are you gonna be using kotlin?
hmm, that's probably a good idea
are you trying to mod MC or learn kotlin?
yeah
lol
you can make plugins for mc with kotlin tho
with like spigot or something like that
you can make mods as well with kotlin
Yes 😛
then the project setup is very different
Pol
Yeah
*lol
plugins aren't interesting for me, they are pretty much incompatible with forge modding after all
(even SpongeForge breaks some things)
for fabric just use https://github.com/natanfudge/fabric-example-mod-kotlin
for forge there is an article somewhere
oh i just realized this name changed early than normal
its nice
fabric is also a lot quicker and stable
👀
fabric has its issues
so is there a command to force a change or
forge has its issues as well they all have issues
such as lack of common APIs (is there a consensus on fluid units yet)
Yeah
ehh, maybe I'll look at Fabric in another year
new forge is pretty fancy tbh
I've played a Fabric pack lately and it's still pretty lacking. Though performance was nice, but that's probably related to having few mods.
yeah, I am just waiting with making more mods until either modloader gets a useful majority
also I just don't have the motivation to finish the things I started
relatable
wow, the minecraftforge site is taking literally minutes to load plaintext pages for me
ehh, relatively, yeah
ok then you should prob be fine
it was the first language I learned, though I don't code in it as much as in... anything else
what I appreciate about java is that despite not writing any meaningful java code for like 3 years, I still remember all of it
ah yes, Java PTSD
Lmfao
Kotlin is too complicated and full of unobvious symbols
the separation between constructor and class needs to a lot clearer than ){
well I am learning rust right now and I have never worked with a type language other than kotlin but I never really knew kotlin that well
the rust type system is very unique
Id never heard the name factorio before this week and now im seeing it everywhere 🥴
I really want to use rust, but every single project taking dozens of minutes to setup due to cargo not caching builds is just bad design
doesn't cargo cache builds?
Car no go cache builds, car go vroom
you don't cleanbuild all the time, but if you add a dependency, you best be ready to take a walk, since your CPU is gonna be at 100% for the forseeable future
ah yes, the sweet smell of Java development
BUILD FAILED in 38s
Lol
also the lack of polymorphism over some things, everything exists in normal, mut, pinned, rc, arc, .. variants
oh god no, it's failing due to not being able to download forge
which is fair, because the site really is lagging
> Could not resolve dependency: net.minecraftforge:forge:1.12.2-14.23.5.2855:userdev3
wait what
why did I get a different error the second time
why are you using 1.12?
I'm most familiar with it (1.16 is IMO not very developed yet) and that's where there are some modpacks I can contribute to
honestly, it is much harder, since forge no longer supports that version (at all pretty much), and recently it was changed to use a different project setup entirely
so a lot of things are outdated
actually, nevermind, I was doing the wrong thing
well, the right way still has a problem of the site hovering on the edge of being down, but at least it's right
😩
Step 2: Set up your Text Editor
Before we begin Minecraft modding, we’ll need to download some tools.
First, for this guide, we are going to download the Eclipse IDE, one of the most popular professional text editors for Java in the world.
encountered this in the wild
Thats actually really good :D
eclipse 😔 we have to use it for school
I'm more referring to it being called a "popular professional text editor for Java"
light theme 🥴
Watching this in a dark room be like
https://c.tenor.com/nlCEZuWvUBEAAAAM/darrion-darrion-nguyen.gif
I've been at work for over 10 hours. Because I was tok lazy to go and decided to hang out with a person who needed to do some work in our lab. And so we broke a server.
I don't really get why people complain about tabs vs spaces considering that if one really cares, they can configure their linter to convert one to the other
We were only applying thermal paste. But somehow one processor doesn't see third of its connected RAM
oh god, I finally got gradle to work. I needed to delete my entire .gradle folder (not just the relevant cache) before it stopped failing trying to open some corrupted zip file
293GB total when normally working. It's one of our lab machines
I have no idea what is inside this. I only run stuff on Vcenter on that machine. Or even not. Idk which machine is that. I'm just here for fun XD
Oh xd
Okay, seems like only one is broken and just breaks the other 2 in its group
278GB remaining.
Trying once more in yet another slot but we don't have any hope for it
Hmmmm
@short cliff was the channel name manually changed?
Or is there a command to force a name change
a load of butterflies came and flipped the bits
Lol
i mean, it was obviously changed from jesus was muted
i'm just curious how
was this already on the list so an admin chose one at random and just changed it, or was it changed with a bot command, or, was it changed from an int e (as joe says, internal eval)
!src butterflies
Unable to convert 'butterflies' to valid command, tag, or Cog.
Unable to convert 'M-x' to valid command, tag, or Cog.
not a valid command, tag, or Cog
so you automated discord to change the name, tos violation 
mhm
no the butterflies
flew by the discord datacenter
and flipped the bits
duh
did you report the security hole?
because flipping bits is a huge issue
time travel would like to have a word with you
but yeah there was a huge butterfly infestation in a GCP data center and all the bits were flipped
hm, i wonder what would happen if every bit was actually flipped
yeah
well I guess there is a non-zero chance that bits could be flipped into a valid filesystem
kinda relates to how computers in space work
run multiple independent systems, compare results, select majority answer
dang
@grim seal Parity bit?
being 7 bits, if everyone of them were flipped, the parity bit would still work there
parity bit would check for integrity, not as a method of restoration
like the data is still gone
it's just you now know it's gone because of corruption
RAID plays into that though and allows for restoration
hm...wasn't there some story of Jeff Dean dealing with a similar problem?
i mean
by building on top of parity bits
lol
because in this situation, we know every bit was flipped
Like I think when Google was going big, there were weird bugs that seemed not to originate from code and dean found out some cosmic rays from space were responsible for fliiping some bits
😝
lol that sounds about right
apparently, NASA protects the system with a layer in their serves casing
Hi :D
Google didn't; hence the problem
yeah, NASA builds their spacecraft to have one super strong radiation proof computer. the spacex approach is to have 3 less-proofed computers running the same calculation and then listening to the two that reach a consensus in the event that one of them produces an incorrect result.
that doesn't seem a very good plan
Id rather have one super strong radiation proof than 3 computers with nothing
but what if the thing that merges the two that agree ends up being affected
probably the merge might be done by all 3
sure, but three computers having the exact same radiation corruption and then producing the same incorrect result is so slight that it's not worth considering
!ot
Off-topic channels
There are three off-topic channels:
• #ot0-fear-of-python
• #ot1-this-regex-is-impossible
• #ot2-the-original-pubsta
Their names change randomly every 24 hours, but you can always find them under the OFF-TOPIC/GENERAL category in the channel list.
Please read our off-topic etiquette before participating in conversations.
THE TWO REAL LEMONS
LMAO
no i totally wasn't stalking when it changed ty
yeah, comparison and ring leading is prob done by all three
spacex also use linux 🙂
Kids, always remember to #ot1-this-regex-is-impossible
which Elon Hates
really was not stalking the name change
It was one of the reasons he was kicked from PayPal. He wanted to use Microsoft than Linux. But much of Paypal infra was for Open Source so they got into the argument
Question. Who are the real lemons? Lemon and ____?
SpaceX uses an Actor-Judge system to provide triple redundancy to its rockets and spacecraft. The Falcon 9 has 3 dual core x86 processors running an instance of linux on each core. The flight software is written in C/C++ and runs in the x86 environment. For each calculation/decision, the "flight string" compares the results from both cores. If there is a inconsistency, the string is bad and doesn't send any commands. If both cores return the same response, the string sends the command to the various microcontrollers on the rocket that control things like the engines and grid fins.
The microcontrollers, running on PowerPC processors, received three commands from the three flight strings. They act as a judge to choose the correct course of actions. If all three strings are in agreement the microcontroller executes the command, but if 1 of the 3 is bad, it will go with the strings that have previously been correct. The Falcon 9 can successfully complete its mission with a single flight string.
The triple redundancy gives the system radiation tolerance without the need for expensive rad hardened components. SpaceX tests all flight software on what can be called a table rocket. They lay out all the computers and flight controllers on the Falcon 9 on a table and connect them like they would be on the actual rocket. They then run a complete simulated flight on the components, monitoring performance and potential failures.
SpaceX engineers perform what they call "Cutting the strings" where they randomly shut off a flight computer mid simulation, to see how it responds.
I microwave my milk
@mods spam
👀 giving discord money smh
Lol
does someone here work with react
if so im confused, how does react link different routes without refreshing the page?
like it will move to another route such as /about or /contact without reloading the page. and usually that only works if there is an href="#contact" on the page
do lancebot command suggestions that get rejected get closed or ignored?
Closed I think.
Yeah, closed.
A chance of what?
What number is it?
They probably just didn't see it.
yay, finally
strictly speaking, the fact that I didn't get an authorization screen here means that anyone who's capable of downloading and installing Forge's MDK can play minecraft 😅
but they probably deserve it for that
at the bottom is actually a perfectly normal log of a modded minecraft installation
you see this every time you launch modded minecraft if you're using a launcher that can show it
Interesting.
lol
why is mods I specified as dependencies not loaded at runtime?..
most likely I'm missing something and compile <...> is treated as a compiletime-only dep
[06:22:16] [Client thread/DEBUG] [FML]: Examining file buildcraft-6.0.8-dev.jar for potential mods

and then it doesn't find it
aaaaah
it's called runtime, of course it is
just remember, some people use storage devices that are failing without making a backup
I have never seen confused reptile be confused
normally he has the answer to all my ds/algos problems
something is happening, maybe it'll even work this time
aaaaaaaaaa
Could not resolve all files for configuration ':compileClasspath'.
> Could not find mezz.jei:jei_1.12.2:4.16.1.301_mapped_snapshot_20171003-1.12.
Searched in the following locations:
oh wow
a new error
Caused by: java.lang.IllegalAccessError: tried to access method net.minecraft.client.renderer.texture.TextureMap.initMissingImage()V from class mezz.jei.gui.textures.JeiTextureMap
huh
actually, that's still progress
because it means the mod got included at runtime, yes!
function isn't public, duh
;-; use fabric...
thanks, I prefer to actually have mods to play with 😛
oh
it looks like this is an actual issue with JEI and forgegradle
The issue has been previously mentioned in #2009. However, @mezz closed the issue as solved, but the issue still persists (it was probably reintroduced with 4.16.1).
don't you love issues that pop up after being fixed
Okay so apparently the only solution to this problem is downgrading to ForgeGradle 2.3, since FG3 doesn't have good support for ATs. I am closing this issue to mark it as solved (and to avoid cluttering the feed).
😔
wtf
I'm using ForgeGradle 2.3 now, definitely, but now the same methods don't work
// compile against the JEI API but do not include it at runtime
deobf "mezz.jei:jei_${mc_version}:${jei_version}:api"
// at runtime, use the full JEI jar
runtime "mezz.jei:jei_${mc_version}:${jei_version}"
neither deobf nor runtime are recognized, and this is a sample from JEI's wiki, for FG2.3
oooh, got it, wrong place
YYYESSS
it only took a few hours and a different Forge version
nice
What's the difference between deobfProvided and deobfCompile? More importantly, how am I supposed to find out?.. 
COFH know where it's at, lmao
same
What projects have you guys done?
lol
lol
do you ever not understand a thing and than come back 2 years later like oh yeah no this totally makes sense i was a dumbass
maybe
might as well pull the allnighter
In the meantime,
@Chrisjl#2655will be taking care of a Super Secret Project™️
still waiting to know what the project is...
sad
https://github.com/AnkithAbhayan/python-chat-bot much more than me lol
i was thinking of making something like that but never had the time to do it 
o this was a 2 ppl project 🥴
dam you doing ml?
that looks like ML ngl
lol
👀
i thought the porject was using some lib or api but its a neural network from scratch from the looks of it
you can roll a dice
i thought it was ML too lol
you can flip a coin
ye some linear regression
damn what is this
def isPrime():
number = int(tell("enter number to find out whether it is a prime number or not:"))
item_list = []
factor_list = []
for i in range(number + 1):
if i == 0:
pass
else:
item_list.append(i)
length = len(item_list) + 1
for i in range(len(item_list)):
length -= 1
for a in range(len(item_list)):
if item_list[a] * length == number:
factor_list.append(item_list[a])
else:
pass
say("the factors of "+str(number)+" are: "+str(factor_list))
if len(factor_list) == 2:
say(True)
else:
say(False)
``` ouch...
lmfao
you know...
I wrote that code when my mind was in an elevated state. now I cant understand it
import sympy
sympy.isprime(11)
and even if you make your own, why is it sooo long 👀
thats cheating
you are the one who commited, you shud know yourself lol 
oh that was other person's code I didnt even review it
@sand drum
copypasted from here https://github.com/AnkithAbhayan/math-functions
all functions in this repo is in that chat bot
??
num = int(input('What number would you like to test: '))
rep=2
while reps <= num:
if num%reps == 0:
return False
else:
reps+=1
return True
``` inefficient but shorter than yours...
read the above convo
ooh
so what
anyway, I agree that my code is shit 🤣 thats why I wrote it
what do you want
if you dont understand, then leave it
i mean what can i do
i dont want to read
take credit
your code 
bruh, you find all the factors before you report it's prime or not. That's even more inefficient than mine (which i considered to be the most inefficient solution ever)
nice
why is such a simple concept coded in such a high amount of lines no offense
yeah i know, my code is 🥴
thats my code
idk, anything about ml so
i can teach you
i cant say anything cause i suck but sorr if i came off as harsh
im not here to be a dick
not mine lol
oh sorr
then be a puss*
lol Ik my code is shit 🤣 I wrote it many months ago
amy schumer is laughing right now
i just need some good sources, the coursera one is too boring 
hey man its okay im learning too
ye
datacamp
rewrite when 
hmmk havent checked that out thanks
lmfao I'm not proud of it. but its damn funny 🤣
@tranquil ridge https://software.intel.com/content/www/us/en/develop/training/course-machine-learning.html
thanks
wait im new but can i propose a solution

@tranquil ridge but coursera is best
dont you dare create a pwull request on my repo. that code is legendary.
code something shorter
zing
its kinda slow so i was only able to watch till linear regress
make it short you are exceding the time limit
this isnt a codeforces problem solution lmao

i would like to contribute more cursed code tbh 🙃
byy i am gtg
cya
I like looking at it an wondering how tf it worked even tho its really taking up a lot of time and memory 🤣
haha
bro same, i probs have code from when i was 8
else if 1
else if 2
else if 3
else if 4
goes on for infinity
this is another one of my cringe code (idk why I even created a function)
def finder():
while True:
number = int(input("enter number: "))
for i in range(11):
answer = number * i
print(str(number)+(" x ")+str(i)+str(" = ")+str(answer))
finder()
finder()
this is better
multiples finder 🤣
if (chungus = 69)
delete system32
where did you get the 11 from 👀
oh nvm
it's a multiplication table lol
yeah multiples finder
but my fav one is the nearest perfect square finder
could be useful if I was in 5th grade
.topc
.topic
😅
👀 why do you like lists so much
yes
best data structure ever (data type?)
stacks
ew
hmm no queues
def perfect_square_finder(num):
return int(num**(1/2)) == num**(1/2)
cringe code because no lists :D
at least use a single ** operation 😦
damn
no, it has to be inefficient
that's a universal rule 😤
damn
haha
Lol
@jovial island please don't post memes without any context into off topic, read https://pythondiscord.com/pages/resources/guides/off-topic-etiquette/
We're a large, friendly community focused around the Python programming language. Our community is open to those who wish to learn the language, as well as those looking to help others.
no
is vivek a mod?
lol
lolll
r/clevercomebacks
perhaps
is vivek a plugin
vivek is an object
vivek is not a raspberry pi, can confirm
is that sys.stdout?
from std import stdout
from System.out import print
Lol
Don't think so
What a wrapper does is basically allows the interaction with the API to be more simple

Alright, so an API is basically something that you can send HTTP requests to in return for data
So say I have an API that returns the weather, I could request to it like below ```py
import requests
r = requests.get("https://weatherapi.com/weatherinmylocation")
``` And now r has the weather data
Now, you'd usually have to parse and retrieve the data thats in r
I tried searching for long earlier and I can't find resources
I see
this is actually what discord.py deals with internally if im right
But, there are API wrappers which make this easier, and take most of the work away
Yes
the discord api is just a bunch of endpoints innit?
Discord.py is an API wrapper that interacts with discords api
I don't want to make discord bots 😫
lol I thought I got disconnected from wifi
So instead of doing all that, you could do something like this ```py
class MyAPIWrapper:
def init(self):
...
def get_weather(self):
requests.get("https://weather.com/myweather")
# Handle data
return weather
And a socket connection, yep
it's just an example
Now, this makes it easier to interact with my example weather API
ight
Now, what you could do is take an already existing API, and write a wrapper around it
u can make a cat api wrapper
Aren't api so big?
It doesn't have to be great, get it to work first, read about how an API works first, how to handle the data, read into the requests module
Or there are small ones?
Depends on the API
Depends, you can have an API in five lines of code, or thousands
They are some with very few endpoints
weatherapis can actually be a pretty good starting point imo
Yeah
they won't be overwhelmingly large
Noice
Take a look at rapidapi.com, pick an API, and write a wrapper for it
But yeah, I have to eat lunch now, cyaaa guys
byee
I should learn request first 
and how http works
Are you looking to do a portfolio project?
Nope practice only
isnt requests also a wrapper for bare http requests?
plottwist
o
Small utility? Do you have an example?
guys!!! my vlc rich presence is working
damn
Sure, I did something like that recently https://github.com/akarys42/cloudflare-ddns-docker
why dont you make your private ip static?
no?
you mean an r/woooosh?
there is no joke, I think
Oof
Hm
Lemme rephrase that
Cloudflare DDNS is a configurable Docker service updating your CloudFlare DNS records periodically to match your local IP address.
local IP = private ip???
Iiiim back :D
My public ip is dynamic because my isp sucks
right?
Nah, the local public ip
what's a local public ip 😭 ?
The public ip of your current network
so... just a normal public ip?
Yeah
But like
The local one
Local to the machine running the container
So basically, no matter what the ip is, the cloudflare records will point to it
nice
just set up a static one internally?
@split spire the codes are here https://docs.microsoft.com/sv-se/windows/win32/inputdev/virtual-key-codes?redirectedfrom=MSDN ```py
VK_VOLUME_MUTE = 0xAD
VK_VOLUME_DOWN = 0xAE
VK_VOLUME_UP = 0xAF
@languid osprey i'm making my own api :D
@rare dawn thanks!
Cool :D
in addition, you can use a simple autohotkey script to read them as well
cc @split spire
i need to figure out how to manage tokens next :D
cool
Does the registry of all the registries contain itself? 
hm
@languid osprey do you know where I can find small api to wrap?
Check out rapidapi.com
I can't find any on Google 
Theres plenty there
Ty
getAttackDamagereturns the base damage of the tool. Note that most tools ask for an integer damage amount in their constructor, which means the resulting damage is(float) materialDamage + (int) toolDamage + 1.
Minecraft do be cursed in places
FabricModelPredicateProviderRegistry
also, good old Java names
meanwhile in the comments on a tutorial
Hmmmmmm
Should I do mint or manjaro (I’m new to Linux as in never used it)
I think imma use virtual box
As vm
But garuda KDE dragonized look sexy
hmmmmmmmmmmmmmmmmmm
@Linux Users
Garuda gnome kinda hot to
Hm, I personally use manjaro
But mint is a great choice for beginners
If your going with manjaro I recommend the KDE version
Depends
I recommend trying them both out on a VM and see what suits you
Or if your not using VM,s just test them from the USB
@wicked hollow
Bourne shell was written this way, for reals
huh?
jesus
Lol
The level of fanaticism you need to have to persist with that the whole way through writing a shell, pushing through the constant impedance mismatches between the two languages
Incredible.
@grim seal where is yo macbook
"Some people are so poor, they only have money"
- Bob Marley
when someone is trying to break into your vps 😳
didn't know ur screenshot quality goes down when someone tries to break into ur vps
@languid osprey do you have an api wrapper you created on your own?
I want to have a reference
I'mma make an api wrapper for this one https://docs.thecatapi.com/
TheCatApi // Developer Experience
Get your API Key from - https://TheCatAPI.com
Here you'll find the API reference & Code examples for:
1. Searc...
uh
ssh keys?
my password is 48 characters long, and is random numbers letters and symbols
i'm good, i just find the idea of someone trying funny
it's like that because i'm using a github service which logs into my vps and does a pull request every time i push
it doesn't support ssh keys
ah that does narrow it down thank you /s
you're welcome, if you want to break into my vps now it should be easier
imagine making a typo
oh god i hope not
tpyos are cringe
i use termius for that exact reason, used to use the basic windows ssh
@limber pollen need some help, am building a package for pure-lang for a piston, and needed to cross check if my build was right:
#!/usr/bin/env bash
PREFIX=$(realpath $(dirname $0))
# Installing LLVM and clang (the latter is optional but recommended)
curl "https://releases.llvm.org/3.4.2/llvm-3.4.2.src.tar.gz" -o llvm.tar.gz
curl "https://releases.llvm.org/3.4.2/cfe-3.4.2.src.tar.gz" -o clang.tar.gz
tar xfvz llvm.tar.gz
tar xfvz clang.tar.gz && mv clang llvm/tools/clang
rm llvm.tar.gz && rm clang.tar.gz
cd llvm
# Building and installing - LLVM and clang
./configure --enable-shared --enable-optimized --enable-targets=host-only --prefix "$PREFIX"
make -j$(nproc)
make install -j$(nproc)
# Installing Pure
curl "https://github.com/agraef/pure-lang/releases/download/pure-0.68/pure-0.68.tar.gz" -o pure.tar.gz
tar xzf pure.tar.gz
rm pure.tar.gz
# Building and installing pure-lang
./configure --enable-release --prefix "$PREFIX"
make -j$(nproc)
make install -j$(nproc)
here it is
should i share the repo of the piston?
I can't say I'm entirely familiar with it
oh ok,https://github.com/engineer-man/piston/pull/178 this is what i was talking about
Uh, I have something that's wraps another library, but not an api
Are you SSHing into some computer with your phone?
huh?
no
I just didn't include the empty space of the terminal in the screenshot, as it serves no purpose
Oh okay
my modding education sure is proceeding fast - I made an item that crashes the client on rightclick
might be all clients in render distance, actually
Lol
||game.crash()||
Like, shouldn’t the game catch errors
It should, but it didn't.
Even if an event trigger a NPE, don’t stop the whole game
I literally just forgot a renderer.
hi
anyone who uses linux as his/her main os?
(for a projectile the item created on rightclick)
Can’t it like.. not render it..
Hey! I do.
what linux do you use?
Custom Manjaro KDE
good
i have an old pc
and i think windows is not good for it so i want to buy a new hdd or sdd and install linux on it
how much capacity shall i have for an average ubuntu or parrot os install?
do you think 500gb can do it?
i mean yea a full install that if i ever tried to changed to an other pc, it would make any trouble
its an SSD right?
Yeah, NVMe
well as i said my pc have an intel core dual and 2gb of ram
I am not gonna do all my work on it, but i might do a little of my coding on it. as i have researched, among ubuntu, parrot and kali, parrot uses the least amount of hardware resources. do you think it can handle linux?
Linux should work perfectly on that hardware
and as i see, manjaro uses even less, so that is another chose i can make
Then GGs, I'm gonna deep clean the system and give her a new life
I'd recommend a manjaro install with either xfce or kde
i have used both xfce and kde on my vm machines, and i feel kde might be smoother
Hm, I'm pretty sure xfce is lighter on resources, but they both should work fine on your hardware
alright then, thank you all for the help
xfce
ik i wanted it for penetration
mk
what does mk means?
mutation of ok
...&mut ok?

Lol
test 2, let's see if I get another crash now
hmm, maybe I should see if there's a fabric mod like VanillaFix that makes crashes only crash to main menu
though it won't help me with this, as I still need to recompile the methods
I didn't even get to click this time, the already flying entity crashed me 😔
mk = mmkay
I did it, yay!

for one, I probably need my own EntityRenderer subclass, since using ThrownItemEntityRenderer just because it was there is... not the right solution
or ThrownEntity at all
since, y'know
it makes my rays fall down 😔
no idk java 😔
I wish it was Java that's the problem, it's Minecraft's wonderful structure
pystachio
lmfao
just to ask, anyone want to be my coding buddy?
im making a mini operating system,
python of course,
and might need help.
ping me
if im online
joe uses a macbook? lmfao
He does
Windows NT gang
He has both iirc
ooh
Hey @fading herald!
It looks like you tried to attach file type(s) that we do not allow (.fwl). We currently allow the following file types: .gif, .jpg, .jpeg, .mov, .mp4, .mpg, .png, .mp3, .wav, .ogg, .webm, .webp, .flac, .m4a.
Feel free to ask in #community-meta if you think this is a mistake.
smh having money for macs and pcs
lmao
Can I share my vbScript here? I don't want you to download it
Hey @safe compass!
It looks like you tried to attach file type(s) that we do not allow (.vbs). We currently allow the following file types: .gif, .jpg, .jpeg, .mov, .mp4, .mpg, .png, .mp3, .wav, .ogg, .webm, .webp, .flac, .m4a.
Feel free to ask in #community-meta if you think this is a mistake.
is this to prevent malicious content from being uploaded
Yeah
.topic
Suggest more topics here!
idk
@grim seal you have a macbook!!!!!!!
yeah
I'm trying to work out my body more take care of myself. Does anyone have any recommendations for work out equipment for back muscles?
Do you hate it when your computer gets destroyed by a main battle tank? Do not worry anymore. This tutorial will inform you of the risks involved with main battle tanks near your computer and show you how to improve your computer rig to resist any type of ammunition shot at it. With this tutorial, your computer will be safe from all kinetic ener...
huh
anyone want to give me more knowledge in python like teaching me? im a beginner
read automate the boring stuff
its what im abuot to do -.-
