|
@ -113,18 +113,6 @@ class EEAptGet(): |
|
|
except SystemError as e: |
|
|
except SystemError as e: |
|
|
Log.debug(self, 'SystemError: ' + str(e)) |
|
|
Log.debug(self, 'SystemError: ' + str(e)) |
|
|
return False |
|
|
return False |
|
|
try: |
|
|
|
|
|
# apt_pkg.PkgSystemUnLock() |
|
|
|
|
|
result = apt_cache.commit() |
|
|
|
|
|
# apt_cache.close() |
|
|
|
|
|
return result |
|
|
|
|
|
except SystemError as e: |
|
|
|
|
|
Log.debug(self, 'SystemError: ' + str(e)) |
|
|
|
|
|
return False |
|
|
|
|
|
except Exception as e: |
|
|
|
|
|
Log.debug(self, str(e)) |
|
|
|
|
|
Log.error(self, str(e)) |
|
|
|
|
|
# apt_cache.close() |
|
|
|
|
|
else: |
|
|
else: |
|
|
# apt_cache.close() |
|
|
# apt_cache.close() |
|
|
Log.error(self, 'Unknown package selected (' + |
|
|
Log.error(self, 'Unknown package selected (' + |
|
@ -134,6 +122,20 @@ class EEAptGet(): |
|
|
if not remove_package(self, package, purge=purge): |
|
|
if not remove_package(self, package, purge=purge): |
|
|
continue |
|
|
continue |
|
|
|
|
|
|
|
|
|
|
|
if apt_cache.delete_count > 0: |
|
|
|
|
|
try: |
|
|
|
|
|
# apt_pkg.PkgSystemUnLock() |
|
|
|
|
|
result = apt_cache.commit() |
|
|
|
|
|
# apt_cache.close() |
|
|
|
|
|
return result |
|
|
|
|
|
except SystemError as e: |
|
|
|
|
|
Log.debug(self, 'SystemError: ' + str(e)) |
|
|
|
|
|
return False |
|
|
|
|
|
except Exception as e: |
|
|
|
|
|
Log.debug(self, str(e)) |
|
|
|
|
|
Log.error(self, str(e)) |
|
|
|
|
|
# apt_cache.close() |
|
|
|
|
|
|
|
|
def auto_clean(self): |
|
|
def auto_clean(self): |
|
|
""" |
|
|
""" |
|
|
Similar to `apt-get autoclean` |
|
|
Similar to `apt-get autoclean` |
|
|