diff --git a/PyInstaller/configure.py b/PyInstaller/configure.py index 530ff8ad4c..e56350f547 100644 --- a/PyInstaller/configure.py +++ b/PyInstaller/configure.py @@ -65,7 +65,7 @@ def _get_pyinst_cache_dir(): if compat.getenv('PYINSTALLER_CONFIG_DIR'): cache_dir = compat.getenv('PYINSTALLER_CONFIG_DIR') elif is_win: - cache_dir = compat.getenv('APPDATA') + cache_dir = compat.getenv('LOCALAPPDATA') if not cache_dir: cache_dir = os.path.expanduser('~\\Application Data') elif is_darwin: diff --git a/news/5537.bugfix.rst b/news/5537.bugfix.rst new file mode 100644 index 0000000000..fc1e5131c6 --- /dev/null +++ b/news/5537.bugfix.rst @@ -0,0 +1,6 @@ +(Windows) Change default cache directory to ``LOCALAPPDATA`` +(from the original ``APPDATA``). +This is to make sure that cached data +doesn't get synced with the roaming profile. +For this and future versions ``AppData\Roaming\pyinstaller`` +might be safely deleted. \ No newline at end of file