Code and dependency cleanup