HNHacker News
TopNewBestAskShowJobs

davidjfelix

640 karma · joined June 28, 2019

submissionscomments
davidjfelix··on Show HN: Scan QR codes to check in guests registered via Google Forms
4th link to blog has a link to homepage. Homepage lists country in the footer.
davidjfelix··on Rethinking serverless with FLAME
> This is exactly my point. You bolt on ever more Serverless offerings to accomplish any actual goal of your application. SNS notifications is exactly the kind of thing I don't want to think about, code around, and pay for. I have Phoenix.PubSub.broadcast and I continue shipping features. It's already running on all my nodes and I pay nothing for it because it's already baked into the price of what I'm running – my app.

I think this is fine if and only if you have an application that can subscribe to PubSub.broadcast. The problem is that not everything is Elixir/Erlang or even the same language internally to the org that runs it. The solution (unfortunately) seems to be reinventing everything that made Erlang good but for many general purpose languages at once.

I see this more as a mechanism to signal the runtime (combination of fly machines and erlang nodes running on those machines) you'd like to scale out for some scoped duration, but I'm not convinced that this needs to be initiated from inside the runtime for erlang in most cases -- why couldn't something like this be achieved externally noticing the a high watermark of usage and adding nodes, much like a kubernetes horizontal pod autoscaler?

Is there something specific about CPU bound tasks that makes this hard for erlang that I'm missing?

Also, not trying to be combative -- I love Phoenix framework and the work y'all are doing at fly, especially you Chis, just wondering if/how this abstraction leaves the walls of Elixir/Erlang which already has it significantly better than the rest of us for distributed abstractions.

davidjfelix··on Rethinking serverless with FLAME
This is a very neat approach and I agree with the premise that we need a framework that unifies some of the architecture of cloud - shuttle.rs has some thoughts here. I do take issue with this framing:

- Trigger the lambda via HTTP endpoint, S3, or API gateway ($)

  * Pretending that starting a fly machine doesn't cost the same as triggering via s3 seems disingenuous.
- Write the bespoke lambda to transcode the video ($)

  * In go this would be about as difficult as flame -- you'd have to build a different entrypoint that would be 1 line of code but it could be the same codebase. Node it would depend on bundling but in theory you could do the same -- it's just a promise that takes an S3 event, that doesn't seem much different.
- Place the thumbnail results into SQS ($)

  * I wouldn't do this at all. There's no reason the results need to be queued. Put them in a deterministically named s3 bucket where they'll live and be served from. Period.
- Write the SQS consumer in our app (dev $)

  * Again -- this is totally unnecessary. Your application *should forget* it dispatched work. That's the point of dispatching it. If you need subscribers to notice it or do some additional work I'd do it differently rather than chaining lambdas.
- Persist to DB and figure out how to get events back to active subscribers that may well be connected to other instances than the SQS consumer (dev $)

  * Your lambda really should be doing the DB work not your main application. If you've got subscribers waiting to be informed the lambda can fire an SNS notification and all subscribed applications will see "job 1234 complete"
So really the issue is:

* s3 is our image database

* our app needs to deploy an s3 hook for lambda

* our codebase needs to deploy that lambda

* we might need to listen to SNS

which is still some complexity, but it's not the same and it's not using the wrong technology like some chain of SQS nonsense.

davidjfelix··on AI chemist could make oxygen on Mars
Can Mars hold onto atmosphere? I was under the impression that the general consensus was Mars lost its atmosphere when it lost its magnetic field.
davidjfelix··on Technology holy wars are coordination problems (2020)
My opinion is there were 2 major issues and a bunch of minor cuts.

The major issues (imo):

* Reliance on extending the runtime via the C-bindings (and that changing)

* A community that had largely gotten accustomed to stability being thrust into an enormous change all at once

I think people tend to be in a camp of either "this was good and needed to happen because python had unshakable warts" or "this was bad and we should have lived with language mistakes forever". I think both of those camps conflicting is really what made it really painful - breaking changes were held for years and then once one got in they all came. I think the reality is that coming up with a migration plan incrementally working towards it would give developers more time to focus on one upgrade rather than a full rewrite. Node gets a bad reputation for being "chaotic" or "constantly changing" but the changes are small and manageable comparatively. Go on the other hand has managed to maintain strong stability, but with an ecosystem that's working primarily in the core language rather than the implementation language (C for python).

