Add query text to most runtime exceptions (except for IO ones where it shouldn't be relevant).