mirror of
https://github.com/cryptoadvance/specter-desktop.git
synced 2026-08-13 12:33:29 +02:00
Enforce hwi init (#2386)
* adding release_notes for v2.0.2 * add --enforcehwiinitialisation as click option * chore: ENFORCE_HWI_INITIALISATION_AT_STARTUP via
This commit is contained in:
parent
1f0bc602c7
commit
655e9153b6
2 changed files with 11 additions and 1 deletions
|
|
@ -57,6 +57,11 @@ def cli():
|
|||
is_flag=True,
|
||||
help="Start the hwi-bridge to use your HWWs with a remote specter.",
|
||||
)
|
||||
@click.option(
|
||||
"--enforcehwiinitialisation",
|
||||
is_flag=True,
|
||||
help="calls enumerate() which is known to cause issues with certain usb-devices plugged in at startup.",
|
||||
)
|
||||
@click.option(
|
||||
"--devstatus-threshold",
|
||||
type=click.Choice(["alpha", "beta", "prod"], case_sensitive=False),
|
||||
|
|
@ -83,6 +88,7 @@ def server(
|
|||
filelog,
|
||||
tor,
|
||||
hwibridge,
|
||||
enforcehwiinitialisation,
|
||||
devstatus_threshold,
|
||||
specter_data_folder,
|
||||
config,
|
||||
|
|
@ -148,6 +154,8 @@ def server(
|
|||
kwargs = configure_ssl(kwargs, app.config, ssl)
|
||||
|
||||
app.app_context().push()
|
||||
if enforcehwiinitialisation:
|
||||
app.config["ENFORCE_HWI_INITIALISATION_AT_STARTUP"] = True
|
||||
init_app(app, hwibridge=hwibridge)
|
||||
|
||||
if filelog:
|
||||
|
|
|
|||
|
|
@ -83,7 +83,9 @@ class BaseConfig(object):
|
|||
KEY = os.getenv("KEY", None)
|
||||
|
||||
# It might be necessary to enforce the HWI initialisation
|
||||
ENFORCE_HWI_INITIALISATION_AT_STARTUP = False
|
||||
ENFORCE_HWI_INITIALISATION_AT_STARTUP = _get_bool_env_var(
|
||||
"ENFORCE_HWI_INITIALISATION_AT_STARTUP", False
|
||||
)
|
||||
|
||||
# This will be used to search for a bitcoin.conf in order to enable the
|
||||
# auth method "RPC password as pin"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue