added debug trace