now always throws error if a bond type changes, but both of of the involved atoms are too close to edge of template