Earlier quoted context omitted.
To play devil's advocate, had OP not wanted to go home so badly Parkinson's Law would've kicked in and OP may have tried to do things the "right way" which may have taken much longer.
Any ideas on what the "right way" would be in this case? To me the solution seems the most straightforward.
Ask HN: What's your "it's not stupid if it works" story?
361–370 of 510 posts
Re: Ask HN: What's your "it's not stupid if it works" story?
#362I built a writing/formatting product now used by 60k+ indie authors. One of the requirements was to format PDFs for print publishing with different themes and configurable layouts. Instead of building a custom PDF rendering engine, I decided to use Puppeteer to generate the PDFs. But there were a bunch of issues we had to deal with: - To render the gutter (margin in the middle) you had to know which side of the book…
Re: Ask HN: What's your "it's not stupid if it works" story?
#363In the early days of Google Chrome, I was tasked with making it work with Windows screen readers. Now, accessibility APIs on Windows were documented, but web browsers used a bunch of additional APIs that were poorly documented. Chrome's design was radically different than Firefox's and IE's, so it was a challenge to implement the APIs correctly. At first I was just trying to get it to work with completely static web…
Re: Ask HN: What's your "it's not stupid if it works" story?
#364Re: Ask HN: What's your "it's not stupid if it works" story?
#365Earlier quoted context omitted.
I've always wanted a Smalltalk VM that did this. Eternally persistent VM, without having to "save". It just "lives". Go ahead, map a 10GB or 100GB file to the VM and go at it. Imagine your entire email history (everyone seems to have large email histories) in the "email array", all as ST objects. Just as an example. Is that "good"? I dunno. But, simply, there is no impedance mismatch. There's no persistence layer, yo…
Isn’t that sort of the original idea for how Forth would work? Everything is just one big memory space and you do whatever you need? I’m going from very hazy memory here.
I also think that what gp is looking for is Scratch. IIRC it's a complete graphical Smalltalk environment where everything is saved in one big image file. You change some function, it stays changed.
Re: Ask HN: What's your "it's not stupid if it works" story?
#366For whatever reason there was an issue no-one could figure out where if either of two networked computers, attached to printers, couldn't communicate (e.g. ping each other) then the printing from the local machine itself would stop working.
I wrote a small Erlang application which would monitor an Erlang pid on the other computer and restart the network interface in case it ever lost contact, which generally made things work again.
Obviously many ways to solve (such as figuring out why it behaved like that in the first place!!) but I was learning Erlang at the time and it seemed a neat way to do it.
Re: Ask HN: What's your "it's not stupid if it works" story?
#367Re: Ask HN: What's your "it's not stupid if it works" story?
#368Earlier quoted context omitted.
Using CGI protocol on a Windows server. IIS (Windows' own web server) basically interfaces with executables by running them, feeding them HTTP headers, and server variables through environment variables, and gets the response HTTP headers and the body from their STDOUT. It's very inefficient, of course, since every request requires spawning a new copy of the executable, but it had worked fine in its first months :) H…
Don't sell yourself too short here, that's exactly how Perl/PHP works and that was defacto standard around the same vintage (and for a decade more).
That said, FastCGI and similar technologies were inevitable and something like PHP-FPM isn't much more difficult to actually run in practice.
Still, having a clearly defined request lifecycle in wonderful, especially when compared to something how Java application servers like Tomcat/Glassfish used to work with Servlets - things there have gotten better and easier too, but still...
Re: Ask HN: What's your "it's not stupid if it works" story?
#369I worked at a startup where the core backend was 1 giant serverless Function. For error handling and recovery, the Function ran in a while loop. For all its faults, it worked and it was generating revenue. Enough that the startup got to a sizable Series A. That experience completely changed how I think about writing code at startups.
this is great. if you look at older game source code you find things like this. things that we view as horrible hacks which are both extremely stable and perform well. i see no reason to stop using these types of solutions, when appropriate.
Re: Ask HN: What's your "it's not stupid if it works" story?
#370This came about because there wasn't any database on the server and sqlite hadn't come about.
This solution worked quite well for more than 20 years. The file grew to host hundreds of thousands or orders.
My only regret is that I should have charged more. The ROI is unbelievable, the amount I charged is a rounding error. The thing got replaced when the original owner passed away.