back to article Google fixes 'Chromebork' one-character code typo that prevented Chrome OS logins

Google has fixed a bug in Chrome OS version 91.0.4472.165 that surfaced on Monday and prevented some users from being able to login to their systems. Chrome OS downloads updates automatically but doesn't apply them until reboot, so only those who restarted their Chromebooks to ingest the force-fed broken update were affected …

  1. Anonymous Coward
    Anonymous Coward

    It's the unintended side effect of evaluating both sides that's the problem here. The code probably crashed when operator - > returned a nullptr. Logically speaking, the use of && or & for two bools will produce the same result.

    Bitwise operations on bools could be warned about by the compiler if the language didn't allow implicit conversion from bool to int for backwards compatibility with C. Certainly it's something static code analysis should pick up. (I'll check that later when I'm near a computer.) Or, you know, testing code you write.

    1. heyrick Silver badge

      Or, you know, testing code you write.

      Given some of the weird bugs I've come across in various Google products, I suspect we are the testers.

      1. Mark 85

        Re: Or, you know, testing code you write.

        Given some of the weird bugs I've come across in various Google products, I suspect we are the testers.

        So Google is now following the Microsoft method? Users=testers.

        1. Anonymous Coward
          Anonymous Coward

          Re: Or, you know, testing code you write.

          I'm pretty sure Google were letting users test their products long before Microsoft decided to give it a go. Just think how many Google products were in beta for years. Some never even made it out of beta before they were canned.

        2. Irongut

          Re: Or, you know, testing code you write.

          What do you mean "now"?

          How long was GMail in beta?

  2. elsergiovolador Silver badge

    Low quality

    Many organisations does not allow you to commit code without accompanying test.

    Otherwise you have to put a lot of trust that the description of what commit is doing matches what it is actually doing. Given the likelihood of low paid engineers, who may not have energy nor time to thoroughly check someone else's work, you are creating a recipe for a disaster.

    1. Version 1.0 Silver badge
      Happy

      Re: Low quality

      Too often code is tested to verify that it "works" - the possibility of it not working is ignored if it passes the "working" test.

      I am watching the Long Strange Trip documentary again and listening to the Grateful Dead's music evolution over the years explained as being a result of their Acid Test performances when they learned to play in an unpredictable environment when everything was possible and virtually nothing was predictable. It's made me think that learning to play in a band has parallels to learning to write programs. If you ever took Acid Tests then you learned that anything (good and bad) can happen, and just because you think that something will happen, doesn't mean that it will happen.

      Now I wonder if my Orange Sunshine life before I started programming explains why I never have any coding issues in any language? The Acid Tests teach you that the answer is, Maybe, or Maybe not so I'm claiming nothing.

      1. Ken Moorhouse Silver badge

        Re: The Grateful Dead: Acid Tests

        Who'd have thought they were database gurus.

        Tip: Lay off the Acid Drops.

    2. Snake Silver badge

      Re: Low quality

      That is an interesting yet relevant comment, considering another bug that some of us are currently dealing with.

      Last week Lenovo issued a Thunderbird firmware update to, at least, my model of workstation laptop. It broke the HDMI output, no audio and completely lost ability to deliver anything over 1080i graphics.

      A very strange occurrence!

      The forums notified Lenovo tech and they are now working on a fix. In the meantime, unless you use an adapter from another port to HDMI, your external high-res monitors are not going to give you what you purchased them for.

      Someone didn't review the code prior to rolling it out. Plus, they disallowed downgrades so we can't roll back as a temporary, DIY solution.

      Yes indeed, we've all become bets testers. Thanks to the constant pressure of marketing, getting it out is more important than getting it right.

  3. Pascal Monett Silver badge
    Facepalm

    "All three mitigations, however, clear local data on the device"

    So Google screws up and you get to lose your data in order to keep using your device.

    You might as well be using a Windows laptop.

    Some people are going to learn the value of backups the hard way.

    1. Skiron

      Re: "All three mitigations, however, clear local data on the device"

      "Some people are going to learn the value of backups the hard way."

      And some people that are stuck in a boot-loop that haven't got any technical knowledge will be fooked.

    2. elsergiovolador Silver badge

      Re: "All three mitigations, however, clear local data on the device"

      I wonder if this will result in a class action or there is some small print somewhere that says the device can delete "your" data to heart's content.

      1. Skiron

        Re: "All three mitigations, however, clear local data on the device"

        Nah, it will all be covered in the EULA. See the 'WARRANTY DISCLAIMER' and 'Limitations of Liability'sections, which almost all tech companies use.

        https://www.termsfeed.com/blog/sample-eula-template/

        1. Uncle Slacky Silver badge

          Re: "All three mitigations, however, clear local data on the device"

          IIRC EULAs have no legal force, at least in the UK. That might concern only the "by opening this package, you have accepted the EULA" kind of thing, though.

      2. Robert Carnegie Silver badge

        Re: "All three mitigations, however, clear local data on the device"

        I think they're saying that the real fix is to log in as guest and then upgrade from the wonky upgrade - when possible. I hope that means that you can now log in as the user and access your local stuff that is still there?

    3. Version 1.0 Silver badge

      Re: "All three mitigations, however, clear local data on the device"

      Some people are going to learn the value of backups the hard way

      There are only two classes of user; Those who have never lost any data, and those who are going to lose data.

      1. Skiron

        Re: "All three mitigations, however, clear local data on the device"

        "There are only two classes of user;"

        Surely 10 classes of users...

      2. AndrewB57

        Re: "All three mitigations, however, clear local data on the device"

        Slight mod:

        ..those who have lost data and those who are about to lose data.

        I don't believe one can go through any significant spell without SOME data loss whatever the strategies employed

        1. quxinot

          Re: "All three mitigations, however, clear local data on the device"

          >I don't believe one can go through any significant spell without SOME data loss whatever the strategies employed

          You're doing it wrong, then.

          It is well and truly possible to not lose data, if that data has been proven to be important, and treated as such. Data that is inconsequential and treated as such can be lost regularly, but that's a very pedantic view.

      3. elsergiovolador Silver badge

        Re: "All three mitigations, however, clear local data on the device"

        Just make the subject access request to all the spying companies and you'll get your data back ;-)

    4. Anonymous Coward
      Anonymous Coward

      Re: "Some people are going to learn the value of backups the hard way."

      Except it can be impossible to truly back up a modern walled garden device as the line between data, application and application provider (all those "apps" you need to sign up for) becomes ever fainter.

      Plus the time needed to fix Googles fuck up. What's that - a million person-hours easily.

    5. Buzzword

      Re: "clear local data on the device"

      I thought the whole point of Chromebooks was that they didn't store any local data on the device?

      1. The Unexpected Bill

        Re: "clear local data on the device"

        Chrome OS does store data locally and allows the user to do the same, though I suspect it is "strongly suggested" that one use the cloud for their data storage needs. Cheaper Chrome OS devices have just enough storage for the OS and very little else. More expensive models have more local storage.

        I've seen Chrome OS arbitrarily decide that it was time for a complete system reset without any warning, so keeping regular backups would be especially wise. Not being all that in to cloudy things, I use a USB flash drive. Unfortunately, there's presently no automation in Chrome OS for making backups that I'm aware of (and probably won't be).

  4. Skiron
    FAIL

    Me too!

    I got bit by this Monday night - after the said update I was stuck in a boot-loop. I managed to recover it all using the Chrome extension on a Windows box at work - luckily didn't lose a thing thanks to the first thing I did when I got it was get a SD-Card to save pertinent stuff on.

    So, having been bitten once I downloaded the 'linux_recovery.sh' bash script so I can use any of my *nix boxes/laptops to do it easily at home if it happens again. Unfortunately it didn't work! Anyway, after a lot of faffing about in the code I found the reason and fixed it up and logged a bug report - you can read all about it here (includes a patch):

    https://bugs.chromium.org/p/chromium/issues/detail?id=1232078#c_ts1627063056

    Another 'gotcha' is the name. On the label on the back of my Chromebook it states I have a HP 11a model. Well, when I grabbed that image the recovery screen said that there was no bootable image found. Ummm. So I used the long HWID key and that found the correct image for my Chromebook but it is for an HP G6 EE? WTF? Anyway, got there in the end.

    BTW, for those interested, here is the actual commit and culprit (see near the end for the offending line):

    https://chromium.googlesource.com/chromiumos/platform2/+/a99bb48cf00496d7eed6b587c6440b2f6edf07b0%5E!/

    1. Skiron

      Re: Me too!

      Oh, forgot.

      There was another issue too. After doing the recovery, I turned on 'linux beta' again to set up the container, but it wouldn't start as it stated that my Chromebook wasn't up-to-date. So going to update it was! Anyway, after a bit of a google I found you have to disable dlc. In chrome browser goto:

      chrome://flags/#crostini-use-dlc

      and disable it. I could then install the linux beta OK.

      1. Anonymous Coward
        Anonymous Coward

        Re: Me too!

        Don't forget to bill for your time.

      2. Anonymous Coward
        Anonymous Coward

        Re: Me too!

        "Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live." - Martin Golding

        1. Irongut

          Re: Me too!

          The guy who maintains my code IS a violent psychopath who knows where I live.

          It's me.

  5. Imhotep

    Can't Login

    If I understand this correctly: how could there have been ANY testing that would not have discovered this bug immediately?

    Or am I misunderstanding the issue?

  6. Miss Config
    Linux

    WHAT form of Linux ?

    Google advised users: to "powerwash" their Chrome OS devices back to factory settings; to rollback the Chrome OS device to a previous version via USB; or to remove the affected account and add the account back to the device. All three mitigations, however, clear local data on the device.

    Or simply install a different distro of Linux entirely.

    1. Boothy

      Re: WHAT form of Linux ?

      'simply' likely depends on the Chromebook.

      My Lenovo Chromebook from a few years back (N20P), required disassembling to get at the main board, and the 'wrong' side of the board as well, so not just a one side cover removal . This included a somewhat unnerving 'cracking' open of the case. I'd done this with mobile phones before now, so had some experience, and the tools needed, but it still needed quite a bit of force!

      Once done, there was a screw that needed to be removed, this had a very large flat head, that bridged two solder pads on the motherboard. Removing this, unlocked the Chromebook bios/flash area, essentially allowing you to replace the boot side of things, and so effectively changing it into a mostly standard Laptop/Netbook device. (Without this, things are basically temporary).

      Once done, installing Gallium OS (based on Xubuntu) was as straightforward as sticking Ubuntu onto a standard Laptop would be.

      Makes quite a nice little Linux netbook now!

      Bonus was avoiding landfilling a perfectly good device due to Googles arbitrary fixed support lifecycle for Chromebooks. aka planned obsolescence.

  7. luminous
    Coat

    You're all doing it wrong

    All of your data should be in our cloud, so this would not really be a problem.... why are you idiots saving anything locally?

    \Sarcasm

  8. This post has been deleted by its author

POST COMMENT House rules

Not a member of The Register? Create a new account here.

  • Enter your comment

  • Add an icon

Anonymous cowards cannot choose their icon

Other stories you might like