some debugging info added, and a fail callback