Databases Folder In User AppData Being Wiped · Issue #45396 · electron/electron · GitHub
Skip to content

Databases Folder In User AppData Being Wiped #45396

Description

@lemonpole

Preflight Checklist

Electron Version

34.0.2

What operating system(s) are you using?

Windows

Operating System Version

Windows 10 Home 22H2 (build 19045.5371)

What arch are you using?

x64

Last Known Working Electron version

29.2.0

Expected Behavior

My databases folder in user app data should not be deleted when a BrowserWindow instance is created.

>> the "C:\Users\Test\AppData\Roaming\glorious-article-detail-vfgrz\databases" folder does NOT exist. creating it...
>> creating browser window...
>> the "C:\Users\Test\AppData\Roaming\glorious-article-detail-vfgrz\databases" folder does NOT exist.

Actual Behavior

  • I create the databases folder in user app data on start.
  • I create a new browser window.
  • My databases folder is deleted.

Important

If I change the name from databases to foo or anything else, it works as expected and the folder is not deleted.

Testcase Gist URL

https://gist.github.com/7671617baf4db8ff7f7d82a37df7ad37

Additional Information

In my app, I persist data in a SQLite database located in the user's app data under a databases folder.

I attempted to upgrade from 29.2.x to 34.x recently and noticed that my databases folder is now being wiped.

  • The issue persists even if you toggle "Do not delete user data directories" on in Electron Fiddle's settings.
  • My databases folder was not removed in Electron 29.x.

Metadata

Metadata

Assignees

No one assigned

    Type

    No fields configured for Bug.

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions