forked from platformio/platformio-core
Fix issue when check updates for VCS repository // Resolve #917
This commit is contained in:
@ -14,7 +14,7 @@
|
||||
|
||||
import sys
|
||||
|
||||
VERSION = (3, 3, "0a15")
|
||||
VERSION = (3, 3, "0a16")
|
||||
__version__ = ".".join([str(s) for s in VERSION])
|
||||
|
||||
__title__ = "platformio"
|
||||
|
@ -553,6 +553,7 @@ class BasePkgManager(PkgRepoMixin, PkgInstallerMixin):
|
||||
# skip a fixed package to a specific version
|
||||
if "@" in pkg_dir and "__src_url" not in manifest:
|
||||
return None
|
||||
|
||||
if "__src_url" in manifest:
|
||||
try:
|
||||
vcs = VCSClientFactory.newClient(
|
||||
@ -571,14 +572,18 @@ class BasePkgManager(PkgRepoMixin, PkgInstallerMixin):
|
||||
silent=True)
|
||||
except (exception.PlatformioException, ValueError):
|
||||
return None
|
||||
|
||||
if not latest:
|
||||
return None
|
||||
|
||||
up_to_date = False
|
||||
try:
|
||||
assert "__src_url" not in manifest
|
||||
up_to_date = (semantic_version.Version.coerce(manifest['version'])
|
||||
>= semantic_version.Version.coerce(latest))
|
||||
except ValueError:
|
||||
except (AssertionError, ValueError):
|
||||
up_to_date = latest == manifest['version']
|
||||
|
||||
return False if up_to_date else latest
|
||||
|
||||
def install(self,
|
||||
|
Reference in New Issue
Block a user