remove popen code