added virtual environment support