skysight-inc/HackerNews huggingface dataset:
My problem with these is that they are generally written by the developer who wrote the function.

So devs code the happy path in their function, and test the happy path in their unit test.
Yes, in fact, 2+2 is in fact 4.
But, do they test add(2,-2) or add(-2,-2) or add(null,2) or add (0,null) .. etc.

Whatever cases they forgot exist and never coded for, never get tested for either. If this is not caught in the initial commit by another dev, then it makes it through to prod happily despite having "unit tests".

This is why I think tests where the application is forced to interact with real world data are better because if your app will be broken by negative/0/null, and that state exists in the real world data, it will break in testing.

Of course this is all a long dissertation on how to code&test the addition of 2 integers. One of the simplest possible functions, now do this on more complex software.

The unit test I think biases later developers to believe the original developer actually coded the software correctly, when to me, in a large number of cases.. it was wrong to begin with, but uncaught.
Shenzhen, China's 'city of young migrants,' at point of inflection
Worse Is Better syndrome.
Dont know how it works in USA but the schools I knew wanted you to write down no novelties or thought of your own, you were supposed to repeat the 'accepted' interpretation of a book. You were graded for memorizing or recognizing the themes that you were supposed to mention.

Also big chance to get a C or a D when you came up with a "novel" approach that the shitty and boring book is actually shitty and boring.

Hell no school was there to stop making your own interpetations different than the official one.

Damn, even on the fucking retarded drawing lesseons (where probably half of stuff was drawn by parents) the teachers would deduct points for any individual style.

I was thinking of getting an MBA, but does it even get any better for "adults"? Arent you just tought to repeat some schematics, which often are bullshit.
Hah, exactly that! You put it better than I could have had.
I've had a terrible time with my Z16 AMD Gen1 (Ryzen 6850H). One broken BIOS update after another, and just when things started to stabilize they pushed out one that broke external USB-C displays and hubs, and the update went out in a way where it could not be rolled back and it's been like this now for over a month without a fix.

Before that they had BIOS versions that under-ran the fan so it overheated, versions that overran the fan constantly, and power management and wake-from-lid-closed under Linux has in general been a nightmare all along.

Lenovo's reputation for reliability has been heavily tarnished by this, but in particular I think going Ryzen with them is a real roll of the dice.
Nope. I explicitly remember the source code being there.
> Microsoft announced it was meant to supersede the old legacy .NET Framework

What actually never happened, to nobody's surprise.

So now we have .Net that was renamed into .Net Framework that is legacy, .Net Core that is legacy but compatible with the modern version, and .Net that is current. Anyway, the platform never stopped being called .Net, because it's larger than just the runtime.

We also have 2 different number sequences starting from 1, and one starting from... some times 4, other times 6, depends on your point of view.

We also have a bunch of confused people without any reason, because all of this is as clear as water. But anyway, it's not the author fault that he didn't communicate the version in an adequate way.
Casting an integer to a pointer is implementation defined, not UB.

And every sane implementation does what everyone expects because its how memory mapped IO works (but you probably want a volatile in there and maybe a compiler or memory barrier as well depending on what the hardware guarantees about the access patterns for that particular range of addresses)
I'm not sure what's the component under test and what's the dependency here. But I don't see this as particularly complex to test.

Assuming you're writing a client:

- use the client to send a sell order, check that you handle properly the ack (or lack thereof) of the trading platform.

- check that the client handles properly a buy order received from the platform.

- check that the client handles properly a cancel order.

- check that when an order is filled, the client closes it properly after the cancel window is closed.

- check that the client recovers properly after a crash.

To do this, assuming the platform is a dependency of the client, in each test case, you have to implement one or two hardcoded messages from the platform.
Re: selective breeding and genetic engineering, that's going to happen regardless of the atmospheric carbon levels.

