13,469 karma · joined June 3, 2011
But there’s no shred of enforcement and instead of calling for enforcement, politicians now call for relaxing the rules on salting.
That's not true in practice: Unsafe code is clearly delineated and can be 100% correctly identified. In C, usage of dangerous features can occur at any point and is much harder to clearly separate.
I've observed that a lot of the folks I used to meet at ruby conferences have moved to Rust. No idea what led to this, but maybe it's just folks that were generally curious about new programming languages that moved to ruby when it became better known and that the same interest led to adopting Rust.
In my observation the critisicm was strongly dominated by outrage over the actual fact.
This is indeed a reason I do consider leaving GHA. The underinvestment into this part of the product shows. But they also did announce quite some investment into new and (for us relevant) features alongside the pricing change, so I'll have a look at how this changes with some sorely needed work on the product.
If you upgrade the plan, you get more minutes for free - which can be consumed by the cost for free runners. They haven't specified at which rate a self-hosted runner consumes the free minutes, but at least for us, the change will largely consume free minutes.
> You might as well say that we should be paying per PR and Issue because, well, that part can’t just be free, you know?
You're misrepresenting what I said. I said, I'm fine with this for these reasons. It's a statement about me, not about what you should do nor what you should consider fine.
I pay (quite a bit) for GH because I do receive a service that's worth it, at least for now. And I'd rather see that GHA is something that makes them money than become something that is second-rate and lingers, just as it did before they made this announcement.
So moving away from GHA will not make self-hosted runners free, they’ll move into a different pricing structure that may or may not be beneficial.
And I think charging for self-hosted runners is actually fine. They’re not free for the provider either - log aggregation, caching of artifacts, runner scheduling, implementing the runner software etc are non-trivial problems for any larger CI system.
So I’m actually fine with the proposed change since it also gives me the power as a customer to say “hey, I’m paying for this, fix it.”
You are effectively filtering out the remaining companies that do care from the pool that you're talking to.
We really try to spend the time to answer every application, but since AI generated applications have become a thing, we have decided to not answer those. Why should I spent time if you haven’t spent the time?
If you need to check which places mutate this global static you only need to check the unsafe parts of the code - you know that no other part of your code could mutate it, the compiler won't let you. If you have a bug that is related to mutating this static, then it might manifest anywhere in your code. But you know for certain that the root cause must be in one of your unsafe blocks - even if you don't know which one.
Good programming practice will cut down that effort even more by dictating that unsafe access should be grouped in modules. For example when binding to a C module (unsafe) you'd usally generate an unsafe wrapper with bindgen and then write a safe wrapper on top of that. Any access that tries to go around the safe wrapper would be frowned upon and likely fail review.
And again, the compiler will help you there: Any access that tries to bypass the safe api would need to be unsafe {} again and automatically receive extra scrutiny in a review, making it less likely to slip through.
Compare that to a C codebase where anything goes. A static might be mutated anywhere in your codebase, even through a pointer to it - meaning you can't even reliably grep for it. It may slip through review unnoticed because no attention is drawn to it and cause bugs that are hard to trace and reason about.
If you're writing embedded code, similar considerations apply - access to registers etc. require unsafe {}. But because access is unsafe {}, it's usually gated behind a safe api that is the boundary of the low-level code and the higher buisness logic. Unsurprisingly, these are critical parts of the code - hence they receive extra scrutiny and in our project, we allocate substantial review capacity on those. And the compiler will enforce that no safe code can circumvent the access layer.
The number you're tagging as unrealistic figure is the result of dedicated and careful design of language and compiler features to achieve exactly this outcome. It's not a random fluke, very clever people did sit down and thought about how to achieve this.
It's not obviously clear to me which features are the relevant ones, but my general observation is that lifetimes, unsafe blocks, the borrow checker allow people to reason about code in smaller chunks. For example knowing that there's only one place where a variable may be mutated supports understanding that at the same time, no other code location may change it.
Yes, I believe that at least the order of magnitude is correct because 4 800 000 of those lines are guaranteed to not have any by virtue of the compiler enforcing memory safety.
So it's 1 per 200 000, which is 1-2 orders of magnitude worse, but still pretty darn good. Given that not all unsafe code actually has potential for memory safety issues and that the compiler still will enforce a pretty wide set of rules, I consider this to be achievable.
This is clearly a competent team that's writing important and challenging low-level software. They published the numbers voluntarily and are staking their reputation on these reports. From personal observation of the Rust projects we work on, the results track with the trend.
There's no reason for me to disbelieve the numbers put forward in the report.