This thread is so similar to those in other media about self driving cars.
There's so much talk about the "programming" of the computer systems, but it's not programming that's the problem.
The real problem is that artificial intelligence isn't actually about programming, deep down. Given that no-one agrees how to define intelligence, or conciousness, it's difficult to see how a truly artificially intelligent aircraft can be envisaged at present.
And if real AI CAN be built, it opens a whole new can of worms anyway.