Skip to content

fix: create file storage directory on initialization - #73

Closed
Mabolla wants to merge 1 commit into
base:masterfrom
Mabolla:fix/create-file-storage-directory
Closed

Mabolla wants to merge 1 commit into
base:masterfrom
Mabolla:fix/create-file-storage-directory

Conversation

@Mabolla

@Mabolla Mabolla commented Aug 21, 2026

Copy link
Copy Markdown

Summary

  • create the configured file storage directory during NewFileStorage initialization
  • add a regression test covering a missing storage directory

Why

The file backend initializes backfill_processes and lockfile immediately, but previously assumed the configured directory already existed. On a fresh deployment with a new --file-directory, those metadata writes can fail because the parent directory is missing.

Closes #71.

Validation

  • reproduced the failure locally with a regression test
  • go test ./common/storage -v
  • git diff --cached --check

S3 integration tests were skipped because RUN_INTEGRATION_TESTS was not set.

@cb-heimdall

Copy link
Copy Markdown
Collaborator

🟡 Heimdall Review Status

Requirement Status More Info
Reviews 🟡 0/2
Denominator calculation
Show calculation
1 if user is bot 0
1 if user is external 0
2 if repo is sensitive 0
From .codeflow.yml 1
Additional review requirements
Show calculation
Max 0
0
From CODEOWNERS 0
Global minimum 0
Max 1
1
1 if commit is unverified 1
Sum 2

@Mabolla
Mabolla marked this pull request as ready for review August 21, 2026 17:59
@Mabolla

Mabolla commented Aug 31, 2026

Copy link
Copy Markdown
Author

Closing this PR because #72 was opened earlier and addresses the same issue (#71). Thanks.

@Mabolla Mabolla closed this Aug 31, 2026
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.

file storage crashes on startup when --file-directory does not exist yet

2 participants