MurphyA/hacker-news huggingface dataset:
Ask HN: Could Go become a first class web citizen?
by 90s_dev | 2025-04-19 23:45:15+00:00
I haven't touched Go in about 10 or 15 years, but with the recent announcement from the TypeScript team, I started to look into it more again, and it seems most of the issues I had with it have since been fixed. And one of the key takeaways from that announcement for me was that status quo Go is about 10x faster than the most optimizable JS you could write.

This got me thinking, Anders and the TS team are probably going to offer upstream some significant contributions to the Go toolchain and language (for their own sake of course, but it benefits everyone) and Go will get even faster and evolve a better type system. And the gap between clean JavaScript and vanilla Go is likely to get smaller and smaller, in terms of semantics. (I just learned a week ago that there's a struct proposal for JS.)

How do you see this going over the next 15 years? I wondered about 10 years ago if TypeScript would ever become part of JS, and that's starting to come true with the type-annotations proposal. Is it possible that the bridge between JS and Go will just shrink? That JS will evolve into Go? That WASM's ergonomics will evolve to make third party languages more "naturalized" citizens, with almost nothing getting between an e.g. Go module and a JS module or differentiating them except the file extension?

What do you all think?
by bobthepanda | 2025-04-19 23:45:25+00:00
I mean there are many reasons that people say that TikTok is bad.

If you think TikTok is bad because it promotes unhelpful or malicious advice around body standards, that's one thing. (See: bigorexia getting promoted into the DSM)

If you think TikTok is bad because it puts children under a lens, that's another thing.

If you think TikTok is bad because it exposes contrarian viewpoints that are not available on your television, like, say, something Gaza related, then that's yet another thing.
by jasonlotito | 2025-04-19 23:46:13+00:00
> The tragedy of the modern library is that no one has the attention span for old books.

Fixed that to mean what you say.

Luckily, people still have the attention for good books. Which is why libraries still stock good books, classic or otherwise. They also stock books that people want to read. Which might seem odd until you realize that libraries are there for the community to use.

However, you are free to setup a library that stores books that no one reads.
by KronisLV | 2025-04-19 23:46:38+00:00
> Dependency injection is just passing your dependencies in as constructor arguments rather than as hidden dependencies that the class itself creates and manages.

This is all well and good, but you also need a bunch of code that handles resolving those dependencies, which oftentimes ends up being complex and hard to debug and will also cause runtime errors instead of compile time errors, which I find to be more or less unacceptable.

Edit: to elaborate on this, I’ve seen DI frameworks not be used in “enterprise” projects a grand total of zero times. I’ve done DI directly in personal projects and it was fine, but in most cases you don’t get to make that choice.

Just last week, when working on a Java project that’s been around for a decade or so, there were issues after migrating it from Spring to Spring Boot - when compiled through the IDE and with the configuration to allow lazy dependency resolution it would work (too many circular dependencies to change the code instead), but when built within a container by Maven that same exact code and configuration would no longer work and injection would fail.

I’m hoping it’s not one of those weird JDK platform bugs but rather an issue with how the codebase is compiled during the container image build, but the issue is mind boggling. More fun, if you take the .jar that’s built in the IDE and put it in the container, then everything works, otherwise it doesn’t. No compilation warnings, most of the startup is fine, but if you build it in the container, you get a DI runtime error about no lazy resolution being enabled even if you hardcode the setting to be on in Java code: https://docs.spring.io/spring-boot/api/kotlin/spring-boot-pr...

I’ve also seen similar issues before containers, where locally it would run on Jetty and use Tomcat on server environments, leading to everything compiling and working locally but throwing injection errors on the server.

What’s more, it’s not like you can (easily) put a breakpoint on whatever is trying to inject the dependencies - after years of Java and Spring I grow more and more convinced that anything that doesn’t generate code that you can inspect directly (e.g. how you can look at a generated MapStruct mapper implementation) is somewhat user hostile and will complicate things. At least modern Spring Boot is good in that more of the configuration is just code, because otherwise good luck debugging why some XML configuration is acting weird.

In other words, DI can make things more messy due to a bunch of technical factors around how it’s implemented (also good luck reading those stack traces), albeit even in the case of Java something like Dagger feels more sane https://dagger.dev/ despite never really catching on.

Of course, one could say that circular dependencies or configuration issues are project specific, but given enough time and projects you will almost inevitably get those sorts of headaches. So while the theory of DI is nice, you can’t just have the theory without practice.
by Spooky23 | 2025-04-19 23:46:45+00:00
Like I said, the problems hide in the averages. You don’t interview average high school graduates to work your shitty job in nowhereville - you’re talking to the 25th percentile for the most part. The 25th percentile Florida, Oklahoma or Arizona 8th grader performs 30% worse that his peer in New York or Massachusetts. I can assure you that NY and MA aren’t some paradise of educational achievement.

The people able to gtfo an emigrate from many places are usually the smarter people. The 75th percentile Filipino probably went to a Catholic school and had a better education than many US districts.

I’m sorry this upsets you, and I assure you I share your anger and disgust.
by ayuhito | 2025-04-19 23:46:52+00:00
I think it depends.

Where I used to live in the Middle East, the culture was very tea (more specifically karak) centric for sure. But it wasn’t a hobby you get so deep into that you become very specific for the average person.

You just drive to your regular place. There’s only one choice and that’s karak. You sip it in your car, chat with your buddies, and you drive off.

Definitely do miss the late nights there. No alcohol, just tea and still an extremely social society.
by maxander | 2025-04-19 23:48:01+00:00
The interesting thing about this blog post isn’t the point it makes (which was endlessly made about cafes in all blue-state U.S. cities in the 00s) but that it’s an Iranian writing in English, and thus for an Western audience, about Iranian culture.

What is going on with that? I don’t even dare to speculate. But something more interesting than bougie coffeeshops, certainly.
by phkahler | 2025-04-19 23:49:40+00:00
"As the electrodynamic force, i.e. the Lorentz force can be related directly to the metrical structure of spacetime, it directly leads to the explanation of the Zitterbewegung phenomenon and quantum mechanical waves as well."

Cool because traditional QM wave function waves are not electromagnetic waves even though they seem to be the same thing in a double slit experiment.
by _DeadFred_ | 2025-04-19 23:50:06+00:00
I don't think people think through to the end enough. Lidar can't be tricked as easily. If Tesla were to attract a group of malicious actors that hated Tesla I wouldn't put it past those actors to figure out ways to confuse Tesla's non-lidar self driving to make it frustrating to Tesla owners but more specifically to cause financial impact on a self driving taxi fleet that wouldn't be possible with Lidar.

Has Tesla accounted for malicious actors trying to sabotage it's vision choice and not just plain jane driving scenarios?

I think at scale and once rolled out malicious actors are going to be one of the number one economic impacts of self driving taxi economics.
by antasvara | 2025-04-19 23:50:44+00:00
Just out of curiosity, is there nothing that you have preferences about? Because I think it's easy to look at someone else's hobby and reflexively say that they're overpaying for something.

For example, I can't personally fathom paying 4k for a gaming PC. 60 vs 40 frames per second doesn't "matter" to me in any meaningful sense.

That being said, I totally get why other people care. If gaming is the thing you really enjoy, I can see why you might want the faster framerate. If you exclusively play super demanding games, I can see wanting decreased loading times and better graphics.

I guess the point I'm making is it's totally fine to drink your Folgers and be fine with that. I do also think that there are "overpriced" coffee places that aren't offering meaningfully better quality and are surviving based on branding. But I think it's okay to spend more for things that you like more. If might be "just a cup of coffee" to you, but reflect and consider what your "cup of coffee" is.

In my opinion, life is more fun when we can enjoy the variety that it has to offer and let others do the same.
by immibis | 2025-04-19 23:51:32+00:00
1. Creating a programming language from scratch isn't hard.

2. It's also worthless.

3. arXiv is for scientific papers and not just random PDFs or project reports.

4. Creating a programming language can be science but something tells me that yours isn't.

I've seen solutions to the halting problem published on something called ResearchGate. I don't know anything about it but maybe you can upload there. Or just use your website or Google Drive, like how a normal person shares PDFs.
by nsoonhui | 2025-04-19 23:51:59+00:00
Forgive my ignorance but isn't this proven to be a dead end? There is this Kaluza Klein theory that proposes EM as the fifth dimension that has been ruled out, and Einstein spent large part of his later years trying to integrate EM into the GR geometric framework, with no success, mainly because he didn't know about strong and weak nuclear force as the other two fundamental force besides EM and gravity.
by pvg | 2025-04-19 23:52:31+00:00
McVeigh knew exactly what he was doing. From a recent book on him and the bombing:

“Mike and Lori knew all the details of the plan, and they never discouraged McVeigh, even when he said during this visit that the death toll might include women and children. As McVeigh later recounted to Jones, “I told them, ‘Children may die. There may be a pregnant woman working there, or there may be someone walking down the street, or someone may have taken their child to work with them. Do you understand that?’ And Mike said, ‘Yeah, I know, it’s part of life.”
by LegionMammal978 | 2025-04-19 23:52:52+00:00
You can get another 56% speedup on the reserve()+emplace_back() version just by replacing (Widget widget) with (const Widget& widget) in the function declaration [0], more of a difference than any of the loops. As well as a further 39% speedup by moving transformed_data into repsonse.data instead of copying it [1]. My takeaway is that C++ makes it extremely easy to copy data around unnecessarily. Also, you should always profile your code for easy wins before making drastic changes.

[0] https://quick-bench.com/q/1Lcfho3hZW2DVgse3xkn82hZsFg

[1] https://quick-bench.com/q/r0DxLEPK68VhBPect3qAhkNIVnA
by cavisne | 2025-04-19 23:52:59+00:00
"An H100 GPU has 989 TFLOPs of half-precision matrix multiply compute, and ~60 TFLOPs of “everything else”"

I always thought there was a lot of crossover between gaming GPU's & DC GPU's (and the volume is why NVIDIA is so far ahead). Are tensor cores somehow related to the pre tensorcore SM's (like an abstraction on top of SM's?)
by rayiner | 2025-04-19 23:53:30+00:00
> Suggesting uneducated immigrants are a major problem

