Better log commands + other changes from Bina Tech.