Better HN
topnewbestaskshowjobs
Log inSign up

dagenix

2,657 karma · joined Jul 15, 2017 (9y ago) · 560 submissions

Submissions

comment 2mo ago · link · parent

How did they fix it?

comment 3mo ago · link · parent

Bank account interest is pretty much always less than inflation. So, money sitting in a bank account for 18 years is just losing value.

comment 4mo ago · link · parent

I have no idea how well such a system works, but, I found these lines pretty jarring:

> They found it fires on ordinary driving, not just distracted driving.

> Glance away from an empty highway to take in the scenery, or look at the infotainment screen to change a song, and the warning goes off anyway.

Like, isn't that the point, that if you aren't looking at the road it should go off?

4.

The Guix Nix Abomination: Leveraging Guix Derivations in Nix(fzakaria.com ↗)

63 points · by dagenix · 5mo ago · discuss

5.

GenCAD(gencad.github.io ↗)

441 points · by dagenix · 6mo ago · 127 comments

comment 6mo ago · link · parent

If you don't like the debian model, didn't use debian. There are people that like the debian model, it seems like you aren't one of them, though. That doesn't make them wrong.

comment 6mo ago · link · parent

My understanding is that existing Ebay shareholders would get half cash and half stock. In order to actually profit, those shareholders would need to believe that the combined company's stock could be sold off without taking a significant loss.

comment 10mo ago · link · parent

https://archive.ph/ZMsnQ

comment 1y ago · link · parent

I strongly suspect that its not feasible to colocate pijul and git. git and jj are based on snapshots, while pijul is based on patches. They have very different models.

comment 1y ago · link · parent

One thing JJ has that git doesn't is the concept of first class conflicts. In JJ, rebasing or merging never fails, but it might record a conflict to resolve later. Git, on the otherhand, forces you to drop we everything to resolve conflicts immediately. It sounds like a small thing - but in my experience, being able to resolve conflicts later when I feel like it is absolutely amazing and really helps reduce context switching.

11.

YouTube agrees to pay Trump $24M to settle lawsuit over Jan. 6 suspension(npr.org ↗)

10 points · by dagenix · 1y ago · 1 comment

comment 1y ago · link · parent

You are supposed to supervise Tesla FSD. Waymo doesn't require someone in the driver's seat at all. They aren't the same thing.

comment 1y ago · link · parent

The problem, IMO, with asyncio is that its way, way too complicated. In my experience, anyio (https://github.com/agronholm/anyio) provides a much better interface on top of asyncio. And since it can use asyncio as a backend, it maintains compatibility with the asyncio ecosystem. FastAPI, for example, uses anyio.

One thing that I don't see being mentioned in any of the threads here talking about green threads is cancellation. A huge benefit, IMO, of anyio is that it makes cancellation really easy to handle. With asyncio, cancellation is pretty hard. And with green threads, cancellation is often impossible.

comment 1y ago · link · parent

In my experience, the key to using asyncio is to use anyio. Anyio is an interface that you can use ontop of asyncio and fixes most of its shortcomings.

https://anyio.readthedocs.io

comment 1y ago · link · parent

I'm not dismissing uv, I'm critiquing the article.

comment 1y ago · link · parent

> This approach eliminates the need for complex setup tools like requirements.txt or package managers...

And yet, the rest of the article is about uv. According to uv itself:

> An extremely fast Python package and project manager, written in Rust.

It's a package manager!

comment 1y ago · link · parent

It doesn't seem like https://comma.ai/ has sources either.

comment 1y ago · link · parent

I especially like how there is next to no mention about safety on the main page. But at least its only $999 and it has AI and 50k GitHub stars, so, thats nice.

comment 1y ago · link · parent

So, a hackier version of Tesla's autopilot? Sounds, uh, terrifying.

comment 1y ago · link · parent

The pretty significant updates to MacOS support are really cool to see!

comment 1y ago · link · parent

https://en.wikipedia.org/wiki/G._K._Chesterton#Chesterton's_...

22.

Technical Analysis of Men's 100M Final Photo Finish(old.reddit.com ↗)

1 points · by dagenix · 2y ago · discuss

comment 2y ago · link · parent

I don't believe its in the standard library for Rust, even if it is very popular in the Rust ecosystem.

comment 2y ago · link · parent

Java does jit

comment 2y ago · link · parent

> Yes, but the absence of the GIL would make race conditions more likely to happen.

Does it though? I'm not saying it doesn't, I'm quite curious. Switching between threads with the GIL is already fairly unpredictable from the perspective of pure-Python code. Does it get significantly more troublesome without the GIL?

> Yes. They could run it in multiple threads with the GIL today, but as above, race conditions might not show up as often, so it might not be realized that the code is broken. But also, with the GIL there is the common perception that Python doesn't do multithreading well anyway, so it's less likely to be used for that. With the GIL removed, I suspect many people will want to use multithreading a lot more in Python to parallelize code, without fully realizing the implications.

Fair

comment 2y ago · link · parent

> But there is a lot of pure Python code out there that is not written that way. Removal of the GIL would allow such code to be naively run in multiple threads using, for example, Python's support for thread pools.

I guess this is what I don't understand. This code could already be run in multiple threads today, with a GIL. And it would be broken - in all the same ways it would be broken without a GIL, correct?

> Anyone under the impression that removing the GIL was intended to allow this sort of thing without any further checking of the code is mistaken. That is the kind of thing my comment was intended to exclude.

Ah, so, is your point that removing the GIL will cause people to take non-multithread code and run it in multiple threads without realizing that it is broken in that context? That its not so much a technical change, but a change of perception that will lead to issues?

comment 2y ago · link · parent

Yup, I think its described here: https://docs.python.org/3/c-api/init.html#releasing-the-gil-....

My understanding, is that many extensions will release the GIL when doing anything expensive. So, if you are doing CPU or IO bound operations in an extension _and_ you are calling that operation in multiple threads, even with the GIL you can potentially fully utilize all of the CPUs in your machine.

comment 2y ago · link · parent

> If your Python code assumes it's just going to run in a single thread now, and it is run in a single thread without the GIL, yes, removing the GIL will make no difference.

I'm not sure I understand your point.

Yes, singled thread code will run the same with or without the GIL.

My understanding, was that multi-threaded pure-Python code would also run more or less the same without the GIL. In that, removing the GIL won't introduce races into pure-Python code that is already race free with the GIL. (and that relatedly, pure-Python code that suffers from races without the GIL also already suffers from them with the GIL)

Are you saying that you expect that pure-Python code will be significantly impacted by the removal of the GIL? If so, I'd love to learn more.

comment 2y ago · link · parent

The GIL prevents the corruption of Pythons internal structures. It's hard to remove because:

1. Lots of extensions, which can control when they release the GIL unlike regular Python code, depend on it 2. Removing the GIL requires some sort of other mechanism to protect internal Python stuff 3. But for a long time, such a mechanism was resisted by th Python team because all attempts to remove the GIL either made single threaded code slower or were considered too complicated.

But, as far as I understand, the GIL does somewhere between nothing and very little to prevent races in pure Python code. And, my rough understanding, is that removing the GIL isn't expected to really impact pure Python code.

comment 2y ago · link · parent

Are you writing an extension or Python code?

If you are writing Python code, the GIL can already be dropped at pretty much any point and there isn't much way of controlling when. Iirc, this includes in the middle of things like +=. There are some operations that Python defines as atomic, but, as I recall, there aren't all that many.

In what way is the GIL preventing races for your use case?

12345
19