@JumpCrisscross said uneducated Americans are a problem. If that’s true, then immigration must really be a problem, because most of it is from countries with much worse education. If you think “uneducated” people are a problem, then own that. Don’t hide behind this “punch up versus punch down” bullshit where it’s okay to call Americans uneducated but not people who are objectively more uneducated than Americans.

Look at the PISA scores I posted up thread. The U.S. performs around the same as Sweden. It’s not hanging with the very top, but it does fine compared to big western countries. And it vastly outperforms every Latin American country.
by grg0 | 2025-04-19 23:53:33+00:00
So what exactly is the difference? Hard to parse the assembly with so many C++-isms, but I'm gonna guess that while the raw loop version is able to std::move transformed_data into response.data, the views version must traverse the view and copy the dumb way. There are some delete calls in the latter version that don't appear in the first one. I think a fairer comparison would be to not store a std::vector<ToData> in Response in the view version, but store the actual view. After all, the only reason there is a vector there to begin with is that the raw-loop version needed somewhere to store the result.
by memling | 2025-04-19 23:53:54+00:00
> Why would you need a support SLA for ASN.1 and not for PB/FB? That makes no sense. And there's plenty of open source ASN.1 tooling now -- just look around this thread!

If your business depends on five nines plus of reliability in your 5g communications stack, you might be willing to fork over the price for it. Or if you need a bug fix made in a timely fashion to the compiker or runtime, likewise. As I've noted above, a client of mine moved to a commercial suite of tools for this reason.

