Skip to content

fix(config): use forward slash in default DB path to prevent literal backslash filename (#90)#91

Open
SAY-5 wants to merge 1 commit into
devedse:masterfrom
SAY-5:fix/issue-90-database-path-separator
Open

fix(config): use forward slash in default DB path to prevent literal backslash filename (#90)#91
SAY-5 wants to merge 1 commit into
devedse:masterfrom
SAY-5:fix/issue-90-database-path-separator

Conversation

@SAY-5
Copy link
Copy Markdown

@SAY-5 SAY-5 commented Apr 30, 2026

Fixes #90. The default DefaultConnection in DeveLanCacheUI_Backend/appsettings.json:3 used backslashes:

Data Source={DeveLanCacheUIDataDirectory}\\database\\develancacheui.db

On Linux containers (the official image base) backslashes aren't path separators, so the SQLite provider created a single file literally named develancacheuidata\\database\\develancacheui.db directly inside /var, while the recommended volume mount at /var/develancacheuidata/database/ stayed empty. Container restart wiped the unmounted file → silent data loss every time.

Switched to forward slashes so the path resolves correctly under both Linux and Windows .NET (/ is accepted as a path separator by all major filesystems and SQLite providers).

Test plan

  • JSON validity check on appsettings.json
  • No code-side change needed; {DeveLanCacheUIDataDirectory} is the same token, only the literal separator differs

…backslash filename (devedse#90)

Signed-off-by: SAY-5 <say.apm35@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Wrong default database filename path which leads data loss

1 participant