Make inventory parsing error detection smarter

If something is executable but doesn't look like it should be, or if
something is NOT executable and DOES looks like it should, show a
more apropos error with a hint on correcting the problem

Fixes #5113