Fix exception handling code.
Fix require_relative.