From 54d3c1d23b8994eeeac8348c6e820aaf3a56cc7b Mon Sep 17 00:00:00 2001 From: Disassembler Date: Wed, 5 Jun 2019 15:15:03 +0200 Subject: [PATCH] Use pkg_resources instead of packaging module --- usr/lib/python3.6/vmmgr/pkgmgr.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr/lib/python3.6/vmmgr/pkgmgr.py b/usr/lib/python3.6/vmmgr/pkgmgr.py index 5dcf815..adfdbf9 100644 --- a/usr/lib/python3.6/vmmgr/pkgmgr.py +++ b/usr/lib/python3.6/vmmgr/pkgmgr.py @@ -7,7 +7,7 @@ import shutil import subprocess from enum import Enum -from packaging.version import Version +from pkg_resources import parse_version from werkzeug.exceptions import BadRequest, NotFound, Unauthorized from . import crypto @@ -175,4 +175,4 @@ class PkgMgr: def has_update(self, app): if not self.online_packages: return False - return Version(self.conf['packages'][app]['version']) < Version(self.online_packages[app]['version']) + return parse_version(self.conf['packages'][app]['version']) < parse_version(self.online_packages[app]['version'])