HNHacker News
TopNewBestAskShowJobs

shroompasta

69 karma · joined January 20, 2022

submissionscomments
shroompasta··on Request bodies in GET requests
True.

I have personally gone off the deep end and started writing 200, 400, and 500 for all my status codes instead of the specific 2xx, 4xx, 5xx ones.

If details of an error response need to be mentioned, it will be in the error response body.

My motivation came from GraphQL as it responds everything with 200s, and so far it has been humming along fine.

True REST are more guidelines if anything.

shroompasta··on Vim Galore: everything you need to know about Vim
>Obviously your experience doesn't agree with mine, and I clearly can't say why. All I can say is that vim simply "clicked" for me when I first learnt it. I have coached enough coworkers that I can say the same thing applies to most people who take the time to learn the "vim way". And of course vim would not be as popular as it is, if that wasn't generally the case.

From my very first comment about the matter.

>>I spent about 4 months on it daily unable to get up to speed how I was originally.

>>This may just speak to my own inabilities of muscle memory, and granted, If I used Vim a little younger, I think the outcome would be different.

You keep talking about configuration, when the bigger elephant in the room is learning the keybindings.

It took me almost 2 months to be comfortable without looking at the vim cheatsheet

It then took another 2 months to get to a speed at which I felt like I could be productive.

And at that point, my typescript projects were so incredibly slow, I had to quit vim.

>But it's objectively complete nonsense to claim that vscode does not require a substantial time-investment if you really want to super-power it.

I still disagree as GUIs makes configurations a lot simpler, and as plugins are just a click away.

Again, if you include learning the keybindings, which for some reason you refuse to, you'd find it within yourself that you would disagree with your initial statement.

shroompasta··on Vim Galore: everything you need to know about Vim
> the two editors are pretty equivalent in how much time you have to spend on super-powering them.

One of the most disagreeable things I have ever disagreed with.

If you remove your bias, you'd find it within yourself that you would disagree with your own statement as well.

When the next VSCode comes along, I will move onto it with ease. Please do not ever consider that I'd get onboarded to vim just as quickly - I've spent enough time with vim to know such.

Jesus.

shroompasta··on Procrastinate: PostgreSQL-Based Task Queue for Python
Why this and not celery?

And why Postgres and not rabbitmq or redis?

shroompasta··on Tor Browser: a legacy of advancing private browsing innovation
that's an interesting perspective - one that I'll take to heart, for sure.
shroompasta··on Tor Browser: a legacy of advancing private browsing innovation
This will be a contested opinion, but I believe full anonymity allows people to become the worst version of themselves.

I've used Tor for a very brief period once in my life, and that was to purchase adderall off of either Silk Road or AlphaBay (I can't remember), and I'm unsure of what the Tor ecosystem is like today, but not even that long ago, the vast majority of the Tor network was used for crime - ranging from child pornography, to hitmen available for hire, banned weapons, and obviously, for drugs.

I did not come across anything meaningful browsing the onion ecosystem, but left with a depressing insight of anonymity.

On a higher level pov, anonymity allows some of the most toxic and damaging ideas to brew and fester.

This is easily pointed out by the characteristics and behaviors between Twitter accounts that have an association with a real individual as opposed to ones that don't.

The difference in what they tweet is staggering.

Not to mention sites like 4chan and it's children.

Don't get me wrong, I'm rather against Big Brother or ISPs tracking and selling off our data, but absolute full anonymity is just an invitation for some of the worst things to happen.

shroompasta··on Vim Galore: everything you need to know about Vim
Even if that is the case, I don't understand why you think getting onboarded to the next big thing is a hurdle.

Do you have to learn Vscode? no.

Do you have to learn vim? immensely so.

