The solution is near....enhance the medical exam and provide a new tick-box which will confirm that the examined machine operator will not have any problems while being fatigued...
If the box is not ticked, a limitation on the license will have to be endorsed...