From 8699f1fb81cb33ff3f1fc56208f95b2dd1bd9f29 Mon Sep 17 00:00:00 2001 From: M1nd3r Date: Mon, 18 Nov 2024 17:25:46 +0100 Subject: [PATCH] temporary disabling of appdirs variables --- .../src/trezorlib/transport/thp/channel_database.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/python/src/trezorlib/transport/thp/channel_database.py b/python/src/trezorlib/transport/thp/channel_database.py index 00dcf2176c..b70f90cc0d 100644 --- a/python/src/trezorlib/transport/thp/channel_database.py +++ b/python/src/trezorlib/transport/thp/channel_database.py @@ -3,17 +3,21 @@ import logging import os import typing as t -from appdirs import user_cache_dir, user_config_dir from ..thp.channel_data import ChannelData from .protocol_and_channel import ProtocolAndChannel LOG = logging.getLogger(__name__) -APP_NAME = "@trezor" # TODO -DATA_PATH = os.path.join(user_cache_dir(appname=APP_NAME), "channel_data.json") -CONFIG_PATH = os.path.join(user_config_dir(appname=APP_NAME), "config.json") +if False: + from appdirs import user_cache_dir, user_config_dir + APP_NAME = "@trezor" # TODO + DATA_PATH = os.path.join(user_cache_dir(appname=APP_NAME), "channel_data.json") + CONFIG_PATH = os.path.join(user_config_dir(appname=APP_NAME), "config.json") +else: + DATA_PATH = os.path.join("./channel_data.json") + CONFIG_PATH = os.path.join("./config.json") class ChannelDatabase: # TODO not finished should_store: bool = False