Better HN
topnewbestaskshowjobs
Log inSign up

commitpizza

671 karma · joined Oct 16, 2022 (4y ago) · 130 submissions

Submissions

comment 3y ago · link · parent

I paid for Tabnine pro since it was 50% off for a year but I won't renew it unless it massively improves.

I mean, it does give good completions sometimes but the time saved isn't that great imho. Maybe chatgpt is better but it feels like AI still have some way to go to actually be so useful you would be less sucessful without it.

comment 3y ago · link · parent

Compared to moat languages, if you have no visitors, php takes up 0 system resources from your system to just sit there and wait.

So you could have hundreds of small sites on the same machine for an extremely low resource cost. That is something it brings to the table and its very beneficial for hosting solutions where there are a lot of small webaites sharing on the same resource.

comment 3y ago · link · parent

I think he/she is joking

comment 3y ago · link · parent

I would say, as a person who have been developing in JS/TS daily for the last ~5-7 years that it depends on your team.

If you have a larger team, yes it is worth it. If it is your side project or if you are like 2 people working on a project then I would say it's probably not worth it.

Typescripts biggest strength is that it's easier to work several people on the same thing. When someone else makes a change, it's easier to figure out what their code does.

The bigger the team and project, the bigger benefits you will get from typescript. At least, that is my opinion.

comment 3y ago · link · parent

I think the issue is that there is three different types of people when it comes to performance.

There is the 1% that are in a need of hard realtime performance, that thinks about GC performance as an issue that needs to be adressed. Sure I can get that for these people, these kind of discussions seems stupid and confusing since they have to develop in C/C++, Rust etc to get the pure performance they need. These people probably aren't in this thread because they know that Python is not a language for them and will never be.

Then there is the 99% crowd, which I am a part of, that could use slow-as-shit frameworks like Rails or Laravel because the performance is just a nice-to-have. These people, like myself, compares Python perf to perhaps PHP or Node because they are fast enough languages and in this kind of league a framework like OPs can make a huge difference. No matter what language you pick here you are basically always using something "beneth" it. Node has been picked by many because it's faster than for example Python and Ruby.

Then there is the people who are part of the 99% crowd but are just have to comment and point the needs of the 1% out because they are negative people who probably produce little themselves and have to hate on what other people create and distribute for free. This group is where most haters on HN belong in. :)

I started in PHP, when I went to Node in the early beginning I was deeply impressed by the great performance and nice features it had. Sure it was built upon C++ libraries but I am never gonna use C++ to write my web api. Still, I could use Node and get 2-3x AT LEAST the performance in all of my endpoints because of this and all my code was in javascript.

What I am trying to say is that I don't care if you pack my code and run it on a computer in Minecraft or your calculator, if it runs faster for very little to no pain on my side that is pure joy to me.

comment 3y ago · link · parent

Well, it could be true IMHO. If I run my code that calls down to some ultra fast, mega well done C++ library that is much better than anything in the Go community my code then completes requests faster than the Go alternative.

If that is the case, that should influence the decision when it comes to performance. If performance is a very important deal in your app, you have to test this yourself so that you reach the performance you need.

Perhaps you can write C++ extensions to Python for the perf-heavy parts yourself instead of having to write the entire application in a language that takes much longer time to develop in?

comment 3y ago · link · parent

> Yet another "X faster than Y" where inside X all hot jobs are done by really good-tuned C or C++. Facepalm.

This is the case for basically every programming language or performant library that exists. Yet, I never see this when discussions exists about node libraries or other languages for that matter. I mean you could argue that node itself is just a thin wrapper around fast C++ libraries.

Who the fuck cares if the request goes down to some compiled C++ library? I still write my logic in Python and get this benefit anyway. This is what makes it great.

comment 3y ago · link · parent

Node.js uses libuv also but it is way slower and tbh, can't you compare node to other things because of that it is using v8 and libuv?

I don't understand this this logic.

comment 3y ago · link · parent

Sorry for all the hate you seem to be recieving, I think it looks great!

I can't join the discord however since I was banned for unknown reasons and cannot create a new account without giving them my phone number, which I refuse to do.

But remember many great things get hated upon in the beginning, take dropbox as an example. People on HN thought it was a shitty idea and they seem to be doing just fine :)

comment 3y ago · link · parent

I actually thought about buying a Steam Deck just to support it financially and then just giving it to a smaller cousin since I don't game.

comment 3y ago · link · parent

Yeah, I hate when companies name products or themselves like that. It's just a matter of time before it is the reverse.

comment 3y ago · link · parent

So I guess we can remove the "Open" in OpenAI then?

comment 3y ago · link · parent

Very cool, I will bookmark this since I am out on a look for a new backend framework for an api I am building.

comment 3y ago · link · parent

Valve is so far a great company and Steam is a nice product. What they have done for linux gaming is huge and they treat their customers well.

I am a happy user of Steam compared to pretty much all the other similar services that exists.

comment 3y ago · link · parent

I would understand it if the individual preaches that people shouldn't fly and then do it themselves but in this case there is no reason to hate on him. Of course he is going to fly private, he can easily afford it and would probably be stalked and/or harassed by everyone if he didn't.

