fix cancel unloading and add log messages