Removed manual debug mode and added log support