removed an assert and created new Exception class