Moving onto the next big thing (although i'm betting on vscode for at least the next decade), is not going to be hard.

shroompasta··on Vim Galore: everything you need to know about Vim
Vim, to me, has been unproductive.

I spent about 4 months on it daily unable to get up to speed how I was originally.

This may just speak to my own inabilities of muscle memory, and granted, If I used Vim a little younger, I think the outcome would be different.

But the thing is, I'm productive enough.

Furthermore, I found the mouse to be faster in many cases - I only believe the top 10% of vim users who have spent countless hours tailoring their config to be the most "productive" in terms of typing.

I say productive in terms of typing, because when we code, a grand majority of our productivity actually comes from our brain.

Squeezing out additional wpm actually has very little relevance to productivity.

But looking at seasoned Vim users looks cool though, and it definitely does give those style points.

shroompasta··on Prime Video Uses WebAssembly
Your whole line of comments is equivalent to "No offense, but.." -> proceeds to offend.

Especially with your "buttons and doodads" comment.

I wasn't even trying to get personal, but If you're going to hit, be prepared to take a hit.

------------

Never once has the weight of my OS been a concern for me, and I'm going to make the assumption that is the general case for the majority of users.

Never once have I heard the metric of LOC/pixels.

You say it's bloat. I say its necessity.

It's just keeping up with the times - beautifying and manicuring to attract eyes.

And you failed to address my comment about all the logic that FE engineers have to deal with - which is more of the meat in FE development than what happens skin deep.

shroompasta··on Prime Video Uses WebAssembly
While I agree in some cases, tech companies aren't marketing to those with that specific taste pallete
shroompasta··on Prime Video Uses WebAssembly
> Web devs typically don’t have strong instincts for mobile apps, they require more mentorship & onboarding time.

I don't agree entirely. I do understand that there are differences in concerns regarding web and mobile, but the similarities overrun that of the differences, ESPECIALLY if they're working with react + rn.

mentorship + onboarding time aren't words I would choose if a developer wanted to move from React to React Native - you make it sounds like a dev is joining a new company.

> Animation and interactivity is strongly limited in RN - You’re always so many levels removed from the actual APIs being used. For example, using UIKit and CoreAnimation are absolutely amazing and super lightweight on CPU/GPU in comparison. UICollectionView is a modern miracle that offers so much more control than FlatList.

Again performance is not something I will ever disagree with, the only part I disagree with is where people typically put that bar of "we need native because of performance" - It's a lot higher than most people think.

Furthermore, your example of Flatlist in animations is confusing. A better example would probably be React Spring. Granted, RN animation is levels above, obviously, but it doesn't mean RN can't implement the same style of animations as native can

https://twitter.com/VilacaRodolfo/status/1178351034051284993

> JS/Babel/node_modules is hell, no I won’t elaborate.

ok

> Multi-threading, priority/concurrent queues etc for maintaining good all-around perf while doing intense operations is very strong with native platforms. RN just has sophisticated band-aids.

not arguing performance. that is always a given.

Again, I will reiterate.

If React Native is good enough for Discord, it's good enough for 3 quarters of mobile apps out there.

Happy coding!

shroompasta··on Prime Video Uses WebAssembly
This comes off incredibly naive of FE engineering.

Buttons and Doodads? sigh.

A significant factor as to why Apple has succeeded the past 2 decades is due to the design of their products - from the sleek aluminum bodies of their hardware to the UI/UX of their operating systems.

Unless you want your UI to look like something out of 1995, you're going to have to make it look good.

Making it look good will require a decent amount of code.

From animation libraries like Framer Motion, or data visualizations using d3, or even After Effects renders from Lottie.

That isn't even mentioning the amount of state that is required to be stored so that proper renders could occur - If your user has logged in, if your user has typed something into an input field, how many times you should retry a request if it fails, what functions to run due to a websocket response, and myriads of other things that FE engineers have to deal with.

Please reconsider your thoughts.

shroompasta··on Prime Video Uses WebAssembly
I disagree with this perspective.

From a startup pov, going with native apps will require multiple teams (Usually just Android + iOS, but occasionally Windows as well)

React Native will only require one team, or just one engineer depending on the size of the project

Better yet, If your front end developer is fluent in React(web), then that developer is already fluent in React Native.

I completely disagree on the "awful lot of work", when you could literally get your FE developer to work on your "native" apps.

Sure, where performance must be squeezed, it's probably optimal to go native, but that bar is set a lot lower than where it actually should be.

If React Native is good enough for Discord, it's good for 3 quarters of all apps out there.

shroompasta··on Why our team cancelled our move to microservices
Their architecture didn't provide any clear boundaries to be sufficient for microservices, however that isn't the case for many medium to larger sized projects.

(By the way, just because there's still quite a bit of coupling between services, doesn't mean there aren't clear boundaries - Microservices can communicate with one another all the time and still be justified in being decoupled)

There isn't an absolute answer to monolith vs microservices - It depends case by case.

Instagram was built using Django and I'm unsure of ig's architecture today, but it remained monolithic for a very long time (at least till late 2019), and if that architecture sufficed for Instagram, I'm sure it would suffice for many other projects.

However, still, it's not a this or that as many of the comments here would seemingly imply - Again, it's HEAVILY dependent on the case.

shroompasta··on Faster CPython (2021) [pdf]
Instagram was also initially built in monolithic Django
shroompasta··on Faster CPython (2021) [pdf]
Choosing a language is a significant factor towards the performance of your services.

A service built in go can req/resp up to 30x faster than one built in python.

https://www.techempower.com/benchmarks/#section=data-r20&hw=...

I know benchmarking isn't always the greatest, especially when the previous maintainer of Actix-Web (Rust) kind of cheated to get to the top of the leaderboard, but it still provides a decent general overview of how many responses/s a service can handle when using the same box.

shroompasta··on Industrial ammonia emits more CO2 than other chemical-making reactions (2019)
the case in point was obviously Japan which fell from the third largest economy to the sixth largest in the past two decades.

Japan wants to be like China and the US, not like Qatar or Switzerland.

GDP is not GDP/Capita

I believe you have this backwards.

shroompasta··on The implementation of the UK Covid-19 dashboard
to be fair, microsoft should've been included in the first place. they've been teetering top 3 market cap for a while now.
shroompasta··on Pydantic
Yeah, that was my bad. Went by a bit too quickly.

looks good.

shroompasta··on Pydantic
Ah, I must've missed something in the first lookaround.

looks good.

shroompasta··on Pydantic
looks promising.

At first sight it seems like you still have to write a "schema" for the SQLModel based on your SQLALchemy model - so basically, two sources of truth.

If you edit your SQLAlchemy model, you'll also have to edit your SQLModel.

sqlalchemy-marshmallow allows you to build your schema based on your SQLAlchemy model.

Other than that, I'm still somewhat intrigued.

Thanks for the suggestion.

shroompasta··on Pydantic
Looks great.

I'm hesitant, however, since marshmallow-sqlalchemy provides full integration with your SQLAlchemy models, but pydantic-sqlalchemy only is for generating Pydantic models based on SQLAlchemy models, and it seems as if it's still experimental (Why does it have more stars? :thinking:)

Otherwise, just between pydantic and marshmallow for straight up validations, it seems Pydantic is more legible and easier to use at first sight.

Will switch if pydantic had full integration with SQLAlchemy.

And for those of you looking down on me for using ORMs (yes, i know some of you exist), I use both raw SQL and SQLAlchemy.

I find it multitudes easier to build models and deal with migrations in SQLAlchemy than writing scripts.

shroompasta··on Industrial ammonia emits more CO2 than other chemical-making reactions (2019)
obviously not killing people.

I'm just demoralized that low birth rates are stigmatized as they are correlated with lower GDP, when low birth rates are somewhat of a godsend in times like these.

Then nations with low birth rates scramble to find ways to up the birth rates despite understanding the C02 cost.

It's ironic, really.

shroompasta··on Industrial ammonia emits more CO2 than other chemical-making reactions (2019)
Why is depopulation not even a consideration as a solution for climate change?

Surely there are ethical ways to implement it.

Or do the world's largest and wealthiest nations only care for their hold on economic power?

shroompasta··on On Leaving Facebook
the reason why FAANG/M companies do ds/algo interviews is because they get an ocean of applicants and it's necessary for these questions to be the immediate filter.

Most startups I have applied to previously rarely asked ds/algo interview questions.

It's not that they want to, it's that they have to.

shroompasta··on Intel's $20B Ohio factory could become world's largest chip plant
I may be wrong, but I'm assuming one of the cardinal factors in the location came down to the cheapest labor they could find.

Competing with labor, in terms of willingness to work for a low wage, against Asia is next to impossible for these fabs.

shroompasta··on Free Postgres databases for small projects
I'm having trouble understanding the purpose of these edge services.

Granted, I've only handled small - medium sized infrastructures, and never really experienced the issues at scale, but if I were to get to that point, wouldn't it be easier to just hire a Infrastructure Engineer who could deal with the replication / sharding, not to mention having that engineer also deal with site reliability and dev ops?

If a user wants to hit my service, and then that service has to hit fly.io's postgres, isn't that an increase in latency? sure I could probably have it pretty darn close, but 20-100ms is still 20-100ms. I could manage my own (or hire someone), and have the db live in the same container (if i have a big enough box), or have it within the same data center.

And if it is the case that I do need to replicate across data centers, at that point, I should have the financial capabilities to hire an infra engineer.

Can anyone enlighten me why I would ever need this?

shroompasta··on FlyZolo – Youngest Woman Solo
Even if that is the case, this is more laudable than other "frivolous" hobbies that rich kids can get into.

I'd take this over a young socialite with a functional drug issue any day of the week.

If you're rich and you make the most of it, then cheers to you.

Hope she reaches her dreams of becoming an astronaut.

← PreviousPage 3 of 3