You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Desktop 9.17 no longer remembers the last visited directory in file dialogs (always opens Downloads) #10226
After upgrading from pgAdmin 4 Desktop 9.16 to 9.17 on Windows, all file selection dialogs always open in the Windows Downloads folder.
In version 9.16, pgAdmin correctly remembered the last directory used and reopened subsequent file dialogs in that location.
This behavior appears to have been lost in 9.17.
Environment
pgAdmin version: 9.17
Installation mode: Desktop
Operating System: Windows 11
Steps to reproduce
Open any file dialog in pgAdmin (for example Backup, Restore, Open SQL file or Import/Export Data).
Browse to a folder other than Downloads.
Complete or cancel the operation.
Open the same (or another) file dialog again.
Expected behavior
The dialog should reopen in the last directory used, as it did in pgAdmin Desktop 9.16.
Actual behavior
The dialog always opens in the Windows Downloads folder.
Additional information
The issue affects all file dialogs that I have tested:
Open SQL file
Backup
Restore
Import/Export Data
I could not find any preference to configure the initial directory, and this behavior is different from pgAdmin Desktop 9.16, where the last visited directory was remembered.
Reacted by Jim Garrison, Jay, Yakir Havin, Liu Mazin, epoweripione and lambda-with-curry
This release's dependency bump list shows the bundled Electron runtime went from 42.3.3 → 43.1.1. Electron's dialog.showOpenDialog/showSaveDialog recently changed their fallback behavior: when no defaultPath is explicitly passed, the dialog now defaults to the user's Downloads folder instead of the previous fallback (the process's current working directory). See: electron/electron#49868
It looks like pgAdmin's native file dialog invocation for the Query Tool may not be explicitly passing a defaultPath (e.g., derived from the last_directory_visited preference, which is otherwise used correctly by the internal Storage Manager), so it's now falling through to Electron's new Downloads-folder default.
Confirmed not a local/config issue:
Verified last_directory_visited and last_storage preferences in pgadmin4.db are set correctly and do reflect the intended last-used folder
Editing these values directly in the SQLite database has no effect on this specific dialog
Behavior started immediately after updating to v9.17; did not occur on v9.16 or earlier
Suggested fix: Explicitly pass a defaultPath (sourced from the last-used directory, same as used elsewhere) into the native dialog call(s) affected by the Electron 43 upgrade, so behavior matches pre-v9.17.
Activity
jitendraloyal commentedon Aug 7, 2026
Suspected cause:
This release's dependency bump list shows the bundled Electron runtime went from 42.3.3 → 43.1.1. Electron's dialog.showOpenDialog/showSaveDialog recently changed their fallback behavior: when no defaultPath is explicitly passed, the dialog now defaults to the user's Downloads folder instead of the previous fallback (the process's current working directory). See: electron/electron#49868
It looks like pgAdmin's native file dialog invocation for the Query Tool may not be explicitly passing a defaultPath (e.g., derived from the last_directory_visited preference, which is otherwise used correctly by the internal Storage Manager), so it's now falling through to Electron's new Downloads-folder default.
Confirmed not a local/config issue:
Verified last_directory_visited and last_storage preferences in pgadmin4.db are set correctly and do reflect the intended last-used folder
Editing these values directly in the SQLite database has no effect on this specific dialog
Behavior started immediately after updating to v9.17; did not occur on v9.16 or earlier
Suggested fix: Explicitly pass a defaultPath (sourced from the last-used directory, same as used elsewhere) into the native dialog call(s) affected by the Electron 43 upgrade, so behavior matches pre-v9.17.
fix: remember last visited directory in Desktop file dialogs
fix: remember last visited directory in Desktop file dialogs
Restore remembering the last visited directory in Desktop file dialogs.
dpage commentedon Oct 12, 2026
Fixed in 7c974c0 (#10327).