Most haters would for sure fly private themselves if they could so I think it's jealousy masked as critique.

comment 3y ago · link · parent

I am not even that much of a fan tbh. But to say Elon hasn't done any good for the environmemt and technical progress is just objectively false.

Who cares if tesla was founded by someone else, he saw potential and executed the growth to what it is today. Tesla is also just one of the several great companies he has founded or been an early part of that does amazing things.

What companies have you been a key player in that has made great technical progress or reduced our environmental impact? Stop the hate man, be mature.

comment 3y ago · link · parent

It's easy to be a critic. Elon Musk have done more for the environment than most people ever will.

I see no posts for all the other rich people who uses their jets for trips that does nothing to reduce our impact to the climate.

It seems quite stupid to me to obsess so much over one persons negative impact and ignoring all the good that has come from the companies he runs.

comment 3y ago · link · parent

I can only wish the author of this article a good afternoon.

(https://www.youtube.com/watch?v=Rj9VljRQzCQ)

comment 4y ago · link · parent

I don't understand your point, this is exactly what I am doing. I am not using Windows or MacOS.

> especially when so many people are perfectly happy to keep buying and using Windows OS?

Honestly, this is because a lot of people that would care are unaware that this is happening. It's impossible to stay on top on everything in your life but that doesn't make it ok to treat those people poorly.

The main issue is that for many, there isn't a choice since you can't go to most stores and buy a linux powered machine. You have to have special knowledge in order to even install it.

comment 4y ago · link · parent

Yeah and I have no issues paying for it but unless you run Linux there is no other option that doesn't do this unfortunately.

comment 4y ago · link · parent

Horrible development, just yet another reason why I use Linux on all my privately owned computers.

82.

Ryan Dahl and Deno(syntax.fm ↗)

2 points · by commitpizza · 4y ago · discuss

83.

The waning days of DEI's dominance(world.hey.com ↗)

23 points · by commitpizza · 4y ago · 12 comments

comment 4y ago · link · parent

I would advice you to at least use some kind of web component wrapper. I have used https://lit.dev/ a lot, even to build a large app and it works really well. You can get started very quickly and the experience stay true to the underlying platform.

I think lit is really a library that deserves more attention since it's so good.

Unless you simply want server rendered html, you can achieve that easily with htmx to get a bit better experience. Then you may use whatever language you want and just return html.

comment 4y ago · link · parent

Interesting article with an interesting writing style, I may pick up the book even if I suck at reading books!

I didn't start as a skeptic and really think functional programming looks beautiful and is very useful in preventing side effects. However, in most practical situations I've found over the years functional programming to be harder to understand and debug when stuff goes wrong.

In javascript in particular, functional programming is very nice but at the same time usually way more ineffecient so for many tasks I tend to go back to normal for loops just because it's that much faster.

I had a collegue that wrote a lot of functional code and his code was extremely hard to follow and understand. Even if it was beautiful figuring out where the system went was the hard part and I had to go to the function decleration, understand it, move on to the next until I found whatever the issue was. When I found the issue, I couldn't easily fix it because the next function called was expecting the data structure to behave in a specific way so for one issue once I had to change basically every function called before and after which was way more tedious then if it would have been more sequential.

I don't know. There is something to say about functional programming but lately I have kind of tilted back into the more standard approach. Functional programming is a lot more beautiful in practically every implementation I've seen but the standard approach is, in my experience, usually more useful in practical terms.

comment 4y ago · link · parent

Very cool idea, the only question I have is how fast does this not drain the battery of the mics?

comment 4y ago · link · parent

Well yes, but this is a much cheaper option. Instead of having many smart gadgets you only need one. The mobile phone or some other microphone but that is the most obvious option.

Instead of paying hundreds of dollars for all these gadgets that have to be charged and kept safe you can buy cheap variants and still have basically the same benefits.

comment 4y ago · link · parent

Just out of curiosity, how would you configure that in a systemd configuration file?

comment 4y ago · link · parent

Somehow I feel like if you need to install Node to run Deno, you may as well just run Node from the beginning.

comment 4y ago · link · parent

> AFAIK unlike node, Deno's API is largely promise-based and therefore all unhandled exceptions should become unhandled rejections withou crashing the process - so this should be less of an issue than it is with node

Perhaps you're right, I have not tried this out in Deno-land so I cannot say wether this actually applies to Deno the same way.

I just know that I got burned by this exact issue in node and I think this can be a security issue that people usually don't really think about. If you know that some api is a node api, if you manage to find a bug that is crashing the process one could probably script it to trigger it to crash over and over again. Even if it restarts quickly, usually it takes a second or and in that time one could bring the entire api down.

I am not aware of any instance that this have been used against some api in practice but most other languages handle this much better than node does and the javascript way of crashing on error is one of the things that made me question using javascript for backend services at all.

Regarding the kubernetes... no thanks. I would not go into that beehive unless forced. I didn't like the complexity increase of adding a load balancer and that is like a drop in the ocean of the complexity that is kubernetes.

12345