Live data from Hacker News

Programs are dead, and JavaScript has killed them

pouria.dev

41–50 of 216 posts

Re: Programs are dead, and JavaScript has killed them

#41
post #31

My experience is pretty similar for my projects but I think generally we shouldn’t point too many fingers. When it comes to public projects, I’ve found a lot of trouble regardless of its JavaScript-proximity. I think we’ve been blessed by a growing ecosystem of projects that are clean to build, and eschew problematic dependencies. Try building anything Linux and C related and you’re worse than JS because now you need…

> I gave up on building on my mac altogether osx is not linux. It has a gazillion of incompatibilities and most developers never test for it, so even if the code compiles, it's no guarantee it will work. > Try building anything Linux and C related "apt install libwhatever-dev" does it in most cases. > docker-packaged projects You mean completely insecure projects that most likely run an old and vulnerable openssl?

Yea macOS is never a guarantee but I’m always hopeful when they include Mac instructions in the readme.

I’ve found projects that use C++ or other older languages and meant for Linux still have a nightmare with building. The project I looked at had a bootstrap script, an initialization script, a pip installation, and 3+ different make-alternatives. Not uncommon even when apt works.

Docker is great but it’s only as secure as Linux can be. Yea it can have outdated SSL, but it’s just as likely that the thing you need depends on a particular version. Most projects don’t get versions updated unless it’s broke. IMO if something is a web service or generally at risk, you should not depend on the good-faith security being vended. Put it bend a secure network or proxy, Audit, etc. As the advice goes, don’t run your server on port 80 as sudo, but instead run behind NGINX.(modify for risk)

Re: Programs are dead, and JavaScript has killed them

#42
This is an article about ecosystems and package managers, not particularly about JavsScript, which is a scripting language around which one can chose to participate in ecosystems and use package managers. The distinction is not as subtle as one would think.

It's the same with any program.. dependencies are future liabilities. You pay for fast development now with a future burden of upgrading and incompatibility.

That's why I enjoy coming back to the software I've written with that mindset, it does not matter which language.. If I was in the supposedly wrong NIH mode when I wrote it, it still builds..

Re: Programs are dead, and JavaScript has killed them

#43

The only reliable solution to this that I have found is compiling an app into a docker container and ensuring my projects are able to run off a SQLite database. I then save this to my NAS. Otherwise literally everything will break. Running an app that I wrote only 3 years ago will blow up.

I don't understand: if you have fixed dependencies and the same Nodejs version, how can things break?

I'm not saying it's a good thing to not update your packages but you seem to imply there's another force messing with your project?

Re: Programs are dead, and JavaScript has killed them

#44
post #10

In the early 2010s, the industry was dominated by mature and stable ecosystems, such as Python/Django and Rails. Then Node came about, and when it was still extremely immature, it got a ton of attention as an army of front-end devs started to flock to it. "We are backend engineers now too!". Doesn't work that way. Node has been basically re-learning all the lessons learned a long time ago, and many lessons it didn't…

> by mature and stable ecosystems, such as Python... Nothing I experienced in the JS ecosystem so far was as nearly as painful as the over a decade-long transition from python2 to python3, and now python3 has the same 'move fast and break things' mindset. It's kinda infuriating for use cases where python2 was more than good enough.

About python past mistakes and future breaking changes, I recommend you to check this talk[0] about the topic

[0] https://www.youtube.com/watch?v=qC5Po77bfKI

Re: Programs are dead, and JavaScript has killed them

#45
post #40
post #26

I have a bit different view. If some app is not updating - there is not much use for it. Just like houses - yeah you can have 100 years old house but if you did not invest in it and expect to be just as good as new you are in world of pain. Same with cars - 10 years and you really have to change quite some parts. Applications are ideas - we expect that ideas don't "wear out" - well most of ideas wear out rather quick…

If some app is not updating - there is not much use for it. That depends entirely on the program. My CD ripper/burner is going on twenty years old and it works flawlessly. Same with my audio recorder and the sensor viewer for my phone. On the occasion I need to make a slideshow or write a document, Office 2007 works just fine with no bullshit, granted I don't view third-party files in it. ES File Explorer Pro is stil…

> My CD ripper/burner is going on twenty years old and it works flawlessly.

This is probably a good example though. The state of the art in CD ripping has advanced significantly over the last 15 years. If you care about bit-perfect rips or even just reliable error correction, it would pay to know about the advances in Exact Audio Copy (Win), XLD (Mac), or Whipper (Linux). All of these have seen releases since 2020. If you have a newer CD drive model, having an updated database in your ripping program can help you get perfect rips, as same-model drives typically have identical bit offsets. In addition, bug fixes can prevent (admittedly rare) ripping issues.

