def create_env(self):
        """
        Create a PEP-370 environment
        """
        root = path.Path(os.environ.get('SERVICES_ROOT', 'services'))
        self.env_path = (root / self.name).abspath()
        cmd = [
            self.python,
            '-c', 'import site; print(site.getusersitepackages())',
        ]
        out = subprocess.check_output(cmd, env=self._run_env)
        site_packages = out.decode().strip()
        path.Path(site_packages).makedirs_p()
def create_env ( self ) : root = path . Path ( os . environ . get ( 'SERVICES_ROOT' , 'services' ) ) self . env_path = ( root / self . name ) . abspath ( ) cmd = [ self . python , '-c' , 'import site; print(site.getusersitepackages())' , ] out = subprocess . check_output ( cmd , env = self . _run_env ) site_packages = out . decode ( ) . strip ( ) path . Path ( site_packages ) . makedirs_p ( )
Create a PEP-370 environment