Protobuf and flatbuffers have different use cases in my experience, although that's somewhat limited. Protobuf at least also introduced breaking changes between versions 2 and 3. ASN.1 isn't perfect in this regard, but these days incompatibikities have to go through ISO or ITU, etc.

Your experience may be different of course. I'm just pointing out that there are reasons people will opt for a commercial product.
by mattbee | 2025-04-19 23:56:16+00:00
The author's pull requests sound exhausting! Opening a PRs to accommodate a "pet peeve" is a mark of inexperience. Does it solve a problem or fix a bug? Doesn't look like it. It doesn't even obviously improve performance. I just see a gratuitously new abstraction that will decrease readability for the rest of the team.

As a team you're going to drown in C++ if you let everyone add their favourite coding conventions, standards or libraries to the code - it's the worst language for that sort of sprawl.
by fragmede | 2025-04-19 23:56:21+00:00
Let's say that this metaphorical LLM chef never discovers or independently invents sous vide as a cooking technique, but they're able to whip up simply the most amazing desserts and the most wonderful air fluffed omelettes. Sure we can make fun of them, like a teenage boy making fun of the kid who's parents didn't let them take sex ed so now they don't know how pregnancy works, but if that LLM chef's desserts sell out when given a kitchen, is their lack of a sous vide technique really that much of an indightment that we should not only not let them into the kitchen in the first place, but also trample all over them, denigrate the people working on them, spit on it as being all hype, and walk away from it all? I'm not saying anyone should want to work at OpenAI, but the haters are worse than the hype men. If you don't want to give them money, don't.
by xelxebar | 2025-04-19 23:56:39+00:00
My YAML loader[0] is where I first broke through the wall. It's still languishing in a relatively proof-of-concept state but does exhibit the basic design principles.