I think the python 3 merge did a ton of damage to the community's willingness to encourage breaking changes that are needed and it's why packaging and runtime self hosting have been comparatively weak despite a huge userbase.

Not breaking apis is a great ideal but if you have to, breaking them in planned, bite-sized, frequent bursts is often MUCH MUCH better than once a decade.

davidjfelix··on From S3 to R2: An economic opportunity
FWIW, Vercel is at least partially backed by cloudflare services under the hood.
davidjfelix··on Htmx, Rust and Shuttle: A New Rapid Prototyping Stack
Not really an htmx user or supporter but as an outside observer I think this can be accomplished but it might not be what you want -- which is okay.

So, if I understand correctly, I think what you're saying is you "create a post" and the timestamp might have "now" listed as a humanized representation of it being just posted. When it reaches 1 minute, what you're saying is you'd like it to say "1 minute ago" etc. I think this is generally against the goals of htmx and the way you'd accomplish this is one of two ways:

* Find a humanized representation that does not need constant updating

* Use ordinary clientside javascript alongside htmx rendered data attributes to update the output.

I don't think htmx aims to do loads of rerender cycle updates like this. I don't think that means its not a good library, just not a good fit for sites that need this. There are plenty of tools like django templates, rails templates, hugo sites etc that all act like this and require some hand-authored clientside js to handle updates. I think the goal of htmx is to require *as few as possible* without overtly adding js to clientside runtimes.

davidjfelix··on Singapore: Right to own a car costs $76,000. And that doesn't include the car
I think if you find money laundering and tax evasion schemes to be scummy you might want to look closer at the migrant work force that helped build that utopian dream city and ask important questions like:

* How do they afford such an expensive city?

* Where do they go when the work is done?

* Why don't they get the same rights as citizens?

* If the city needs them so badly and has such a hard time finding work, why aren't they allowing migrants a more permanent residency that isn't tied to a specific company?

* Why are companies and the government restricting migrant movement?

* Why do companies (sometimes) charge their migrant workers for the right to work?

* Why do companies (sometimes) withhold the passports of their workers?

* Why does the government punish overstaying a visa with caning?

I think there are a lot of parallels to western wealth disparity but there's still a lot of grossness to the systemic human labor trafficking that is the backbone of the country.

davidjfelix··on Singapore: Right to own a car costs $76,000. And that doesn't include the car
I feel like Singapore is also largely a country for the rich, perhaps just larger -- they import something like 30-40% of their workers as migrant workers.
davidjfelix··on Extracting Hacker News book recommendations with the ChatGPT API
I thought this was pretty odd too but it does tend to find its way onto aggregated HN book lists (linked throughout the comments) a lot. My theory is that the short name combined with it's rather divisive content leads to people arguing about it by name which boosts these "per mention" metrics.

For example: take a look at some of the comments here https://hacker-recommended-books.vercel.app/category/0/all-t... while there are some recommendations (I expect this) there are also quite a lot of people using the book as a way to deride purveyors of its ideology.

I think what we're both experiencing here is an expectation that this list will be GOOD recommendations, but the methodology is popular mentions, which happen to contain some people's (subjective) GOOD recommendations but also peoples (subjective) BAD popular mentions.

