fix(core): preserve S3 config and serve nested uploads - #2780
Conversation
SafeDep Report SummaryNo dependency changes detected. Nothing to scan. This report is generated by SafeDep Github App |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 96e8a6eb11
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| bucket: field.halfGrid(nullableStorageText(), 'Bucket'), | ||
| region: field | ||
| .halfGrid(nullableStorageText(), 'Region') | ||
| .transform((value) => value || 'auto'), |
There was a problem hiding this comment.
Preserve the existing region on partial backup patches
When a client PATCHes backupOptions without a region—for example, to change only enable—this transform converts the omitted value from undefined to "auto". patchAndValid() then passes that generated field to patch(), so a previously configured custom S3 region is silently overwritten and subsequent backup uploads may use the wrong region. Keep undefined unchanged while normalizing only an explicitly null or blank region.
Useful? React with 👍 / 👎.



Summary
Test plan
Database migrations checklist (delete if no schema change)
(rolling deploy: new and old pods coexist during cutover).
(expand now, contract in a follow-up release).
CREATE INDEX CONCURRENTLY(and breakout of drizzle's default transaction).
pnpm -C apps/core run lint:migrationspasses.migration-lint:allow=is used,reason=explains why and areviewer has agreed.
See
.claude/skills/mx-migration-author/SKILL.mdfor the expand-contractdecision tree and the spec at
docs/superpowers/specs/2026-05-05-database-migration-release-phase-design.md.