Skip to main content

Amazon Drone Crashes On Garage After Delivering Shampoo, Draws FAA Probe

13 hours 23 minutes ago
The Federal Aviation Administration (FAA) has opened an investigation into an Amazon Prime Air delivery drone that struck a fiber-optic cable and crashed onto a residential garage in Michigan after delivering shampoo. The drone lost a propeller and became entangled in power lines, prompting Amazon and local utility workers to coordinate its removal. Amazon offered to help repair the damaged roof and gave the homeowner a $100 gift card. Ars Technica reports: Amazon Prime Air currently operates a fleet of battery-powered MK30 drones that can deliver packages weighing up to five pounds and have onboard sense-and-avoid technology to avoid obstacles. However, the drone clearly failed to avoid the thin fiber-optic cable in this case -- so hopefully the FAA investigation would take that into account along with Amazon delivery drone procedures. The FAA preliminary accident and incident notification briefly describes the incident as "UAS struck a fiber cable, a residential garage, and became entangled in power lines during takeoff." That notice was posted on November 23. The National Transportation Safety Board is also gathering information about the incident but has not yet decided whether to open its own probe, according to CNBC. That US government agency holds primary responsibility for investigating aviation accidents and other transportation incidents. Amazon said the Michigan crash was the first involving its drone delivery operations near Detroit, but federal regulators are already investigating several incidents in Arizona and Texas involving collisions with a construction crane, an internet cable, and an apartment building. An Amazon spokesperson said Prime Air drones make nearly 6,000 flights per day and have delivered "hundreds of thousands of packages this year."

Read more of this story at Slashdot.

BeauHD

CodeSOD: ReferenceError: HELL is not defined

13 hours 53 minutes ago

David came across some Java code. This particular block needed to, based on an integer masquerading as an enumerated type, return an amount of time to sleep. It has strong opinions about what should happen when you send it an invalid value:

private static int getTime(int mode) { return switch (mode) { case 0 -> 30 * SECOND; case 1 -> 15 * SECOND; case 2 -> 10 * SECOND; case 3 -> 20 * SECOND; case 4 -> 17 * SECOND; case 5 -> 32 * SECOND; default -> // go to hell 1000000000; }; }

Now, actually using an enum wouldn't solve this, though it'd make the code more clear. There's always the risk that the enum would have values added, and then you'd need to update the switch. Besides, maybe enums were just too new- they were only added in 2004 after all. The switch expression syntax here was added in 2020, however, so…

I just have to wonder: why not just use Integer.MAX_VALUE? If you want to send them to hell, why not really send them to hell?

[Advertisement] Keep all your packages and Docker containers in one place, scan for vulnerabilities, and control who can access different feeds. ProGet installs in minutes and has a powerful free version with a lot of great features that you can upgrade when ready.Learn more.
Remy Porter