Do all the things like ++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatarSign Up
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple APILearn More
Search - "asyncio"
I just switched up my temperature sensors and attached a TMP36 in place of the usual DS18B20.
I did my usual pinout and turned on my Pi, then compiled Python3.6 because I needed it for asyncio.
Ten minutes later when I entered my room again, my Pi was fried and the sensor was smoking.
About 4-5 hours ago I wanted to make simple websocket to get input from textarea and parse it on server and somehow got myself into developing in asyncio -> aiohttp -> graphql-core -> graphql-ws -> aioredis
and svelte-> typescript
I still didn’t make the stuff I wanted but I’m very close on backend at least.
I have some frontend part somewhere in my old prototypes so it will be faster if I figure out svelte.
Still don’t understand what the fuck just happened.
Maybe it’s because I wanted try those frameworks for a long time.
All ‘simple’ examples I found have around 20-30 files for backend and same amount for frontend so more then 50 files to get this shit working.
They’re called oh irony “simple chat”.
Now I see why no one fucking understands this shit.
I’m trying to cut mine to 5 files.
I thought developers are lazy bastards who don’t like write code.
But now after this they’re all looking like adhd coders.
Looks like Monday won’t be my best day.9
tldr: my classmates suck and I hate them
We study cs in school, and my classmates are super dumb.
Here is an example from today:
The task: build an http server in python, using sockets.
My classmates: writes everything in the main function, uses try-expect for everything and every error possible, nothing works, nothing worked after a week.
Me: properly separated to different functions, used goddam regrx to get data from requests, used asyncio to make sure it can handle multiple requests at the same time, everything worked after 2 hours.
But, and here is the problem, after I finish they ask me a bunch of dumb, 'Just Google it dude' questions and they call me condescending because I get mad after the second hour of teaching them the same thing.
Once they told me:"you think you are a better programmer then us" and I just want to say this out loud: I AM A BETTER PROGRAMMER THEN THEM, THEY ARE THE PERFECT EXAMPLE OF HOW YOU SHOULDN'T DO ANYTHING AND I HATE THEM.
That's it, I'm done. I feel much better now.
PS: it's okay to suck at programming, but please stop thinking that everyone who's better than you is condescending.3
Pygame can handle kinect, but can't interface with asyncio. It freezes if I try to run event.wait in an executor. You may write the best game engine for a language, if you won't use language standards and don't support async, then it's shit.5
Getting started with Python's asyncio is probably the worst experience I've had with the language in 2+ years I've been using it.2
Python3's asyncio is awesome.
In an IoT server we used python2 socket programming with multi-threading. Recently I have changed the socket layer to python 3 asyncio and performance was far better. I am not gonna use multi-threading anymore.
What do you guys think about asyncio?1
I was troubleshooting an asyncio websocket project for two hours that was working the previous day with minimal changes.
I am new to asyncio so I was getting very frustrated thinking I wasn't understanding something.
As it turns out, I had replaced a continue with a return, killing the broadcast function completely.
What do you guys think is better: socket, SocketServer or Asyncio??
In my experience i found socket performing better than the SockerServer, but i have heard that Asyncio is even better.4
Speaking of Go.
defer() is like blessing.
Every time I code in Python, especially asyncio code, I wish it has something similar.2