fixed some prints and lookup bugs