Surely the main problem here is with the BoJ▸ not being properly considered when planning the software for the ticket gate? If the barrier had understood the rules, the passenger would not have had to go through this palaver.
How would you do that? I guess for some journeys it is easy. But many journeys can be done multiple ways, and depending on which route you take, that will change if your are having a BoJ or if you have actually overrode and should be charged extra.
The real problem is the staff. Gateline rules are great for the simple stuff, and then staff should be able to fill in the rest. If the staff aren't trained, or do not accept the rules, then that is the real failing.