Re: Programs are dead, and JavaScript has killed them

#46
post #10

In the early 2010s, the industry was dominated by mature and stable ecosystems, such as Python/Django and Rails. Then Node came about, and when it was still extremely immature, it got a ton of attention as an army of front-end devs started to flock to it. "We are backend engineers now too!". Doesn't work that way. Node has been basically re-learning all the lessons learned a long time ago, and many lessons it didn't…

> by mature and stable ecosystems, such as Python... Nothing I experienced in the JS ecosystem so far was as nearly as painful as the over a decade-long transition from python2 to python3, and now python3 has the same 'move fast and break things' mindset. It's kinda infuriating for use cases where python2 was more than good enough.

Still to this day nothing is as painful as trying to get a pip package or ruby gem with a C dependency to build on hardware where a wheel or whatever the ruby equivalent is unlikely to exist.

Re: Programs are dead, and JavaScript has killed them

#47
post #26

I have a bit different view. If some app is not updating - there is not much use for it. Just like houses - yeah you can have 100 years old house but if you did not invest in it and expect to be just as good as new you are in world of pain. Same with cars - 10 years and you really have to change quite some parts. Applications are ideas - we expect that ideas don't "wear out" - well most of ideas wear out rather quick…

> well most of ideas wear out rather quickly and are not useful for centuries

I'm not a religious person, but already a couple thousand years ago the bible folk rightly identified that there is nothing new under the sun. Or as BNL eloquently puts it, "it's all been done before."

I don't know how we could ever quantify it or qualify it, but I would guess that most ideas stick around.

Re: Programs are dead, and JavaScript has killed them

#48
post #31

Earlier quoted context omitted.

> I gave up on building on my mac altogether osx is not linux. It has a gazillion of incompatibilities and most developers never test for it, so even if the code compiles, it's no guarantee it will work. > Try building anything Linux and C related "apt install libwhatever-dev" does it in most cases. > docker-packaged projects You mean completely insecure projects that most likely run an old and vulnerable openssl?

Yea macOS is never a guarantee but I’m always hopeful when they include Mac instructions in the readme. I’ve found projects that use C++ or other older languages and meant for Linux still have a nightmare with building. The project I looked at had a bootstrap script, an initialization script, a pip installation, and 3+ different make-alternatives. Not uncommon even when apt works. Docker is great but it’s only as sec…

> The project I looked at had a bootstrap script, an initialization script, a pip installation, and 3+ different make-alternatives. Not uncommon even when apt works.

Seems like it was created by noobs. It happens. I guess it's not packaged in a distribution for a reason. A distro maintainer would tell them to fix that crap.

> but it’s just as likely that the thing you need depends on a particular version

No it's not likely. Openssl is a shared library that you can just replace with a version that has whatever fix. Unless you do rust/golang/docker/static linking… and the standard is to dynamically link.

Running vulnerable software is always a risk. You might think you secured it, but vulnerabilities can get chained.

Anyway I'm sure there are crappy softwares being written in any language. But the problem with js seems to be that even a state of the art one incurs such problems continuously because all dependencies are crappy.

Re: Programs are dead, and JavaScript has killed them

#49
post #19

> During the past 5–6 years of my JavaScript experience, every time I wanted to go back to any of my projects—from tiny to big, server-side or front-end—there was always a challenge, a problem to tackle or an obstacle to overcome before I can update or sometimes even just run my program. why i moved mostly from writing node cmd tools to using bash. don't need to go on a bunch of side missions every time i run npm ins…

Why learn cmd and bash when you can just learn js? Easier to maintain 1 language than 1+. My software in js from 7 years ago still works.

But it's not that simple, for an example I have older personal projects as well which I'm unable to run without doing considerable changes to the code after moving to M1 chip.

Just because I'm unable to run older versions of node and thus unable to run some of the dependencies and thus need to update the dependencies and then the code etcetc.

Yes, I could use docker and containers... Yes, I could use Rosetta...

But it doesn't run natively like it did before.

But bash still works...

Re: Programs are dead, and JavaScript has killed them

#50
post #34
post #26

I have a bit different view. If some app is not updating - there is not much use for it. Just like houses - yeah you can have 100 years old house but if you did not invest in it and expect to be just as good as new you are in world of pain. Same with cars - 10 years and you really have to change quite some parts. Applications are ideas - we expect that ideas don't "wear out" - well most of ideas wear out rather quick…

Updating is fine… bash for example keeps having new versions and new features. However this doesn't mean that we must fix every bash script every 6 months because of a bash update.

That's why I stick to the POSIX shell (sh)

https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V...

Post reply on HN