def _install(self, package, file_location): # 1. extract files LOG.info('Installing {0.name}-{0.full_version}'.format(package)) files_list = Extractor(self.pypmenv).extract_package(file_location) ipkg = InstalledPackage.create_from( package, files_list=files_list) assert len(ipkg.files_list) > 0 # 2. apply fixes for fixer in Fixer(self.pypmenv).get_applicable_fixers(ipkg): fixer.fix() # 3. add to installed_store self.pypmenv.installed_store.add_packages([ipkg])
def _install(self, package, file_location): # 1. extract files LOG.info('Installing {0.full_name}'.format(package)) files_list = Extractor(self.pypmenv).extract_package( file_location, package.name) ipkg = InstalledPackage.create_from(package, files_list=files_list) assert ipkg.files_list is not None assert len(ipkg.files_list) > 0 # 2. post-install hooks for hook in hooks.POSTINSTALL: hook(self.pypmenv, ipkg) # 3. add to installed_store self.pypmenv.installed_store.add_packages([ipkg])
def _install(self, package, file_location): # 1. extract files LOG.info('Installing {0.full_name}'.format(package)) files_list = Extractor(self.pypmenv).extract_package( file_location, package.name) ipkg = InstalledPackage.create_from( package, files_list=files_list) assert ipkg.files_list is not None assert len(ipkg.files_list) > 0 # 2. apply fixes for fixer in Fixer(self.pypmenv).get_applicable_fixers(ipkg): fixer.fix() # 3. add to installed_store self.pypmenv.installed_store.add_packages([ipkg])
def _install(self, package, file_location): # 1. extract files LOG.info('Installing {0.full_name}'.format(package)) files_list = Extractor(self.pypmenv).extract_package( file_location, package.name) ipkg = InstalledPackage.create_from( package, files_list=files_list) assert ipkg.files_list is not None assert len(ipkg.files_list) > 0 # 2. post-install hooks for hook in hooks.POSTINSTALL: hook(self.pypmenv, ipkg) # 3. add to installed_store self.pypmenv.installed_store.add_packages([ipkg])