fix(android): use .noopbak extension for Backup & Move export in Data Sources #19

Merged
NoopApp merged 1 commit from A/noop:fix/datasources-backup-extension-v2 into main 2026-06-17 19:03:27 +00:00
Contributor

What this PR does

The Backup & Move card in the Data Sources screen was passing "strand-backup.noopdb" as the suggested filename to the system file picker. The .noopdb extension belongs to the old plain-SQLite format that was retired in favour of the compressed .noopbak format (ZIP-wrapped SQLite, typically 80-90% smaller).

DataBackup.exportTo has always written the compressed format - the stale extension was the only bug. A user who accepted the default filename would end up with a .noopdb file that actually contained a ZIP, which:

  • breaks any tool that tries to open it as a SQLite file by extension
  • breaks import on iOS/Mac if they detect format by extension before magic bytes

Details:

  • Fixed: exportLauncher.launch("strand-backup.noopdb") ? exportLauncher.launch("noop-backup-${java.time.LocalDate.now()}.noopbak") in DataSourcesScreen.kt
  • Filename now matches the format used by the Settings screen export and the format documented in the changelog

No logic changes - DataBackup.exportTo already writes a correct single-entry ZIP with deflate compression.

Type of change

  • Bug fix
  • New feature
  • Refactor / cleanup
  • Documentation
  • CI / tooling

How it was tested

Built and ran assembleFullRelease locally. Tapped Export in Data Sources - file picker now suggests noop-backup-2026-06-17.noopbak. Imported the exported file on the same device - import succeeded and prompted restart as expected.

Checklist

  • Swift package tests pass for any package I touched (swift test in Packages/<name>)
  • Android unit tests pass if I touched android/ (./gradlew testFullDebugUnitTest)
  • No new build warnings introduced
  • UI changes use only StrandDesign tokens - no hardcoded colors, fonts, or spacing
  • No hardcoded hex frame bytes; protocol facts live in the schema / decoders
  • Follows the conventions in docs/CONTRIBUTING.md
  • I did not commit generated output (Strand.xcodeproj/) or any secrets/keystores
## What this PR does The **Backup & Move** card in the Data Sources screen was passing `"strand-backup.noopdb"` as the suggested filename to the system file picker. The `.noopdb` extension belongs to the old plain-SQLite format that was retired in favour of the compressed `.noopbak` format (ZIP-wrapped SQLite, typically 80-90% smaller). `DataBackup.exportTo` has always written the compressed format - the stale extension was the only bug. A user who accepted the default filename would end up with a `.noopdb` file that actually contained a ZIP, which: - breaks any tool that tries to open it as a SQLite file by extension - breaks import on iOS/Mac if they detect format by extension before magic bytes **Details:** - **Fixed:** `exportLauncher.launch("strand-backup.noopdb")` ? `exportLauncher.launch("noop-backup-${java.time.LocalDate.now()}.noopbak")` in `DataSourcesScreen.kt` - Filename now matches the format used by the Settings screen export and the format documented in the changelog No logic changes - `DataBackup.exportTo` already writes a correct single-entry ZIP with deflate compression. ## Type of change - [x] Bug fix - [ ] New feature - [ ] Refactor / cleanup - [ ] Documentation - [ ] CI / tooling ## How it was tested Built and ran `assembleFullRelease` locally. Tapped Export in Data Sources - file picker now suggests `noop-backup-2026-06-17.noopbak`. Imported the exported file on the same device - import succeeded and prompted restart as expected. ## Checklist - [ ] Swift package tests pass for any package I touched (`swift test` in `Packages/<name>`) - [x] Android unit tests pass if I touched `android/` (`./gradlew testFullDebugUnitTest`) - [x] No new build warnings introduced - [x] UI changes use only `StrandDesign` tokens - no hardcoded colors, fonts, or spacing - [x] No hardcoded hex frame bytes; protocol facts live in the schema / decoders - [x] Follows the conventions in [`docs/CONTRIBUTING.md`](../docs/CONTRIBUTING.md) - [x] I did not commit generated output (`Strand.xcodeproj/`) or any secrets/keystores ## Related issues <!-- Closes #N -->
A added 1 commit 2026-06-17 18:57:19 +00:00
Owner

Verified against source and merged — thank you! 🙏

Confirmed: DataBackup.exportTo writes a .noopbak ZIP, the Settings export already uses this exact noop-backup-<date>.noopbak pattern, and .noopdb is the retired plain-SQLite format — so the suggested filename here was the only thing out of step. Clean catch, and it now matches the Settings export verbatim. Ships in the next release.

Welcome, and nice first PR on the new home. 🖤

Verified against source and merged — thank you! 🙏 Confirmed: `DataBackup.exportTo` writes a `.noopbak` ZIP, the Settings export already uses this exact `noop-backup-<date>.noopbak` pattern, and `.noopdb` is the retired plain-SQLite format — so the suggested filename here was the only thing out of step. Clean catch, and it now matches the Settings export verbatim. Ships in the next release. Welcome, and nice first PR on the new home. 🖤
A deleted branch fix/datasources-backup-extension-v2 2026-06-17 19:04:46 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
NoopApp/noop!19
No description provided.