better debugging info
add open/close debug