Skip to content

Commit

Permalink
fix(qbtools): warning on config
Browse files Browse the repository at this point in the history
  • Loading branch information
buroa committed Oct 2, 2024
1 parent eda48b7 commit 061a32a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions qbtools/qbtools.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,11 @@ def qbit_client(args):
def get_config(args, key=None, default=None):
config = {}

with open(args.config, "r") as stream:
try:
try:
with open(args.config, "r") as stream:
config = yaml.safe_load(stream)
except yaml.YAMLError as e:
logger.error(e)
except Exception as e:
logger.debug(e) # ignore error

if key:
config = config.get(key, default)
Expand Down

0 comments on commit 061a32a

Please sign in to comment.