From ccacf50db5bec792ae83e33b7acf1bf7c5092333 Mon Sep 17 00:00:00 2001 From: deeplow Date: Thu, 21 Jul 2022 14:00:56 +0100 Subject: [PATCH] simplify resources_path logic to reolve type hint The following logic was leading to type hint issues: > inspect.getfile(inspect.currentframe()) But this code is overly complex for what it does is the same as simply __file__. So we kill two birds with one stone, so to speak. --- dangerzone/global_common.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/dangerzone/global_common.py b/dangerzone/global_common.py index c93c050..f8d8537 100644 --- a/dangerzone/global_common.py +++ b/dangerzone/global_common.py @@ -1,8 +1,6 @@ import gzip -import inspect import json import logging -import os import pathlib import platform import shutil