Also, while I did bring up agriculture and it's fair to point out that it's going to get better over the next thousand years, agriculture is only about 2% of the Earth's plant biomass. While the rest of the biomass will be affected by the heat and benefit from the CO2, unless we start engineering the phytoplankton and the forests and all the other plants around us, it's not going to benefit from it.

Re: Canada's gain, there is a lot of land between 50 and 70 degrees north. The questions are (a) how much land in the north are we trading for how much land in the south? and (b) how does the productivity of the northern land compare to the productivity lost in the southern land?
> In fact, the name of the original book about awk is The Awk Programming Language.

Great book. I read it after it was so enthusiastically endorsed here on HN. A lot of people said it was worth reading just to take in the excellent technical writing style of Brian Kernighan.

I would offer a strong second to that.
https://www.techrepublic.com/article/how-to-archive-websites...

You can take a look at this article.

I will sync web archives to my Mac through iCloud, and then import it in bulk into Hamsterbase.
This reminds me of Chicago water service lines. They were required to be lead till well into the 70s.. even though it was a known toxin.

https://www.theguardian.com/us-news/2022/sep/21/lead-contami...
Rex: https://metacpan.org/pod/Rex never used it but
I believe so!
I am perfectly aware of what IL decompilation is. I've written a decompiler before before. That's not what was happening.
Looking at your point regarding that earning call, it seems you're looking at this in light of a more traditional company and not an ETF/REIT/Leveraged fund. Forgive me if I'm wrong in that assumption. For conventional value investing, this is probably true, I'm no expert.

It does seem to me that there is room for a stock like this in one's portfolio though, as part of a larger strategy. Maybe a high yield leveraged fund is only a small portion of your stock, or you need to convert some of your assets to income for a few years.
So you use ElemantaryOS with the KDE Plasma desktop? Or Plasma on a different distro now?
The answer is yes. They can be disassembled and reassembled in a solved state. That's what I did.
> Why they got to assume their reader is a “man” at the end though?

"Man" can in many cases refer to more things than just "men". Like mankind, or the typical surfer/stoner-usage of "man", which refers to any gender/non-gender, which is the case in this article. Just like "dude" can mean more than just "you of male gender".

For posterity, the article ends with the following:

> Pure thought-stuff, indeed, man.
I guess I'm lying then. :)
On Statistically Improbable Things and Irrational Fear
Did you do any estimate of how much storage is required?

On the face of it, I would expect the gradients to take about as much space as the weights. So you’d be checkpointing your network at every batch, in effect.
Testing against real services (probably in some kind of staging environment) is mandatory, IMO, but it is only really useful for verifying the happy path, or some simple failure modes. Unit tests can verify the system's logic is correct in the face of complex edge cases that are difficult to replicate in integration or end-to-end testing.

Unit tests also allow you to add new functionality to the codebase with confidence, as you can know that your modifications did not break some specific edge case or cause some bug regression. If you're in a dynamic language they also help ensure your refactoring did not introduce some type mismatch somewhere.

Which is why I draw the conclusion that anyone who thinks unit testing and mocking boils down to `response = "derp"; assert response == "derp"`, must not have much experience working in such codebases.
Excellent points @eropple! The fediverse - or at least many stacks/implementatins/apps - does lack some features of twitter or bluesky, etc.; but, the omissions tend to be by design. So, your points about my assuming that everyone's expectations are the same is valid. I should have been more clear, and noted that expectations should be different on the Fedi side of things. My intent was to show the OP that they should feel free to, well, feel empowered, and not feel like they need to be at the whim of some corporate entity - considering there exists technology that can give that person some more freedom and at least some mechanisms to engage with other humans, etc. But, your points are valid: the experience is different. For me, i rather like the purposeful constraints of the Fediverse, but of course it might not be for everyone; that's true. ;-)
Same here, no problems with undefined behavior. Also, no memory issues either after done with code finalization using Valgrind.
How could you guarantee such a thing? I get almost daily use out of my PCs. For work, for play, for whatever. I think that is a bold assumption to make without knowing a person.
> Stock buybacks are such shenanigans in comparison: they make money and use it to inflate the value of their shares.

