HNHacker News
TopNewBestAskShowJobs

zeroimpl

614 karma · joined January 11, 2018

submissionscomments
zeroimpl··on Node.js 20.6.0 will include built-in support for .env files
If your env file is a script that you source manually, I’d call it env.sh instead.

Historically this has been my approach, but in production environments it’s convenient to have a static list of variables with no “export” instead since eg systemd’s EnvironmentFile only supports that.

zeroimpl··on Bypassing YouTube video download throttling
Most websites use JS to tell the player what to do, so the JS decides what streams to play based on asking the browser what it supports.
zeroimpl··on Lazygit Turns 5: Musings on Git, TUIs, and open source
Precisely this. Most of my coworkers seem to use a prompt that just reports what branch you are on. I use a power line-based prompt that captures a lot more info, and so I virtually never end up in a situation where I forgot to include files or forgot to push my commit since it’s super obvious.
zeroimpl··on AWS to begin charging for public IPv4 addresses
Which then requires each app to have a public IP, priced at $44/year starting soon
zeroimpl··on Are the “missing baryons” simply too hot to see?
The article was interesting but didn't explain why hot atoms would be invisible.
zeroimpl··on Microsoft Owns the Trademark for “X”
> Mark Type: Service Mark

Doesn't this just mean they own the rights to their use as a logo? Eg the stylized X on their products? I don't think this blocks anybody from using X in their products as long as the logos are clearly different.

zeroimpl··on Why SQLite does not use Git (2018)
That’s true for personal projects, which is essentially the case here. If this was a business, not so much.

I was probably too harsh in my initial message, but when I read the article and see reasoning along the lines of “git lacks a good UI for X, I hear there may be 3rd-party solutions to this problem, but then that’s too many things to install, so I’d rather build a custom solution from scratch which does everything”, it reminds me of stuff I see at work ;)

zeroimpl··on Why SQLite does not use Git (2018)
I thought they both started at the same time? Unless you are implying early versions of git were worse, which wouldn't surprise me.

I know git has a learning curve, but the only times I really see junior people have issues is when they are trying to do things that wouldn't have been easy with earlier VCS systems either. And it seems like git isn't going away, so it's worth putting the time into learning it.

zeroimpl··on Why SQLite does not use Git (2018)
Seems like a textbook example of NIH to me. By the time you understand git well enough to design a good replacement, you’re bound to be an expert and ought to appreciate more the design of git.

If you don’t like the lack of a good GUI or web application, you can just build one that works the way you want and still works with git.

zeroimpl··on The controller pattern is awful, and other OO heresy (2013)
Which is what’s great about these languages - best of both worlds.

I also think this discussion shouldn’t be about languages at all, you can have objects of some form in any imperative language including C. It’s more about what design patterns make sense for specific problems, and sometimes the answer is OO-style (eg with class hierarchies) and sometimes not.

zeroimpl··on Defining a new HTTP method: HTTP Search (2021)
TIL sending a POST request to a URL invalidates the cache for GET requests of the same URL.

Going to have to review my REST APIs to make sure that’s not a problem.

zeroimpl··on Go with PHP
Comments can also be accessed at runtime :)
zeroimpl··on 5G Rollout Disappointments
Am I charged less for that data transfer when it’s 5G? To me the important consideration is the cost of the data. 1Gbps seems pointless if the cost is still $10+/GB.
zeroimpl··on The part of Postgres we hate the most: Multi-version concurrency control
> Oracle and MySQL do not have this problem in their MVCC implementation because their secondary indexes do not store the physical addresses of new versions. Instead, they store a logical identifier (e.g., tuple id, primary key) that the DBMS then uses to look up the current version’s physical address.

This doesn’t have anything to do with MVCC. I’m sure PostgreSQL could implement an index format that piggybacks on another index rather than pointing at the physical page directly, without overhauling MVCC.

zeroimpl··on Ways to shoot yourself in the foot with Postgres
I’m fully against using triggers to implement business logic, but find stored procedures can be great for encapsulating some elements of application/business logic. I’ve got several applications that access the same databases, and putting logic in the database avoids needing to duplicate it in clients.

Most comments about debugability are nonsense. It’s just different, with some pros and cons. One simple example - if you have a bug in production, you’re not going to attach a debugger to your production application. But you can absolutely open a readonly connection to the database and start running queries, invoking functions, etc. It helps if you can architect your functions to distinguish pure readonly functions from those with side effects, but you can still debug even if that’s not the case.

zeroimpl··on Most of my skills are now worth nothing, but 10% are worth 1000x
I know it sometimes feels easier to just implement something than file a JIRA ticket with enough detail to describe what needs to be done.
zeroimpl··on Irregular Expressions
Ah I thought they meant flipping the finality of the final state, but I guess they said "states" so your interpretation makes more sense.
zeroimpl··on Irregular Expressions
That example doesn’t really fit since one easily could compute the negation of “a|(aa)+” in linear time by simply returning the opposite of the top-level node in the tree.

Perhaps something like “X|!Y” or similar might be impossible?

zeroimpl··on Safari's date-picker is the cause of 1/3 of our customer support issues
I didn’t even know <input type="date"> was a thing, I rely on JS datepicker libraries in various places. However there’s usually plenty of configuration that goes along with that, so I’m not surprised it isn’t optimal in all cases.
zeroimpl··on Netflix: 30% bitrate saving using Film Grain Synthesis
I know it’s referred to as film grain, but digital cameras also have grain, and the amount of grain will vary from shot to shot depending on lighting, shutter speed etc.

Adding extra fake noise to the movie solves a few problems such as ensuring a consistent look from scene to scene, as well as avoiding video artifacts like banding.

It’s also an artistic choice just like the choice to use telephoto lenses that blur backgrounds into fuzzy balls of light.

zeroimpl··on Apple announces ‘upgrade’ to App Store pricing, adding 700 new price points
I’m confused because this is how it already worked. Unlike regular purchases, subscription pricing was always managed by choosing a price in one territory, letting it recommend prices for all the other territories (based on the exchange rate at that date) and giving you the option to make final adjustments. The prices never adjust for exchange rates afterwards unless you re-run the process manually. This was required because fluctuating prices are bad for subscriptions as customers get locked in.

So I don’t understand what’s different here.

zeroimpl··on A friendly introduction to the Friendship Paradox (2021)
How would the results differ if you looked at median instead of average? It seems like median would probably be about the same in many cases, when talking about # of friends.
zeroimpl··on I have 218 browser tabs open
Wow just realized Firefox has this feature built-in but not enabled by default! Just needed to turn on "Ctrl+Tab cycles through tabs in recently used order".
zeroimpl··on I have 218 browser tabs open
The author mentioned the vimium addon with the ability to quickly flip back to the previous tab. This makes me want something similar to the recently-used-tab selector in VSCode - pressing ctrl-tab pops-up a list of recently used tabs in reverse-chronological order and makes it super easy to flip back and forth. I wonder if there's any browser extension like this?
← PreviousPage 3 of 8Next →