There's also a Metamath verifier that does parallel proof verification on the GPU. It's unpublished right now because the whole thing is just a handful of handwritten code in my notebook at the moment. Hoping to get this out this month, actually.

A DOOM port is bouncing around in my notes as well as a way to explore asynchronous APL.

I'm also helping Aaron Hsu in his APL compiler[1] for stuff adjacent to my professional work, which I can't comment on much, unfortunately.

Et hoc genus omne

[0]:https://github.com/xelxebar/dayaml

[1]:https://github.com/Co-dfns/Co-dfns
by matheusmoreira | 2025-04-19 23:57:25+00:00
> What hardware, though?

Good question. There seems to be no way to tell whether or not we're gonna get junk when we buy hard drives. Manufacturers got caught putting SMR into NAS drives. Even if you deeply research things before buying, everything could change tomorrow.

Why is this so hard? Why can't we have a CMR drive that just works? That we can expect to last for 10 years? That properly reports I/O errors to the OS?
by PostOnce | 2025-04-19 23:57:37+00:00
I as a child, a teen, and a young adult thought I hated math, I got bad grades and it bored me. I dropped out of school. I later went to college and took remedial algebra twice.

Math in school was purposeless and rigid, a rote procedure to be followed by command because that's what kids have to do.

Now, I have grown older, and my curiosity drove me to learn because I wanted to make things, machines and software and probabilistic strategies. Things that necessitate math. If you can't rotate a vector, your guy walks faster diagonally. If you can't think mathematically and you want to lift a 2 jointed robot arm that weighs several tons, you're going to tip it over, and possibly die in the process. You can do it without trig but you can't do it without thinking about math.

Once I found purpose, I began to appreciate the beauty of the more elegant solutions. I kind of fell in love with math as an adult. Now I watch numberphile with my kids and make complicated machinery and software at work.

I think a lot more people love math than realize it, because they're conflating math itself and what school calls math, which is worksheets and demands, not beauty and creation.
by eth0up | 2025-04-19 23:57:59+00:00
Is he defending a terrorist, or is he defending information accuracy?

If he's defending terrorism, fine then. But it's kind of creepy when because terror, we advocate low quality or bad information and insult those who speculate. If it's the latter, that may well be a form of psychoterrorism. I didn't observe any advocacy of terrorism, but I guess I'll read the comment again to be sure.
by XorNot | 2025-04-20 00:01:44+00:00
But the reality is that's usually almost a false trade - I'm not buying one item in the grocery store I'm buying easily a dozen or more. The best way to do this would be toss the online inventory into a solver to calculate "best value" for me, but in reality it would be a waste of time because if they're out of something, or the quality looks suspect, then that blows that calculation completely. And then am I going to do this for every single item, where every minute in the store is multiplying through the rest of my day? How much is the time shopping trading off against extremely sparse leisure time?