Nothing is inflated if you think it through, since the market capitalization does not change.

By that logic, is issuing new stock (or even stock splits!) virtuous, since they both decrease the price per share?
Very frankly, Google it for yourself. This result is remarkably consistent. It would take intentional refusal to not find one study that you like, but do that effort by yourself.

It is not my fault you don't trust your own link or did not read it. Because that link is about "divorce rate" among "married at least once" subset of population. not about number of divorcees in the whole population.
I agree with your point about Python, which is why I'm glad type hints see adoption but dismayed that they're essentially fancy comments that don't enforce the actual runtime types.

The thing is, I'm not convinced avoiding UB is easy. E.g. what's the behavior of the following code?

int16_t a = 20000;
int16_t b = a + a;
It's a tiny part of that post, easy to overlook:

> The fundamental question we will address is whether the elements and radioactive isotopes in the spherules have different abundances than solar system materials. If so, we would also check for any anomalies that might indicate a technological origin.
> I give you 2 hours to write a brand new fully spec compliant ARMv8 interpreter, 3 hours to write an android VM to run on my windows laptop.

2 hours is pushing it for pretty much anything. I am pretty confident I can make a 64bit risc-v interpreter that'll boot Linux in a few days. Wouldn't be fast and wouldn't have IO, but neither of those have any baring on how easy the instructions are to interpret. The spec is fairly easy to understand.

> The instructions allowed them to depend on platform specific features, which is what I want to prevent.
> Instead of calling some random android `external_is_switch_gesture` syscall the app should request a boolean/bit given a string "Has there been a switch gesture?" and expect the result of that syscall to be what they asked for.

Ok so in order to make it fast we're not going to use strings, instead integers that we only ever increment for new syscalls (no conflicts, ever). Applications want to know whether the system has support for a syscall, so we return an error if they don't exist. This is how Linux syscalls work.

Lets use your hypothetical: I'm writing a game that makes heavy use of switch geatures. I make my game call the "Has there been a switch gesture?" syscall, but whoops switch gestures were added in version 6 but this customer is using version 5. The absense of this syscall is fundamentally incompatible with my game, so I guess I'll put "requires version 6" on the website.

This is the status quo. Nothing you've suggested is a fundamental change to how software/hardware works. As long as new things are being invented/written you can never have full backwards compatibility.

> but if it is not you could simply prompt the user to chose what to give the application given a list of all the possible environment access.

Just to be thorough this is fully possible right now - intercepting unknown syscalls and showing a prompt - but there's simply way too many and their behavior too complex for it to be of any use. Especially non-experts would have exactly zero chance.
Are you sure they didnt spend a lot of time to get the answer, then posted the question with a sock puppet account?
Having messed with VR/AR tech since the DK2, the Apple Store presence could be the killer app that VR/AR needs.

The manual learning process of ordering special fit lenses, adjusting the headsets, etc would be a great fit with Apple’s store model.
They should just self host so they are not dependent on anyone else's platform. Microsoft is worth 2.5 trillion dollars. I am sure they can spare a few pennies to toss at a server running mediawiki.
I'm not OP but in their list the glasses are obviously acting as the computer screen they'd be working on, chosen because they're smaller and lighter than carrying an actual monitor around with you.
Show HN: Momento AI – Create your own AI clone
https://www.producthunt.com/posts/momento-ai

Hello everyone it's Julian the Founder & CEO of Mome to AI. I am happy to announce the launch of Momento AI the world's very first turnkey and scalable AI cloning platform! Scale yourself by creating an AI clone of... you.

Train your clone
No code
Real conversations
24/7 uptime

Train your AI clone on historically accurate and real-time data about you

Earn cash from follower subscriptions to your clone

Secure your AI cloning rights on Momento AI and we will make sure no one clones you before you do.