davidjfelix··on Why has a useless cold medication been allowed on shelves for years?
Well, Americans would call it acetaminophen or just Tylenol and I'd be careful with "pills" as dosage isn't consistent among the pills and that could be a lot. In the US, many pseudoephedrine pills come with 500mg acetaminophen. Typically they're marketed as "cold & sinus" (Tylenol Cold & Sinus is the brand I know). I've heard people say that the addition of acetaminophen is dual-purpose; one is that it generally helps with symptoms and the other is that it makes it harder for meth producers to isolate the pseudoephedrine without adding a lethal dose of acetaminophen. This is all mostly hearsay.
davidjfelix··on Backward Compatibility, Go 1.21, and Go 2
https://docs.aws.amazon.com/lambda/latest/dg/invocation-retr... Lambda retry docs. I still would strongly not advice intentionally disabling the GC and explicitly said not to above for the same reasons you're concerned.
davidjfelix··on Backward Compatibility, Go 1.21, and Go 2
Do not do this in AWS lambda or OpenFaas. Lambda processes are reused in "warm" invocations and are only short lived in cold, infrequent use cases (read: once every > 45 minutes). This is useful when the process dies at the end of every request (in which case you're relying on the OS to do the GC for you).
davidjfelix··on When an app asks for permissions, it should have a “feed fake data” option
I think you're selectively ignoring parts of the comment. "Darwinian opportunity ... [which is] self-solving" is clearly referring to the death of a person who blindly followed GPS directions for a mis-configured app. GP was saying that anyone who dies because an app told them wrong information was not "fit" (darwinian fitness) for survival. Expressing no remorse or desire to prevent preventable death with the justification that it's allowing the species to become more fit is eugenics.
davidjfelix··on When an app asks for permissions, it should have a “feed fake data” option
That feeling when hacker news user endorses eugenics as long as its just stupid people.
davidjfelix··on Microwaved plastic containers release microplastics into food
I think it's worth noting that the seasoning, while still a plastic and an oxidized oil and not necessarily good for you (probably bad or neutral), is not necessarily the same levels of bad for you that PFAS like teflon are when ingested. PFAS are called "forever chemicals" because they've been observed in our blood stream and don't naturally break down.
davidjfelix··on Type-safe, K-sortable, globally unique identifier inspired by Stripe IDs
So you don't have to create an additional index to scan them in a somewhat sensible order. createdAt just happens to be a naturally decent scan order.
davidjfelix··on Type-safe, K-sortable, globally unique identifier inspired by Stripe IDs
Yep. The whole point is that you /never/ assign ids that begin with "user" to types that are not users. Because of that, you can be sure nobody can accidentally copy an id that begins with "user" when meaning to address a different type and get back a result other than "not found".

Example:

I have userId=4 and userId=2. Suppose a user can have multiple bank accounts and userId=4 has accountId=5 and accountId=6 and a defaultAccound accountId=5. userId=2 has an account, accountId=7; I want to send userId=4 some money so I use the function `sendUserMoneyFromAccount(to: int, from: int)`. This is a bad interface but these things exist in the wild a lot. I could accidentally assume that because I want to send userId=4 the money to their default account that I would call it using `sendUserMoneyFromAccount(4, 7)` and that would work, but if under the hood it wants 2 accountIds, I've just sent accountId=4 money rather than userId=4's defaultAccount, accountId=5.

With prefixed ids that indicate type, a function that assumes type differently from the one supplied will not accidentally succeed.

In addition, humans who copy ids will be less likely to mistake them. This is just an ergonomic/human centric typing.

davidjfelix··on GCC Adopts a Code of Conduct
So I think I hear you but it's hard for me to really grasp what you're trying to say because you're not using specifics. I'm not sure if that's an attempt to protect yourself from backlash, but as somebody who doesn't see the same thing as you, these are some things that I feel the need to clarify:

* "the majority of coc documents" - this feels unquantifiable, but maybe you mean a particular template? Could you point me to one that you take issue with?

* "one particular in-group of people who share extremist beliefs" - which group? Is it the same group for all of the communities or one group per community? Could you help me with an example? Which extremist beliefs? Again, is this per-community or one group with one set of beliefs?

With these concrete examples, what do you personally think could be done by these communities to make would-be well-intentioned-codes more like their abstract, theoretical tool?

davidjfelix··on GCC Adopts a Code of Conduct
I think unfortunately this has become something of a lightning rod with culture war topics of late. I'd really encourage people to read the article. CoCs are not all the same and it's hard to codify expectations of a group that already exists because it requires consensus or severance. Many codes of conduct lay out unenforceable or questionable rules and this is not one of them. I read in the comments somebody claiming they were trying to eliminate using any project with a CoC like they were fighting against a spreading disease. It's zealotry and I urge you, if you consider yourself skeptical -- be skeptical of your own positions too because GCC's CoC FTA says nothing that has been expressed as something folks here are afraid of.
davidjfelix··on GCC Adopts a Code of Conduct
There's an awful lot of straw man accusations going on in this thread from people who seem to feel threatened by some invisible person who is going to persecute them for something they believe or say or are as a person. Even just an ounce of empathy and you'd realize that's possible without a CoC too and the goal of establishing these boundaries is to protect the people who feel that same way daily because of who they are. If you feel more attacked than protected, it might be time to look inwards instead of accusing outwards.
davidjfelix··on 3 Men Convicted of Harassing Family on Behalf of China’s Government
I feel like you're really downplaying how impactful credit score is and how dystopian it is. They rebranded fraud against the lender as "identity theft" against you so that they could sell your fraudulent debt to private harassment firms. In turn since identity theft isn't real (fraud is) you need to get the lender to file a police report and unseal their private financial records (they won't do this). All this while you experience real damages like being rejected by mainstream lenders, swaths of employment and housing opportunities and pushed towards fringe and predatory lenders.

That being said, I also think you're not accurately describing social credit or relying entirely on hearsay. For the most part its focused around credit worthiness and financial fraud. I'm not a huge fan of either system, but as somebody who's worked with people harmed by the US private credit system, I can tell you that it's possible to "Nosedive" here and that's not just what I've heard.

davidjfelix··on ES Modules Are Terrible
I don't think it's hyperbole -- I think the changes are often as large and collectively more significant than 2-to-3, but the ecosystem is better at change. Even with that there are clearly factions and currents in different directions, but things generally work.
davidjfelix··on Show HN: Accelerated Docker builds on your local machine with Depot (YC W23)
Awesome work!
davidjfelix··on Some employers have decided to build their own housing for workers
Regardless of whether or not it's a legal requirement of the board, I think even this confusion on the matter is evidence that not enough protection is in place for long term longevity or worker benefit in normal corporate bylaws. With LLCs you can offer bylaws, with PBCs you can offer a benefit charter, with LCAs you can offer direct worker ownership; there are other corporate entities besides C corps which can offer better protection that is more explicit and less prone to financial debate - that's my point.
davidjfelix··on Some employers have decided to build their own housing for workers
Aside: Many HN readers may remember that Basecamp's drama from 2 years ago [1] made mention of "paternalism" and how they planned to end the practice within their benefit structure. I recall the phrasing to be a source of confusion and argument. I think there were still a lot of folks (myself included) who saw this as a form of societal absenteeism in an economy with challenges that are often not easily overcome with simply more money at an individual level. I do, however, think this is a dicey area where companies can spend more efficiently on some paternalistic benefits rather than flatly increasing salary (which may have fewer tax incentives). This needs to be balanced with the fact that US corporations are not legally incentivized to maximize employee happiness, they're incentivized to maximize profit and without a legal entity around worker benefit, this form of paternalism can feel cheap or dystopian with callbacks to "company stores" and jumping through hoops and checking boxes to maximize your salary.

[1]: https://world.hey.com/jason/changes-at-basecamp-7f32afc5o

davidjfelix··on QEMU 8.0
That makes more sense.
davidjfelix··on QEMU 8.0
My interpretation of this:

You have an x86 machine running Linux v5.12 which is running QEMU using KVM accelerations. Using this setup, you're able to emulate a machine that can run Xen. Since Xen is a type 1 hypervisor, you would then run a Dom0 and perhaps many DomU machines inside it, let's say Linux here for both.

Hardware > Linux KVM > QEMU > Xen guest > Linux Dom0 guest, Linux DomU guest

davidjfelix··on C Rival 'Zig' Cracks Tiobe Index Top 50
"'Zig' Cracks Tiobe Index Top 50"

(it was #46)

davidjfelix··on How does database sharding work?
I think that AWS DocumentDB uses the last mongodb version that wasn't their new(ish) SSPL license and any compatibility beyond that was "clean room" backported. Its possible Azure is in a similar place.
← PreviousPage 2 of 6Next →