catch exception on boundary