• sugar_in_your_tea@sh.itjust.works
    link
    fedilink
    English
    arrow-up
    4
    ·
    51 minutes ago

    Ift is precious and beyond compare. It has tools that most other languages lack to prove certain classes of bugs are impossible.

    You can still introduce bugs, especially when you use certain features that “standard” linter (clippy) catches by default and no team would silence globally. .unwrap() is very controversial in Rust and should never be used without clear justification in production code. Even in my pet projects, it’s the first thing I clear out once basic functionality is there.

    This issue should’ve been caught at three separate stages:

    1. git pre-commit or pre-push should run the linter on the devs machine
    2. Static analysis checks should catch this both before getting reviews and when deploying the change
    3. Human code review

    The fact that it made it past all three makes me very concerned about how they do development over there. We’re a much smaller company and we’re not even a software company (software dev is <1% of the total company), and we do this. We don’t even use Rust, we’re a Python shop, yet we have robust static analysis for every change. It’s standard, and any company doing anything more than a small in-house tool used by 3 people should have these standards in place.