Now you can have a subject matter expert in your pocket at all times. Interact endlessly with your favorite online personality. Need a friend who is always there for you and truly understands you? Find them on Momento AI
I see a lot of people mentioning Fairphones not being on par with phones by multi billion dollar companies.

This citicism is valid. But I think it leaves out a lot of the overall picture.

I have a Fairphone 3, and so far it survived being dropped into the bathtub (being submerged for a sec), being dropped on hard floors several times and being stepped on (screen got cracked, but it still works).

Like with the Fairphone 2 I had before that, I'm able to do repairs (part replacements) on my own with minimal effort. It gets support for years.

I have it running /e/ OS (terrible name) without Google Services and while that's not Graphene OS, I vastly prefer it to Google Android.

For me having minor frustrations with Wi-Fi is well worth having a less-unfree and more-ethical phone.
> That's how the people on the other side of the table feel.

Of course, you can't say such a general thing about a very diverse group of people with different motives and incentives.
You are right that it doesn't fit in. You are wrong that it isn't a major theme. Probably the last third of the book is about cryogenically preserving someone while looking for a way to revive them.
Cool

https://freedomhouse.org/country/indian-kashmir/freedom-worl...

I'm at 27 now, yayyyyy
Kudos to The Guardian for choosing to illustrate the article with a picture of the guy wearing a "Who the fuck is Justin Bieber" T-Shirt.
I can understand the Bay Area workforce being costly, but how much are they saving by closing down the Chilean office/division?

I guess it’s harder to say given that they never specified where in Europe the work is moving to.
Thanks for the reply -- good info in here.

I'll consider adding a section / filter for stocks with repurchase programs. That is an interesting point I didn't consider. It's a bit tangential to theme of this site, but maybe I can make it work.

Factoring in the expense ratio is a very good idea--I'll look into how to add that.
Forms play a crucial role in web development. It allows users to interact with websites by entering data and submitting it to be processed. HTML (Hypertext Markup Language) provides a powerful toolset for creating forms that are both user-friendly and functional. In this comprehensive guide, we will walk you through the process of creating HTML forms from scratch. It covers all the essential elements and attributes. Whether you’re a beginner or an experienced developer, this guide will equip you with the knowledge to build effective and engaging forms for your web projects.
> you don’t get fulfilling internet experiences when you build for brand safety

The other side of that coin is that when you fire the bouncer at your bar that used to get all the marketing spiffs from the beers you serve and the bar fills up with meth dealers and their hangers on, those brands leave, too.

In other words, Twitter is not the public square. It's a tavern on the public square and normies don't go there now that nazis and bigots hang out there.
Ironically, it probably is.

But we need to be able to see it.
You can store your 'list items' in an array and still link to random items in the array - although an index instead of a pointer would make more sense in that case, but what else is an index than a pointer with fewer bits ;) The main advantage being that you don't need to alloc/free individual items.
Absolutely. The Perl Team stands unrivaled to this day by anything in subsequent communities. That and the O'Reilly Perl series.
So, which references would you point to?

I've work in such environments. I've been bitten by mocks and I've been bitten by false positives from ugly E2E systems. I've seen flaky E2E tests linger indefinitely, so I know why trying to spin up the whole system for a small set of tests is bad.

I also know that test data management and systems like VCR are very difficult to maintain. So, we mock because it's more painful to do otherwise. (That is; the test data management does not keep every edge case because it's extremely expensive to do so.)

Yet, the mocking is painful too in the complex system. There's no way to tell if the mock's response has been changed from underneath. You introduce false confidence in your code. Most bugs, in my experience, are based on a misalignment of expectations between two separate parts of the system (or internal/external systems.) Some of this is based on changes, others are based on unknown edge cases.

So, given that this is a hard problem, where do you point intermediate practitioners?
Why? Do you mean assuming using a laptop screen and not raising it higher than the desk?
How is std::vector is inefficient?

