24
24
_CACHE = OrderedDict ()
25
25
_CACHE [Path (sys .executable )] = PythonInfo ()
26
26
LOGGER = logging .getLogger (__name__ )
27
- _CACHE_FILE_VERSION = 1
28
27
29
28
30
29
def from_exe (cls , app_data , exe , env = None , raise_on_error = True , ignore_cache = False ): # noqa: FBT002, PLR0913
@@ -65,13 +64,8 @@ def _get_via_file_cache(cls, app_data, path, exe, env):
65
64
with py_info_store .locked ():
66
65
if py_info_store .exists (): # if exists and matches load
67
66
data = py_info_store .read ()
68
- of_path , of_st_mtime , of_content , version = (
69
- data ["path" ],
70
- data ["st_mtime" ],
71
- data ["content" ],
72
- data .get ("version" ),
73
- )
74
- if of_path == path_text and of_st_mtime == path_modified and version == _CACHE_FILE_VERSION :
67
+ of_path , of_st_mtime , of_content = data ["path" ], data ["st_mtime" ], data ["content" ]
68
+ if of_path == path_text and of_st_mtime == path_modified :
75
69
py_info = cls ._from_dict (of_content .copy ())
76
70
sys_exe = py_info .system_executable
77
71
if sys_exe is not None and not os .path .exists (sys_exe ):
@@ -86,7 +80,6 @@ def _get_via_file_cache(cls, app_data, path, exe, env):
86
80
"st_mtime" : path_modified ,
87
81
"path" : path_text ,
88
82
"content" : py_info ._to_dict (), # noqa: SLF001
89
- "version" : _CACHE_FILE_VERSION ,
90
83
}
91
84
py_info_store .write (data )
92
85
else :
0 commit comments