And then there's intangibles - something being slightly cheaper doesn't necessarily mean I'm making a good trade off by buying it for my overall quality of life.

In Australia at least this whole problem was perfectly adequately solved by mandating bulk price labeling on all items in the supermarket. Products in comparable categories have per volume/weight prices listed alongside item prices.
by vitus | 2025-04-20 00:03:22+00:00
The first code block (with the raw loop) also has an unnecessary copy in the form of `response.data = transformed_data;` -- that should be std::move(transformed_data), or else you're copying every element in the vector.

That further eliminates the copies outside of the loop. At that point, you basically have created every element just once, with no moves or copies.

Meanwhile, the ranges approach incurs a move followed by a copy for every element. It's not obvious to me how to eliminate those.
by _DeadFred_ | 2025-04-20 00:03:48+00:00
When I was in management they hated temporary income bumps to employees because when the income bump went away the employees tended to look for a different job at the income level they became accustomed to/dependant on. It's not they don't want to give you more income, it's they know they will be hosed when/if they cut your income later.

Edit: This was also an issue with year end bonuses. We did well a few years and bonuses were given and it made things difficult when the good years ended. I doubt they gave bonuses after that, good or bad year.
by LegionMammal978 | 2025-04-20 00:04:18+00:00
> I think a fairer comparison would be to not store a std::vector<ToData> in Response in the view version, but store the actual view.

That would be catastrophic, since the view is only storing a bunch of references to the (Widget widget) argument that gets deleted once the function returns. In general, you have to be wary regarding how long references are valid for.

Anyway, I'm not entirely sure what the purpose of the transformed_data vector is. If you're already going to put it into response.data, just clear it out and start adding elements directly. Or if that's infeasible, at least move it into response.data instead of copying it.
by SonOfKyuss | 2025-04-20 00:06:06+00:00
I’m all for holding journalists to account, but I think they gave away the game when their main takeaway from reading that article was to complain that a terrorist was treated unfairly using a weak comparison to another group they likely have less sympathetic feelings towards. It was very clearly an attempt at whataboutism between black lives matter and the Waco bombing.
by westurner | 2025-04-20 00:06:44+00:00
Red Hat too.

Containers, pip, and conda packages have TUF and now there's sigstore.dev and SLSA.dev. W3C Verifiable Credentials is the open web standard JSONLD RDF spec for signatures/attestations.

IDK how many reinventions of GPG there are.

Do all of these systems differ only in key distribution and key authorization, ceteris paribus?
by thomassmith65 | 2025-04-20 00:07:22+00:00
What set me off is... well, it's easiest to share some memories:

1970s, early 1980s in America: nowhere to get espresso except for fancy restaurants or italian neighborhood

Late 1980s in Pacific NW, America: quirky little Starbucks chain pops up. Ambience emulates a SF hippie coffee house, but they serve Italian-style cookies and espresso.

1990s, 2000s: Starbuck becomes gigantic corporation. Coffee culture fad spreads. Average American now knows what 'biscotti' are.

Today: "Italians make bad espresso"

And in a plausible future...

2050s: espresso fad long dead in America. Italians carry on same as ever, since coffee there, for generations, has meant 'espresso'
by like_any_other | 2025-04-20 00:07:51+00:00
You are the second person in this thread to pretend to not be able to distinguish between accepting collateral casualties, and having them as the primary objective. You also imply I'm trying to rehabilitate McVeigh, when I have done nothing but point out how the Guardian is playing loose with facts, and being opportunistic in who they associate with which decades-old tragedies. Do you think he is so sympathetic, one has to lie about him to avoid 'rehabilitating' him?
by benoau | 2025-04-20 00:08:03+00:00
I have always wished TypeScript would just be built-in because it would eliminate build steps and processes and a massive chain of fluff that makes building and rebuilding and starting and restarting so much slower. It's hard to believe it didn't happen and very disappointing for both browser and NodeJS.

I certainly don't think Go is in a better position to achieve this.