Especially that that macro-hack from stretchy buf seems to do it in an even more naive way.

Splitting the element data is a different implementation with very different performance characteristics - it’s quite a bad thing if I have to resort to that due to a language inefficiency, especially in case of a language that is supposedly close to the hardware.
> These statements are not true in languages which support operator overloading

I guess I will never understand the C and Java developers incredible fear of operator overloading.

Do you have the same reaction to user-defined functions? Because they are exactly the same thing. Is it because of the bad type system that won't let you know what operator you are using?
it has, you just have to call it a "heat pump"
First of all, it's important to define what we mean by "innovation".

Is cryptocurrency "innovation"? Credit-default swaps? Leveraged buyouts? So much of what's been making absurd amounts of money in recent decades—and which gets openly called "innovative" by many people—is not better ways of doing things for people, but simply better ways of separating people from their money.

Second of all, it's important to look at who, exactly, is doing the hard work on the innovations that are pushing us forward, rather than simply making rich people richer. How many of these innovations come from people who got their education 15, 25, 40 years ago?

Third of all, it's important to question the very premise: I'm absolutely in agreement that there is a strong thread of anti-intellectualism in American culture, and that there have been changes in our public school system that have caused some serious problems over the past few decades...but to what extent are these problems universal? To what extent do they actually leave graduates less well prepared to be innovative?

Indeed, to what extent is innovation even a product of education, rather than culture and creativity?
FWIW, I agree with you. But I think there is an argument to be made: the OpenBSD team has indicated that cross-architecture ports help them find bugs that otherwise might not be noticed if they were just targeting the usual suspects.
The difference between China and the U.S. is that it is clear that corporations in China are to serve the government (CCP) and in the U.S. it’s the other way around.
I’m not sure ‘robust’ is a term that often comes to mind for me regarding the DOM API.
I wonder how much violence was due to diabetes, as its been documented since 600 years before christ? Alcohol being the main sources, sugar cane consumption didnt appear until the 1700's.

Likewise although fewer in number, the female threshold for murder seems to be lower, but it would have been nice to have known what the male thresholds were, ie what the disputes were about.

This could also show that females have other creative ways at getting back at people they feel aggrieved by, which might not be detected by law enforcers and thus remains under the radar and creates a vacuum of pertinent laws, with the only warning being "hell has no fury than a woman scorned".

And being part of an organisation like a guild or religion also seems to increase the chances of becoming a murderer!
The picture is taken in the UNIT Factory, Kyiv, Ukraine. Visited it in 2017. No idea how it is doing today, their website seems to be dysfunctional.

Built after the School 42 concept in France:
https://42.fr/en/homepage/
The Fairphone is going to be sold in the US in partnership with the e.Foundation which develops /e/OS (another deGoogled android fork), and is what's going to come preinstalled on the Fairphone https://murena.com/america/shop/smartphones/brand-new/murena...
There's a fine line between being a parody of a style and just being bad. I'm not certain where this one falls, but it's not really working for me either.

Perhaps a subset of HN is just excited to take the "rationalist" movement down a peg, which I suppose is a positive development.
Does it? Mastodon writes "toot":"http://joinmastodon.org/ns#" in its objects' "@context" as required by JSON-LD. What's wrong with it?
Singlefile supports batch saving URLs to local storage.

Right-click on the webpage > select Singlefile > choose "Batch save URLs".

Using this method, I have converted hundreds of my bookmarks into html files.

I also think that Hamsterbase is not worth $60, so I offered a free trial. Only after it is released on iOS and Android will I consider charging.
To add to this, if you think of a dividend as a forced sale of some of your shares (because that's effectively what it is), it doesn't look quite as appealing. A dividend is not free money.

That said, I do think that companies with consistent earnings and a solid track record of paying dividends are a different breed than a company than one that is driven by growth (often to their detriment). So it is worth paying attention to.