mirror of
https://github.com/trezor/trezor-firmware.git
synced 2025-01-17 19:00:58 +00:00
trezorctl: bad call to click.echo (fixes #304)
This commit is contained in:
parent
2d7c74c535
commit
2b02af1126
11
trezorctl
11
trezorctl
@ -96,6 +96,7 @@ class UnderscoreAgnosticGroup(click.Group):
|
||||
This implementation of `click.Group` responds to underscore_commands by invoking
|
||||
the respective dash-command.
|
||||
"""
|
||||
|
||||
def get_command(self, ctx, cmd_name):
|
||||
cmd = super().get_command(ctx, cmd_name)
|
||||
if cmd is None:
|
||||
@ -522,18 +523,14 @@ def firmware_update(connect, filename, url, version, skip_check, fingerprint):
|
||||
elif url:
|
||||
import requests
|
||||
|
||||
click.echo("Downloading from", url)
|
||||
click.echo("Downloading from {}".format(url))
|
||||
r = requests.get(url)
|
||||
fp = r.content
|
||||
else:
|
||||
import requests
|
||||
|
||||
r = requests.get(
|
||||
"https://wallet.trezor.io/data/firmware/{}/releases.json".format(
|
||||
firmware_version
|
||||
)
|
||||
)
|
||||
releases = r.json()
|
||||
url = "https://wallet.trezor.io/data/firmware/{}/releases.json"
|
||||
releases = requests.get(url.format(firmware_version)).json()
|
||||
|
||||
def version_func(r):
|
||||
return r["version"]
|
||||
|
Loading…
Reference in New Issue
Block a user