Skip to content

Commit 47d1b19

Browse files
committed
Revert "Better version verification"
This actually blocks installing unlisted sdks, revert to old behavior
1 parent ae1870c commit 47d1b19

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

pebble_tool/sdk/manager.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -251,10 +251,9 @@ def _install_toolchain_from_handle(self, f, sdk_version, platform_name):
251251
os.rmdir(os.path.join(toolchain_path, 'toolchain-' + platform_name))
252252

253253
def install_remote_sdk(self, version):
254-
versions = [x['version'] for x in self.list_remote_sdks()] + ['latest']
255-
if version not in versions:
256-
raise SDKInstallError("SDK {} could not be found.".format(version))
257254
sdk_info = self.request("/v1/files/sdk-core/{}?channel={}".format(version, self.get_channel())).json()
255+
if version not in sdk_info:
256+
raise SDKInstallError("SDK {} could not be downloaded.".format(version))
258257
path = os.path.normpath(os.path.join(self.sdk_dir, sdk_info['version']))
259258
manifest_path = os.path.join(path, 'sdk-core', 'manifest.json')
260259

0 commit comments

Comments
 (0)