SapFix cutting cool path toward eliminating debugging-code drudgery

SapFix cutting cool path toward eliminating debugging-code drudgery
This graphic illustrates how SapFix generates patches for software bugs. Credit: Facebook

Facebook has come up with something called SapFix and their announcement signifies a welcome measure of support for debugging task drudgery; SapFix can rely on artificial intelligence and come up with some answers that save time. The tool is all about finding and fixing bugs automatically. As such it has potential not only to boost the quality of code production but also the speed of generating code.

Facebook engineers Yue Jia, Ke Mao, and Mark Harman wrote about the find-and-fix in their blog.

"Debugging is drudgery," they wrote, but this new AI hybrid tool can cut engineers' time spent on debugging. SapFix can automatically generate fixes for specific bugs, then propose them to engineers for approval and deployment to production.

Their description clearly shows that this is not a replacement for human expertise as the engineers are always kept in the loop; their expertise is called on to confirm that the fixes proposed should actually be deployed. The tool leans on AI to suggest fixes for programming errors, and then comes the human element where humans (software engineers) can approve and deploy.

"It's an important milestone for AI hybrids and offers further evidence that search-based software engineering can reduce friction in software development," they said.

SD Times walked readers through what SapFix can do: (1) find the bug (2) generate a fix and (3) propose a plan of action for engineers to work out before the production rollout.

The tool can even find more than a single patch. It can generate multiple fixes per bug and evaluate the quality. The identification of a red light code crash is passed to SapFix, said The Register, which then decides on a few possible strategies for generating a patch.

In addition to SapFix mention was given to Facebook's automated software testing tool, in the article by Christina Cardoza of SD Times.

SapFix is still in development, so it not to be confused with Sapienz, producing hundreds of monthly bug reports. The engineers also blogged, "But since we started testing SapFix in August, the tool has successfully generated patches that have been accepted by human reviewers and pushed to production."

The bloggers had this to say about future directions. "As we develop SapFix to work with different kinds of bugs and software, the tool has the potential to change the speed and quality of code generation. That's true not just for companies that operate at large scales, but also for nearly anyone who creates code. Whether used together or separately, SapFix and Sapienz let developers spend less time on debugging and more on generating what's next."

Want a taste of how SapFix scrambles for solutions? Thomas Claburn in The Register:

"It may fully or partially undo the past commit that introduced the bug, or it may fetch a fix from a library of templated repairs derived from code patches filed by company engineers in the past. If those options don't work, SapFix tries making minor code changes to the abstract syntax tree of the statement responsible for the crash, in the hope that will ameliorate the problem."

© 2018 Tech Xplore

Citation: SapFix cutting cool path toward eliminating debugging-code drudgery (2018, September 17) retrieved 21 May 2024 from
This document is subject to copyright. Apart from any fair dealing for the purpose of private study or research, no part may be reproduced without the written permission. The content is provided for information purposes only.

Explore further

Automatic debugging of software


Feedback to editors